WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-ia64-devel

Re: [Xen-ia64-devel] [PATCH 4/5] kexec: fix /proc/iomem_machine

To: Simon Horman <horms@xxxxxxxxxxxx>
Subject: Re: [Xen-ia64-devel] [PATCH 4/5] kexec: fix /proc/iomem_machine
From: Isaku Yamahata <yamahata@xxxxxxxxxxxxx>
Date: Thu, 24 Jul 2008 17:15:49 +0900
Cc: xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Thu, 24 Jul 2008 01:15:54 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <20080724080417.GE8421@xxxxxxxxxxxx>
List-help: <mailto:xen-ia64-devel-request@lists.xensource.com?subject=help>
List-id: Discussion of the ia64 port of Xen <xen-ia64-devel.lists.xensource.com>
List-post: <mailto:xen-ia64-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-ia64-devel>, <mailto:xen-ia64-devel-request@lists.xensource.com?subject=unsubscribe>
References: <20080724055959.GA14460@xxxxxxxxxxxxxxxxxxxxxxxxxx> <20080724080417.GE8421@xxxxxxxxxxxx>
Sender: xen-ia64-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.6i
On Thu, Jul 24, 2008 at 06:04:19PM +1000, Simon Horman wrote:
> On Thu, Jul 24, 2008 at 02:59:59PM +0900, Isaku Yamahata wrote:
> > [IA64] initialize /proc/iomem_machine properly when discontig mem.
> > 
> > With CONFIG_DISCONTIGMEM enabled /proc/iomem_machine isn't
> > initialized properly so that kexec failes because kexec-tools wrongly
> > tries to use ia64 boot mem (or efi memmap area).
> > This patch fixes /proc/iomem_machine.
> > 
> > Signed-off-by: Isaku Yamahata <yamahata@xxxxxxxxxxxxx>
> > 
> > diff -r 75235538851a arch/ia64/mm/discontig.c
> > --- a/arch/ia64/mm/discontig.c      Thu Jul 24 14:31:08 2008 +0900
> > +++ b/arch/ia64/mm/discontig.c      Thu Jul 24 14:31:27 2008 +0900
> > @@ -21,6 +21,9 @@
> >  #include <linux/acpi.h>
> >  #include <linux/efi.h>
> >  #include <linux/nodemask.h>
> > +#if defined(CONFIG_XEN) && defined(CONFIG_KEXEC)
> > +#include <linux/kexec.h>
> > +#endif
> >  #include <asm/pgalloc.h>
> >  #include <asm/tlb.h>
> >  #include <asm/meminit.h>
> > @@ -502,10 +505,18 @@
> >     reserve_pernode_space();
> >     memory_less_nodes();
> >     initialize_pernode_data();
> > +#if defined(CONFIG_XEN) && defined(CONFIG_KEXEC)
> > +   xen_machine_kexec_setup_resources();
> > +#endif
> >  
> >     max_pfn = max_low_pfn;
> >  
> >     find_initrd();
> > +#ifdef CONFIG_CRASH_DUMP
> > +   /* If we are doing a crash dump, we still need to know the real mem
> > +    * size before original memory map is * reset. */
> > +   saved_max_pfn = max_pfn;
> > +#endif
> >  }
> >  
> >  #ifdef CONFIG_SMP
> 
> I need to review this more fully, but should #ifdef CONFIG_CRASH_DUMP
> be #ifdef CONFIG_KEXEC?

To be honest, I'm not sure with saved_max_pfn.
I just followed find_memory() in linux/arch/ia64/mm/contig.c
which is commited by changeset:   229:d3f72c686185.
Upstream Linux changeset 45a98fc622ae700eed34eb2be00743910d50dbe1

-- 
yamahata

_______________________________________________
Xen-ia64-devel mailing list
Xen-ia64-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ia64-devel