aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/vmi_32.c
diff options
context:
space:
mode:
authorYinghai Lu <yhlu.kernel@gmail.com>2008-07-14 01:19:35 -0400
committerIngo Molnar <mingo@elte.hu>2008-07-14 03:02:54 -0400
commit94a8c3c2437c8946f1b6c8e0b2c560a7db8ed3c6 (patch)
tree7bad615005b6047306336e8f688edcf1c6bb74dd /arch/x86/kernel/vmi_32.c
parentf910a9dc7c865896815e2a95fe33363e9522f277 (diff)
x86: let 32bit use apic_ops too - fix
fix for pv - clean up the namespace there too. Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com> Cc: Suresh Siddha <suresh.b.siddha@intel.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/vmi_32.c')
-rw-r--r--arch/x86/kernel/vmi_32.c51
1 files changed, 48 insertions, 3 deletions
diff --git a/arch/x86/kernel/vmi_32.c b/arch/x86/kernel/vmi_32.c
index b15346092b7b..cf3074354553 100644
--- a/arch/x86/kernel/vmi_32.c
+++ b/arch/x86/kernel/vmi_32.c
@@ -676,6 +676,50 @@ static inline int __init probe_vmi_rom(void)
676 return 0; 676 return 0;
677} 677}
678 678
679#ifdef CONFIG_X86_LOCAL_APIC
680static u32 vmi_apic_read(u32 reg)
681{
682 return 0;
683}
684
685static void vmi_apic_write(u32 reg, u32 val)
686{
687 /* Warn to see if there's any stray references */
688 WARN_ON(1);
689}
690
691static u64 vmi_apic_icr_read(void)
692{
693 return 0;
694}
695
696static void vmi_apic_icr_write(u32 low, u32 id)
697{
698 /* Warn to see if there's any stray references */
699 WARN_ON(1);
700}
701
702static void vmi_apic_wait_icr_idle(void)
703{
704 return;
705}
706
707static u32 vmi_safe_apic_wait_icr_idle(void)
708{
709 return 0;
710}
711
712static struct apic_ops vmi_basic_apic_ops = {
713 .read = vmi_apic_read,
714 .write = vmi_apic_write,
715 .write_atomic = vmi_apic_write,
716 .icr_read = vmi_apic_icr_read,
717 .icr_write = vmi_apic_icr_write,
718 .wait_icr_idle = vmi_apic_wait_icr_idle,
719 .safe_wait_icr_idle = vmi_safe_apic_wait_icr_idle,
720};
721#endif
722
679/* 723/*
680 * VMI setup common to all processors 724 * VMI setup common to all processors
681 */ 725 */
@@ -904,9 +948,10 @@ static inline int __init activate_vmi(void)
904#endif 948#endif
905 949
906#ifdef CONFIG_X86_LOCAL_APIC 950#ifdef CONFIG_X86_LOCAL_APIC
907 para_fill(pv_apic_ops.apic_read, APICRead); 951 para_fill(vmi_basic_apic_ops.read, APICRead);
908 para_fill(pv_apic_ops.apic_write, APICWrite); 952 para_fill(vmi_basic_apic_ops.write, APICWrite);
909 para_fill(pv_apic_ops.apic_write_atomic, APICWrite); 953 para_fill(vmi_basic_apic_ops.write_atomic, APICWrite);
954 apic_ops = &vmi_basic_apic_ops;
910#endif 955#endif
911 956
912 /* 957 /*