x86: remove mach_apicdef.h
authorIngo Molnar <mingo@elte.hu>
Wed, 28 Jan 2009 16:36:56 +0000 (17:36 +0100)
committerIngo Molnar <mingo@elte.hu>
Wed, 28 Jan 2009 22:20:36 +0000 (23:20 +0100)
Move its definitions into apic.h.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
arch/x86/include/asm/apic.h
arch/x86/include/asm/mach-default/mach_apic.h
arch/x86/include/asm/mach-default/mach_apicdef.h [deleted file]
arch/x86/include/asm/mach-generic/mach_apicdef.h [deleted file]
arch/x86/include/asm/smp.h
arch/x86/kernel/apic.c
arch/x86/kernel/genapic_flat_64.c
arch/x86/kernel/io_apic.c
arch/x86/kernel/mpparse.c
arch/x86/mach-generic/default.c

index e8f030440bc723e1ec7c453eb441292e0eaa5a0f..3a3202074c638d1d9f54241074a1f360e75dbd1c 100644 (file)
@@ -211,4 +211,20 @@ static inline void disable_local_APIC(void) { }
 
 #endif /* !CONFIG_X86_LOCAL_APIC */
 
+#ifdef CONFIG_X86_64
+#define        SET_APIC_ID(x)          (apic->set_apic_id(x))
+#else
+
+static inline unsigned default_get_apic_id(unsigned long x) 
+{
+       unsigned int ver = GET_APIC_VERSION(apic_read(APIC_LVR));
+
+       if (APIC_XAPIC(ver))
+               return (x >> 24) & 0xFF;
+       else
+               return (x >> 24) & 0x0F;
+}
+
+#endif
+
 #endif /* _ASM_X86_APIC_H */
index 2e4104cf3481fb6415dffe8539eacd55b4fa993f..b60b767d5be09726dc649539a66f98e5266a2321 100644 (file)
@@ -3,7 +3,6 @@
 
 #ifdef CONFIG_X86_LOCAL_APIC
 
-#include <mach_apicdef.h>
 #include <asm/smp.h>
 
 #define APIC_DFR_VALUE (APIC_DFR_FLAT)
diff --git a/arch/x86/include/asm/mach-default/mach_apicdef.h b/arch/x86/include/asm/mach-default/mach_apicdef.h
deleted file mode 100644 (file)
index 5141085..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-#ifndef _ASM_X86_MACH_DEFAULT_MACH_APICDEF_H
-#define _ASM_X86_MACH_DEFAULT_MACH_APICDEF_H
-
-#include <asm/apic.h>
-
-#ifdef CONFIG_X86_64
-#define        SET_APIC_ID(x)          (apic->set_apic_id(x))
-#else
-
-static inline unsigned default_get_apic_id(unsigned long x) 
-{
-       unsigned int ver = GET_APIC_VERSION(apic_read(APIC_LVR));
-
-       if (APIC_XAPIC(ver))
-               return (x >> 24) & 0xFF;
-       else
-               return (x >> 24) & 0x0F;
-} 
-
-#endif
-
-#endif /* _ASM_X86_MACH_DEFAULT_MACH_APICDEF_H */
diff --git a/arch/x86/include/asm/mach-generic/mach_apicdef.h b/arch/x86/include/asm/mach-generic/mach_apicdef.h
deleted file mode 100644 (file)
index 61caa65..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-#ifndef _ASM_X86_MACH_GENERIC_MACH_APICDEF_H
-#define _ASM_X86_MACH_GENERIC_MACH_APICDEF_H
-
-#ifndef APIC_DEFINITION
-#include <asm/genapic.h>
-#endif
-
-#endif /* _ASM_X86_MACH_GENERIC_MACH_APICDEF_H */
index c63d480802af0df3556cd5fa8085f6ab6292e12a..d4ac4de4bceced7b2c63627b07671b40caa6ef03 100644 (file)
@@ -173,6 +173,8 @@ extern int safe_smp_processor_id(void);
 
 #endif
 
+#include <asm/genapic.h>
+
 #ifdef CONFIG_X86_LOCAL_APIC
 
 #ifndef CONFIG_X86_64
@@ -182,7 +184,6 @@ static inline int logical_smp_processor_id(void)
        return GET_APIC_LOGICAL_ID(*(u32 *)(APIC_BASE + APIC_LDR));
 }
 
-#include <mach_apicdef.h>
 static inline unsigned int read_apic_id(void)
 {
        unsigned int reg;
@@ -197,7 +198,6 @@ static inline unsigned int read_apic_id(void)
 # if defined(APIC_DEFINITION) || defined(CONFIG_X86_64)
 extern int hard_smp_processor_id(void);
 # else
-#include <mach_apicdef.h>
 static inline int hard_smp_processor_id(void)
 {
        /* we don't want to mark this access volatile - bad code generation */
index 84b8e7c57abc6487ab210a763dd1f2e743ab4d2e..e6220809ca11730061320fe500d9cd424faa683e 100644 (file)
@@ -50,7 +50,6 @@
 #include <asm/smp.h>
 
 #include <mach_apic.h>
-#include <mach_apicdef.h>
 #include <mach_ipi.h>
 
 /*
index e9237f5992826b4818c40f31ec91441a6c2eb353..19bffb3f732035b6ff4b190aa8ca49d73a36af72 100644 (file)
@@ -19,7 +19,6 @@
 #include <asm/smp.h>
 #include <asm/ipi.h>
 #include <asm/genapic.h>
-#include <mach_apicdef.h>
 
 #ifdef CONFIG_ACPI
 #include <acpi/acpi_bus.h>
index e90970ce21a062a02d5a957f70f2c741e90910f6..abae81989c2fb6789e011fcdb0aa1c03a41e45dd 100644 (file)
@@ -64,7 +64,6 @@
 
 #include <mach_ipi.h>
 #include <mach_apic.h>
-#include <mach_apicdef.h>
 
 #define __apicdebuginit(type) static type __init
 
index c6930162b3be028926795b0378032829944715b7..a1452a53d14f35e0ec1f63e5e7c6df7d2ad68a0d 100644 (file)
@@ -30,9 +30,6 @@
 #include <asm/smp.h>
 
 #include <mach_apic.h>
-#ifdef CONFIG_X86_32
-#include <mach_apicdef.h>
-#endif
 
 /*
  * Checksum an MP configuration block.
index 6485e57e29b1cdd83acb617a105640ec13119cca..07817b2a78766672f0064060aaafd17fb8af30c4 100644 (file)
@@ -5,7 +5,6 @@
 #include <linux/threads.h>
 #include <linux/cpumask.h>
 #include <asm/mpspec.h>
-#include <asm/mach-default/mach_apicdef.h>
 #include <asm/genapic.h>
 #include <asm/fixmap.h>
 #include <asm/apicdef.h>