[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] RE: [PATCH] to fix ACPI slit table access at runtime



But the alloc_boot_pages() isn't done on x86-64 only, as Keir pointed
out has to be the case.

Jan

>>> "Kamble, Nitin A" <nitin.a.kamble@xxxxxxxxx> 25.02.10 20:31 >>>
> Keir, here is the updated patch. I did verify that it is giving right 
> information at runtime.

This is re-updated and bit simplified patch.
Signed-Off-By: Nitin A Kamble <nitin.a.kamble@xxxxxxxxx>


diff -r b474725a242b xen/arch/x86/srat.c
--- a/xen/arch/x86/srat.c       Thu Feb 25 07:50:38 2010 -0800
+++ b/xen/arch/x86/srat.c       Fri Feb 26 03:26:08 2010 -0800
@@ -140,11 +140,18 @@
 /* Callback for SLIT parsing */
 void __init acpi_numa_slit_init(struct acpi_table_slit *slit)
 {
+       unsigned long mfn;
        if (!slit_valid(slit)) {
                printk(KERN_INFO "ACPI: SLIT table looks invalid. Not used.\n");
                return;
        }
-       acpi_slit = slit;
+       mfn = alloc_boot_pages(PFN_UP(slit->header.length), 1);
+       if (!mfn) {
+               printk(KERN_ERR "ACPI: Unable to allocate memory for saving 
ACPI SLIT numa information.\n");
+               return;
+       }
+       acpi_slit = mfn_to_virt(mfn);
+       memcpy(acpi_slit, slit, slit->header.length);
 }
 
 /* Callback for Proximity Domain -> LAPIC mapping */


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


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


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.