x86, es7000: clean up es7000_enable_apic_mode()
authorIngo Molnar <mingo@elte.hu>
Wed, 28 Jan 2009 12:15:06 +0000 (13:15 +0100)
committerIngo Molnar <mingo@elte.hu>
Wed, 28 Jan 2009 22:20:26 +0000 (23:20 +0100)
- eliminate the needless es7000_enable_apic_mode() complication which
  was not apparent prior the namespace cleanups

- clean up the control flow in es7000_enable_apic_mode()

- other cleanups

Signed-off-by: Ingo Molnar <mingo@elte.hu>
arch/x86/include/asm/es7000/apic.h
arch/x86/kernel/es7000_32.c
arch/x86/mach-generic/es7000.c

index 717c27f8da61f05ef87e69fff0ab9097308d38a6..038c4f0e480b760474190065b01c3edf0727c2ce 100644 (file)
@@ -36,6 +36,8 @@ static inline unsigned long es7000_check_apicid_present(int bit)
        return physid_isset(bit, phys_cpu_present_map);
 }
 
+extern void es7000_enable_apic_mode(void);
+
 #define apicid_cluster(apicid) (apicid & 0xF0)
 
 static inline unsigned long calculate_ldr(int cpu)
index 20a2a43c2a9c19aa255b1190b172cebb92e79c71..e73fe18488ac5c9c6d7b2527a8e8dda28b5f8988 100644 (file)
@@ -359,20 +359,21 @@ es7000_mip_write(struct mip_reg *mip_reg)
        return status;
 }
 
-void __init
-es7000_sw_apic(void)
+void __init es7000_enable_apic_mode(void)
 {
-       if (es7000_plat) {
-               int mip_status;
-               struct mip_reg es7000_mip_reg;
-
-               printk("ES7000: Enabling APIC mode.\n");
-               memset(&es7000_mip_reg, 0, sizeof(struct mip_reg));
-               es7000_mip_reg.off_0 = MIP_SW_APIC;
-               es7000_mip_reg.off_38 = (MIP_VALID);
-               while ((mip_status = es7000_mip_write(&es7000_mip_reg)) != 0)
-                       printk("es7000_sw_apic: command failed, status = %x\n",
-                               mip_status);
+       struct mip_reg es7000_mip_reg;
+       int mip_status;
+
+       if (!es7000_plat)
                return;
+
+       printk("ES7000: Enabling APIC mode.\n");
+               memset(&es7000_mip_reg, 0, sizeof(struct mip_reg));
+               es7000_mip_reg.off_0 = MIP_SW_APIC;
+               es7000_mip_reg.off_38 = MIP_VALID;
+
+               while ((mip_status = es7000_mip_write(&es7000_mip_reg)) != 0) {
+               printk("es7000_enable_apic_mode: command failed, status = %x\n",
+                       mip_status);
        }
 }
index 9acb71120ef61164a838b11b0f8f5a47acf472c1..1185964b7a336fbec1e719f434eb473c0dd4362f 100644 (file)
@@ -35,13 +35,6 @@ static int probe_es7000(void)
        return 0;
 }
 
-extern void es7000_sw_apic(void);
-
-static void __init es7000_enable_apic_mode(void)
-{
-       es7000_sw_apic();
-}
-
 static __init int
 mps_oem_check(struct mpc_table *mpc, char *oem, char *productid)
 {
This page took 0.026778 seconds and 5 git commands to generate.