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

[Xen-changelog] linux: clean up setup_arch_post.h



# HG changeset patch
# User cl349@xxxxxxxxxxxxxxxxxxxx
# Node ID 5ef601da9c2c79fd11bd265b5b36561a9b0a2950
# Parent  cfbf7332d616da0b0118e4e92f3feb73ada82919
linux: clean up setup_arch_post.h
- machine_specific_memory_setup() was unused on x86-64
- machine_specific_modify_cpu_capabilities() must not be __init (for CPU 
hotplug)
- machine_specific_modify_cpu_capabilities() should be called in similar ways 
on 32- and 64-bits

From: Jan Beulich <JBeulich@xxxxxxxxxx>
Signed-off-by: Christian Limpach <Christian.Limpach@xxxxxxxxxxxx>

diff -r cfbf7332d616 -r 5ef601da9c2c 
linux-2.6-xen-sparse/arch/x86_64/kernel/setup-xen.c
--- a/linux-2.6-xen-sparse/arch/x86_64/kernel/setup-xen.c       Thu Mar  2 
15:06:51 2006
+++ b/linux-2.6-xen-sparse/arch/x86_64/kernel/setup-xen.c       Thu Mar  2 
15:33:47 2006
@@ -82,6 +82,8 @@
 extern unsigned long start_pfn;
 extern struct edid_info edid_info;
 
+extern void machine_specific_modify_cpu_capabilities(struct cpuinfo_x86 *c);
+
 shared_info_t *HYPERVISOR_shared_info = (shared_info_t *)empty_zero_page;
 EXPORT_SYMBOL(HYPERVISOR_shared_info);
 
@@ -1405,6 +1407,8 @@
        select_idle_routine(c);
        detect_ht(c); 
 
+       machine_specific_modify_cpu_capabilities(c);
+
        /*
         * On SMP, boot_cpu_data holds the common feature set between
         * all CPUs; so make sure that we indicate which features are
diff -r cfbf7332d616 -r 5ef601da9c2c 
linux-2.6-xen-sparse/include/asm-i386/mach-xen/setup_arch_post.h
--- a/linux-2.6-xen-sparse/include/asm-i386/mach-xen/setup_arch_post.h  Thu Mar 
 2 15:06:51 2006
+++ b/linux-2.6-xen-sparse/include/asm-i386/mach-xen/setup_arch_post.h  Thu Mar 
 2 15:33:47 2006
@@ -16,7 +16,7 @@
        return "Xen";
 }
 
-void __init machine_specific_modify_cpu_capabilities(struct cpuinfo_x86 *c)
+void __devinit machine_specific_modify_cpu_capabilities(struct cpuinfo_x86 *c)
 {
        clear_bit(X86_FEATURE_VME, c->x86_capability);
        clear_bit(X86_FEATURE_DE, c->x86_capability);
diff -r cfbf7332d616 -r 5ef601da9c2c 
linux-2.6-xen-sparse/include/asm-x86_64/mach-xen/setup_arch_post.h
--- a/linux-2.6-xen-sparse/include/asm-x86_64/mach-xen/setup_arch_post.h        
Thu Mar  2 15:06:51 2006
+++ b/linux-2.6-xen-sparse/include/asm-x86_64/mach-xen/setup_arch_post.h        
Thu Mar  2 15:33:47 2006
@@ -1,28 +1,12 @@
 /**
- * machine_specific_memory_setup - Hook for machine specific memory setup.
+ * machine_specific_* - Hooks for machine specific setup.
  *
  * Description:
  *     This is included late in kernel/setup.c so that it can make
  *     use of all of the static functions.
  **/
 
-static char * __init machine_specific_memory_setup(void)
-{
-       char *who;
-       unsigned long start_pfn, max_pfn;
-
-       who = "Xen";
-
-       start_pfn = 0;
-       max_pfn = xen_start_info->nr_pages;
-
-       e820.nr_map = 0;
-       add_memory_region(PFN_PHYS(start_pfn), PFN_PHYS(max_pfn) - 
PFN_PHYS(start_pfn), E820_RAM);
-
-       return who;
-}
-
-void __init machine_specific_modify_cpu_capabilities(struct cpuinfo_x86 *c)
+void __cpuinit machine_specific_modify_cpu_capabilities(struct cpuinfo_x86 *c)
 {
        clear_bit(X86_FEATURE_VME, c->x86_capability);
        clear_bit(X86_FEATURE_DE, c->x86_capability);

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


 


Rackspace

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