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

[Xen-devel] [PATCH 5/6] xen: Drop empty __devinit annotation, and aliased __pminit



x86 is the only architecture which uses __devinit, and also has CONFIG_HOTPLUG
enabled, making the annotation empty.

Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
---
CC: Jan Beulich <JBeulich@xxxxxxxx>
---
 xen/arch/x86/apic.c         |  6 +++---
 xen/arch/x86/cpu/amd.c      |  6 +++---
 xen/arch/x86/cpu/intel.c    | 10 +++++-----
 xen/arch/x86/i8259.c        |  2 +-
 xen/arch/x86/mpparse.c      |  8 ++++----
 xen/arch/x86/nmi.c          | 12 +++++-------
 xen/arch/x86/setup.c        |  2 +-
 xen/arch/x86/traps.c        |  2 +-
 xen/arch/x86/x86_64/traps.c |  2 +-
 xen/include/xen/init.h      |  2 --
 10 files changed, 24 insertions(+), 28 deletions(-)

diff --git a/xen/arch/x86/apic.c b/xen/arch/x86/apic.c
index 67733c0..b9601ad 100644
--- a/xen/arch/x86/apic.c
+++ b/xen/arch/x86/apic.c
@@ -521,7 +521,7 @@ static void resume_x2apic(void)
         free_ioapic_entries(ioapic_entries);
 }
 
-void __devinit setup_local_APIC(void)
+void setup_local_APIC(void)
 {
     unsigned long oldvalue, value, ver, maxlvt;
     int i, j;
@@ -1087,7 +1087,7 @@ static void __setup_APIC_LVTT(unsigned int clocks)
     apic_write_around(APIC_TMICT, clocks/APIC_DIVISOR);
 }
 
-static void __devinit setup_APIC_timer(void)
+static void setup_APIC_timer(void)
 {
     unsigned long flags;
     local_irq_save(flags);
@@ -1199,7 +1199,7 @@ void __init setup_boot_APIC_clock(void)
     local_irq_restore(flags);
 }
 
-void __devinit setup_secondary_APIC_clock(void)
+void setup_secondary_APIC_clock(void)
 {
     setup_APIC_timer();
 }
diff --git a/xen/arch/x86/cpu/amd.c b/xen/arch/x86/cpu/amd.c
index 3ebcc86..c51aa16 100644
--- a/xen/arch/x86/cpu/amd.c
+++ b/xen/arch/x86/cpu/amd.c
@@ -134,7 +134,7 @@ static const struct cpuidmask *__init noinline 
get_cpuidmask(const char *opt)
  *
  * The processor revision string parameter has precedene.
  */
-static void __devinit set_cpuidmask(const struct cpuinfo_x86 *c)
+static void set_cpuidmask(const struct cpuinfo_x86 *c)
 {
        static unsigned int feat_ecx, feat_edx;
        static unsigned int extfeat_ecx, extfeat_edx;
@@ -383,7 +383,7 @@ static void check_syscfg_dram_mod_en(void)
        wrmsrl(MSR_K8_SYSCFG, syscfg);
 }
 
-static void __devinit amd_get_topology(struct cpuinfo_x86 *c)
+static void amd_get_topology(struct cpuinfo_x86 *c)
 {
         int cpu;
         unsigned bits;
@@ -424,7 +424,7 @@ static void __devinit amd_get_topology(struct cpuinfo_x86 
*c)
                                                          c->cpu_core_id);
 }
 
-static void __devinit init_amd(struct cpuinfo_x86 *c)
+static void init_amd(struct cpuinfo_x86 *c)
 {
        u32 l, h;
 
diff --git a/xen/arch/x86/cpu/intel.c b/xen/arch/x86/cpu/intel.c
index c00657e..b318215 100644
--- a/xen/arch/x86/cpu/intel.c
+++ b/xen/arch/x86/cpu/intel.c
@@ -49,7 +49,7 @@ void set_cpuid_faulting(bool_t enable)
  * edx = 0xBFEBFBFF when executing CPUID.EAX = 1 normally. If you want to
  * 'rev down' to E8400, you can set these values in these Xen boot parameters.
  */
-static void __devinit set_cpuidmask(const struct cpuinfo_x86 *c)
+static void set_cpuidmask(const struct cpuinfo_x86 *c)
 {
        static unsigned int msr_basic, msr_ext, msr_xsave;
        static enum { not_parsed, no_mask, set_mask } status;
@@ -156,7 +156,7 @@ static void __devinit set_cpuidmask(const struct 
cpuinfo_x86 *c)
        }
 }
 
-void __devinit early_intel_workaround(struct cpuinfo_x86 *c)
+void early_intel_workaround(struct cpuinfo_x86 *c)
 {
        if (c->x86_vendor != X86_VENDOR_INTEL)
                return;
@@ -193,7 +193,7 @@ void __devinit early_intel_workaround(struct cpuinfo_x86 *c)
  * Xeon 7400 erratum AAI65 (and further newer Xeons)
  * MONITOR/MWAIT may have excessive false wakeups
  */
-static void __devinit Intel_errata_workarounds(struct cpuinfo_x86 *c)
+static void Intel_errata_workarounds(struct cpuinfo_x86 *c)
 {
        unsigned long lo, hi;
 
@@ -216,7 +216,7 @@ static void __devinit Intel_errata_workarounds(struct 
cpuinfo_x86 *c)
 /*
  * find out the number of processor cores on the die
  */
-static int __devinit num_cpu_cores(struct cpuinfo_x86 *c)
+static int num_cpu_cores(struct cpuinfo_x86 *c)
 {
        unsigned int eax, ebx, ecx, edx;
 
@@ -231,7 +231,7 @@ static int __devinit num_cpu_cores(struct cpuinfo_x86 *c)
                return 1;
 }
 
-static void __devinit init_intel(struct cpuinfo_x86 *c)
+static void init_intel(struct cpuinfo_x86 *c)
 {
        unsigned int l2 = 0;
 
diff --git a/xen/arch/x86/i8259.c b/xen/arch/x86/i8259.c
index c2c9005..aa266c2 100644
--- a/xen/arch/x86/i8259.c
+++ b/xen/arch/x86/i8259.c
@@ -283,7 +283,7 @@ int i8259A_suspend(void)
     return 0;
 }
 
-void __devinit init_8259A(int auto_eoi)
+void init_8259A(int auto_eoi)
 {
     unsigned long flags;
 
diff --git a/xen/arch/x86/mpparse.c b/xen/arch/x86/mpparse.c
index 497a4e9..22b11fb 100644
--- a/xen/arch/x86/mpparse.c
+++ b/xen/arch/x86/mpparse.c
@@ -124,8 +124,8 @@ static int __init mpf_checksum(unsigned char *mp, int len)
 }
 
 /* Return xen's logical cpu_id of the new added cpu or <0 if error */
-static int __devinit MP_processor_info_x(struct mpc_config_processor *m,
-                                        u32 apicid, bool_t hotplug)
+static int MP_processor_info_x(struct mpc_config_processor *m,
+                              u32 apicid, bool_t hotplug)
 {
        int ver, cpu = 0;
        
@@ -190,7 +190,7 @@ static int __devinit MP_processor_info_x(struct 
mpc_config_processor *m,
        return cpu;
 }
 
-static int __devinit MP_processor_info(struct mpc_config_processor *m)
+static int MP_processor_info(struct mpc_config_processor *m)
 {
        return MP_processor_info_x(m, m->mpc_apicid, 0);
 }
@@ -787,7 +787,7 @@ void __init mp_register_lapic_address (
 }
 
 
-int __devinit mp_register_lapic (
+int mp_register_lapic (
        u32                     id,
        bool_t                  enabled,
        bool_t                  hotplug)
diff --git a/xen/arch/x86/nmi.c b/xen/arch/x86/nmi.c
index 7520454..b1195a1 100644
--- a/xen/arch/x86/nmi.c
+++ b/xen/arch/x86/nmi.c
@@ -254,14 +254,12 @@ void release_lapic_nmi(void)
         enable_lapic_nmi_watchdog();
 }
 
-#define __pminit __devinit
-
 /*
  * Activate the NMI watchdog via the local APIC.
  * Original code written by Keith Owens.
  */
 
-static void __pminit clear_msr_range(unsigned int base, unsigned int n)
+static void clear_msr_range(unsigned int base, unsigned int n)
 {
     unsigned int i;
 
@@ -279,7 +277,7 @@ static inline void write_watchdog_counter(const char *descr)
     wrmsrl(nmi_perfctr_msr, 0 - count);
 }
 
-static void __pminit setup_k7_watchdog(void)
+static void setup_k7_watchdog(void)
 {
     unsigned int evntsel;
 
@@ -300,7 +298,7 @@ static void __pminit setup_k7_watchdog(void)
     wrmsr(MSR_K7_EVNTSEL0, evntsel, 0);
 }
 
-static void __pminit setup_p6_watchdog(unsigned counter)
+static void setup_p6_watchdog(unsigned counter)
 {
     unsigned int evntsel;
 
@@ -321,7 +319,7 @@ static void __pminit setup_p6_watchdog(unsigned counter)
     wrmsr(MSR_P6_EVNTSEL(0), evntsel, 0);
 }
 
-static int __pminit setup_p4_watchdog(void)
+static int setup_p4_watchdog(void)
 {
     uint64_t misc_enable;
 
@@ -359,7 +357,7 @@ static int __pminit setup_p4_watchdog(void)
     return 1;
 }
 
-void __pminit setup_apic_nmi_watchdog(void)
+void setup_apic_nmi_watchdog(void)
 {
     if ( nmi_watchdog == NMI_NONE )
         return;
diff --git a/xen/arch/x86/setup.c b/xen/arch/x86/setup.c
index 6714473..76c7b0f 100644
--- a/xen/arch/x86/setup.c
+++ b/xen/arch/x86/setup.c
@@ -195,7 +195,7 @@ static void __init init_idle_domain(void)
     this_cpu(curr_vcpu) = current;
 }
 
-void __devinit srat_detect_node(int cpu)
+void srat_detect_node(int cpu)
 {
     nodeid_t node;
     u32 apicid = x86_cpu_to_apicid[cpu];
diff --git a/xen/arch/x86/traps.c b/xen/arch/x86/traps.c
index d29f828..e103834 100644
--- a/xen/arch/x86/traps.c
+++ b/xen/arch/x86/traps.c
@@ -3616,7 +3616,7 @@ void load_TR(void)
         : "=m" (old_gdt) : "rm" (TSS_ENTRY << 3), "m" (tss_gdt) : "memory" );
 }
 
-void __devinit percpu_traps_init(void)
+void percpu_traps_init(void)
 {
     subarch_percpu_traps_init();
 
diff --git a/xen/arch/x86/x86_64/traps.c b/xen/arch/x86/x86_64/traps.c
index b7c2759..26e2dd7 100644
--- a/xen/arch/x86/x86_64/traps.c
+++ b/xen/arch/x86/x86_64/traps.c
@@ -371,7 +371,7 @@ DEFINE_PER_CPU(struct stubs, stubs);
 void lstar_enter(void);
 void cstar_enter(void);
 
-void __devinit subarch_percpu_traps_init(void)
+void subarch_percpu_traps_init(void)
 {
     unsigned long stack_bottom = get_stack_bottom();
     unsigned long stub_va = this_cpu(stubs.addr);
diff --git a/xen/include/xen/init.h b/xen/include/xen/init.h
index e411736..17fe550 100644
--- a/xen/include/xen/init.h
+++ b/xen/include/xen/init.h
@@ -118,11 +118,9 @@ extern struct kernel_param __setup_start, __setup_end;
 #endif /* __ASSEMBLY__ */
 
 #ifdef CONFIG_HOTPLUG
-#define __devinit
 #define __devexit
 #define __devexitdata
 #else
-#define __devinit __init
 #define __devexit __exit
 #define __devexitdata __exitdata
 #endif
-- 
2.1.4


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

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