From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Jan Beulich" Subject: [PATCH] Re: Re: [PATCH] to fix ACPI slit table access at runtime Date: Thu, 25 Feb 2010 13:35:45 +0000 Message-ID: <4B868AC102000078000314BB@vpn.id2.novell.com> References: <4B868329020000780003144E@vpn.id2.novell.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=__Part7852B8A1.2__=" Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Keir Fraser Cc: "xen-devel@lists.xensource.com" , Ian Jackson List-Id: xen-devel@lists.xenproject.org This is a MIME message. If you are reading this text, you may want to consider changing to a mail reader or gateway that understands how to properly handle MIME multipart messages. --=__Part7852B8A1.2__= Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Content-Disposition: inline >>> Keir Fraser 25.02.10 14:16 >>> >Given we agree the current situation is a bug, could you make up a patch >along the lines of what you prefer to see? Because my default action will = be >simply to ifdef the code, as NUMA-on-i386 is not much a concern of mine. Signed-off-by: Jan Beulich --- 2010-02-19.orig/xen/arch/x86/numa.c 2010-01-13 18:58:11.000000000 = +0100 +++ 2010-02-19/xen/arch/x86/numa.c 2010-02-25 14:27:14.000000000 = +0100 @@ -30,7 +30,7 @@ struct node_data node_data[MAX_NUMNODES] =20 /* Mapping from pdx to node id */ int memnode_shift; -static typeof(*memnodemap) _memnodemap[2]; +static typeof(*memnodemap) _memnodemap[64]; unsigned long memnodemapsize; u8 *memnodemap; =20 @@ -90,6 +90,7 @@ static int __init populate_memnodemap(co =20 static int __init allocate_cachealigned_memnodemap(void) { +#ifndef __i386__ unsigned long size =3D PFN_UP(memnodemapsize * sizeof(*memnodemap))= ; unsigned long mfn =3D alloc_boot_pages(size, 1); =20 @@ -108,6 +109,13 @@ static int __init allocate_cachealigned_ memnodemapsize =3D size / sizeof(*memnodemap); =20 return 0; +#else + printk(KERN_ERR + "Memory to Node hash needs %lu entries, got only %zu\n", + memnodemapsize, ARRAY_SIZE(_memnodemap)); + memnodemapsize =3D 0; + return -1; +#endif } =20 /* --=__Part7852B8A1.2__= Content-Type: text/plain; name="i386-numa-not-boot-alloc.patch" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="i386-numa-not-boot-alloc.patch" Signed-off-by: Jan Beulich =0A=0A--- 2010-02-19.orig/x= en/arch/x86/numa.c 2010-01-13 18:58:11.000000000 +0100=0A+++ = 2010-02-19/xen/arch/x86/numa.c 2010-02-25 14:27:14.000000000 +0100=0A@@ = -30,7 +30,7 @@ struct node_data node_data[MAX_NUMNODES]=0A =0A /* Mapping = from pdx to node id */=0A int memnode_shift;=0A-static typeof(*memnodemap) = _memnodemap[2];=0A+static typeof(*memnodemap) _memnodemap[64];=0A unsigned = long memnodemapsize;=0A u8 *memnodemap;=0A =0A@@ -90,6 +90,7 @@ static int = __init populate_memnodemap(co=0A =0A static int __init allocate_cachealigne= d_memnodemap(void)=0A {=0A+#ifndef __i386__=0A unsigned long size =3D = PFN_UP(memnodemapsize * sizeof(*memnodemap));=0A unsigned long mfn = =3D alloc_boot_pages(size, 1);=0A =0A@@ -108,6 +109,13 @@ static int = __init allocate_cachealigned_=0A memnodemapsize =3D size / = sizeof(*memnodemap);=0A =0A return 0;=0A+#else=0A+ printk(KERN_ERR=0A+= "Memory to Node hash needs %lu entries, got only %zu\n",=0A+= memnodemapsize, ARRAY_SIZE(_memnodemap));=0A+ memnodemaps= ize =3D 0;=0A+ return -1;=0A+#endif=0A }=0A =0A /*=0A --=__Part7852B8A1.2__= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel --=__Part7852B8A1.2__=--