aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/x86/kernel/apic_32.c4
-rw-r--r--arch/x86/lguest/boot.c4
-rw-r--r--arch/x86/xen/enlighten.c4
-rw-r--r--include/asm-x86/apic_32.h16
-rw-r--r--include/asm-x86/apic_64.h6
-rw-r--r--include/asm-x86/paravirt.h12
6 files changed, 22 insertions, 24 deletions
diff --git a/arch/x86/kernel/apic_32.c b/arch/x86/kernel/apic_32.c
index a56c782653be..3a069acb270c 100644
--- a/arch/x86/kernel/apic_32.c
+++ b/arch/x86/kernel/apic_32.c
@@ -135,9 +135,9 @@ void apic_wait_icr_idle(void)
135 cpu_relax(); 135 cpu_relax();
136} 136}
137 137
138unsigned long safe_apic_wait_icr_idle(void) 138u32 safe_apic_wait_icr_idle(void)
139{ 139{
140 unsigned long send_status; 140 u32 send_status;
141 int timeout; 141 int timeout;
142 142
143 timeout = 0; 143 timeout = 0;
diff --git a/arch/x86/lguest/boot.c b/arch/x86/lguest/boot.c
index 92c56117eae5..df04bf884dd4 100644
--- a/arch/x86/lguest/boot.c
+++ b/arch/x86/lguest/boot.c
@@ -788,11 +788,11 @@ static void lguest_wbinvd(void)
788 * code qualifies for Advanced. It will also never interrupt anything. It 788 * code qualifies for Advanced. It will also never interrupt anything. It
789 * does, however, allow us to get through the Linux boot code. */ 789 * does, however, allow us to get through the Linux boot code. */
790#ifdef CONFIG_X86_LOCAL_APIC 790#ifdef CONFIG_X86_LOCAL_APIC
791static void lguest_apic_write(unsigned long reg, unsigned long v) 791static void lguest_apic_write(unsigned long reg, u32 v)
792{ 792{
793} 793}
794 794
795static unsigned long lguest_apic_read(unsigned long reg) 795static u32 lguest_apic_read(unsigned long reg)
796{ 796{
797 return 0; 797 return 0;
798} 798}
diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c
index 79ad15252150..00829401389e 100644
--- a/arch/x86/xen/enlighten.c
+++ b/arch/x86/xen/enlighten.c
@@ -521,12 +521,12 @@ static void xen_io_delay(void)
521} 521}
522 522
523#ifdef CONFIG_X86_LOCAL_APIC 523#ifdef CONFIG_X86_LOCAL_APIC
524static unsigned long xen_apic_read(unsigned long reg) 524static u32 xen_apic_read(unsigned long reg)
525{ 525{
526 return 0; 526 return 0;
527} 527}
528 528
529static void xen_apic_write(unsigned long reg, unsigned long val) 529static void xen_apic_write(unsigned long reg, u32 val)
530{ 530{
531 /* Warn to see if there's any stray references */ 531 /* Warn to see if there's any stray references */
532 WARN_ON(1); 532 WARN_ON(1);
diff --git a/include/asm-x86/apic_32.h b/include/asm-x86/apic_32.h
index f909e2daf226..649e9a6f6683 100644
--- a/include/asm-x86/apic_32.h
+++ b/include/asm-x86/apic_32.h
@@ -51,25 +51,23 @@ extern int local_apic_timer_disabled;
51#define setup_secondary_clock setup_secondary_APIC_clock 51#define setup_secondary_clock setup_secondary_APIC_clock
52#endif 52#endif
53 53
54static __inline fastcall void native_apic_write(unsigned long reg, 54static __inline fastcall void native_apic_write(unsigned long reg, u32 v)
55 unsigned long v)
56{ 55{
57 *((volatile unsigned long *)(APIC_BASE+reg)) = v; 56 *((volatile u32 *)(APIC_BASE + reg)) = v;
58} 57}
59 58
60static __inline fastcall void native_apic_write_atomic(unsigned long reg, 59static __inline fastcall void native_apic_write_atomic(unsigned long reg, u32 v)
61 unsigned long v)
62{ 60{
63 xchg((volatile unsigned long *)(APIC_BASE+reg), v); 61 (void) xchg((u32 *)(APIC_BASE + reg), v);
64} 62}
65 63
66static __inline fastcall unsigned long native_apic_read(unsigned long reg) 64static __inline fastcall u32 native_apic_read(unsigned long reg)
67{ 65{
68 return *((volatile unsigned long *)(APIC_BASE+reg)); 66 return *((volatile u32 *)(APIC_BASE + reg));
69} 67}
70 68
71extern void apic_wait_icr_idle(void); 69extern void apic_wait_icr_idle(void);
72extern unsigned long safe_apic_wait_icr_idle(void); 70extern u32 safe_apic_wait_icr_idle(void);
73extern int get_physical_broadcast(void); 71extern int get_physical_broadcast(void);
74 72
75#ifdef CONFIG_X86_GOOD_APIC 73#ifdef CONFIG_X86_GOOD_APIC
diff --git a/include/asm-x86/apic_64.h b/include/asm-x86/apic_64.h
index 7bfad0224178..9d0c06c4df91 100644
--- a/include/asm-x86/apic_64.h
+++ b/include/asm-x86/apic_64.h
@@ -38,14 +38,14 @@ struct pt_regs;
38 * Basic functions accessing APICs. 38 * Basic functions accessing APICs.
39 */ 39 */
40 40
41static __inline void apic_write(unsigned long reg, unsigned int v) 41static __inline void apic_write(unsigned long reg, u32 v)
42{ 42{
43 *((volatile unsigned int *)(APIC_BASE+reg)) = v; 43 *((volatile unsigned int *)(APIC_BASE+reg)) = v;
44} 44}
45 45
46static __inline unsigned int apic_read(unsigned long reg) 46static __inline u32 apic_read(unsigned long reg)
47{ 47{
48 return *((volatile unsigned int *)(APIC_BASE+reg)); 48 return *((volatile u32 *)(APIC_BASE+reg));
49} 49}
50 50
51extern void apic_wait_icr_idle(void); 51extern void apic_wait_icr_idle(void);
diff --git a/include/asm-x86/paravirt.h b/include/asm-x86/paravirt.h
index f59d370c5df4..19fd3e67b08c 100644
--- a/include/asm-x86/paravirt.h
+++ b/include/asm-x86/paravirt.h
@@ -150,9 +150,9 @@ struct pv_apic_ops {
150 * Direct APIC operations, principally for VMI. Ideally 150 * Direct APIC operations, principally for VMI. Ideally
151 * these shouldn't be in this interface. 151 * these shouldn't be in this interface.
152 */ 152 */
153 void (*apic_write)(unsigned long reg, unsigned long v); 153 void (*apic_write)(unsigned long reg, u32 v);
154 void (*apic_write_atomic)(unsigned long reg, unsigned long v); 154 void (*apic_write_atomic)(unsigned long reg, u32 v);
155 unsigned long (*apic_read)(unsigned long reg); 155 u32 (*apic_read)(unsigned long reg);
156 void (*setup_boot_clock)(void); 156 void (*setup_boot_clock)(void);
157 void (*setup_secondary_clock)(void); 157 void (*setup_secondary_clock)(void);
158 158
@@ -690,17 +690,17 @@ static inline void slow_down_io(void) {
690/* 690/*
691 * Basic functions accessing APICs. 691 * Basic functions accessing APICs.
692 */ 692 */
693static inline void apic_write(unsigned long reg, unsigned long v) 693static inline void apic_write(unsigned long reg, u32 v)
694{ 694{
695 PVOP_VCALL2(pv_apic_ops.apic_write, reg, v); 695 PVOP_VCALL2(pv_apic_ops.apic_write, reg, v);
696} 696}
697 697
698static inline void apic_write_atomic(unsigned long reg, unsigned long v) 698static inline void apic_write_atomic(unsigned long reg, u32 v)
699{ 699{
700 PVOP_VCALL2(pv_apic_ops.apic_write_atomic, reg, v); 700 PVOP_VCALL2(pv_apic_ops.apic_write_atomic, reg, v);
701} 701}
702 702
703static inline unsigned long apic_read(unsigned long reg) 703static inline u32 apic_read(unsigned long reg)
704{ 704{
705 return PVOP_CALL1(unsigned long, pv_apic_ops.apic_read, reg); 705 return PVOP_CALL1(unsigned long, pv_apic_ops.apic_read, reg);
706} 706}