Browse Source

x86: apic - unify lapic_is_integrated

Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Cyrill Gorcunov 17 years ago
parent
commit
9c803869f5
2 changed files with 9 additions and 1 deletions
  1. 4 0
      arch/x86/kernel/apic_32.c
  2. 5 1
      arch/x86/kernel/apic_64.c

+ 4 - 0
arch/x86/kernel/apic_32.c

@@ -128,7 +128,11 @@ static inline int lapic_get_version(void)
  */
 static inline int lapic_is_integrated(void)
 {
+#ifdef CONFIG_X86_64
+	return 1;
+#else
 	return APIC_INTEGRATED(lapic_get_version());
+#endif
 }
 
 /*

+ 5 - 1
arch/x86/kernel/apic_64.c

@@ -111,11 +111,15 @@ static inline int lapic_get_version(void)
 }
 
 /*
- * Check, if the APIC is integrated or a seperate chip
+ * Check, if the APIC is integrated or a separate chip
  */
 static inline int lapic_is_integrated(void)
 {
+#ifdef CONFIG_X86_64
 	return 1;
+#else
+	return APIC_INTEGRATED(lapic_get_version());
+#endif
 }
 
 /*