diff options
author | Andi Kleen <ak@suse.de> | 2006-09-26 04:52:33 -0400 |
---|---|---|
committer | Andi Kleen <andi@basil.nowhere.org> | 2006-09-26 04:52:33 -0400 |
commit | 131cfd7bd54767ec8959e013f83839442a54d546 (patch) | |
tree | 25f08ec22a6559939296a1c50c138c96a2d334b5 /arch/x86_64/kernel/vsyscall.c | |
parent | 3bd4d18cbab622c504f131f3c0029c3aa29c05be (diff) |
[PATCH] Add sparse annotation to vsyscall.c
Fixes
linux/arch/x86_64/kernel/vsyscall.c:276:7: warning: constant 0x0f40000000000 is so big it is long
linux/arch/x86_64/kernel/vsyscall.c:80:14: warning: incorrect type in argument 1 (different address spaces)
linux/arch/x86_64/kernel/vsyscall.c:80:14: expected void const volatile [noderef] *addr<asn:2>
linux/arch/x86_64/kernel/vsyscall.c:80:14: got void *<noident>
linux/arch/x86_64/kernel/vsyscall.c:200:7: warning: incorrect type in assignment (different address spaces)
linux/arch/x86_64/kernel/vsyscall.c:200:7: expected unsigned short [usertype] *map1
linux/arch/x86_64/kernel/vsyscall.c:200:7: got void [noderef] *<asn:2>
linux/arch/x86_64/kernel/vsyscall.c:203:7: warning: incorrect type in assignment (different address spaces)
linux/arch/x86_64/kernel/vsyscall.c:203:7: expected unsigned short [usertype] *map2
linux/arch/x86_64/kernel/vsyscall.c:203:7: got void [noderef] *<asn:2>
linux/arch/x86_64/kernel/vsyscall.c:215:10: warning: incorrect type in argument 1 (different address spaces)
linux/arch/x86_64/kernel/vsyscall.c:215:10: expected void volatile [noderef] *addr<asn:2>
linux/arch/x86_64/kernel/vsyscall.c:215:10: got unsigned short [usertype] *map2
linux/arch/x86_64/kernel/vsyscall.c:217:10: warning: incorrect type in argument 1 (different address spaces)
linux/arch/x86_64/kernel/vsyscall.c:217:10: expected void volatile [noderef] *addr<asn:2>
linux/arch/x86_64/kernel/vsyscall.c:217:10: got unsigned short [usertype] *map1
Signed-off-by: Andi Kleen <ak@suse.de>
Diffstat (limited to 'arch/x86_64/kernel/vsyscall.c')
-rw-r--r-- | arch/x86_64/kernel/vsyscall.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/arch/x86_64/kernel/vsyscall.c b/arch/x86_64/kernel/vsyscall.c index 902783bc4d53..ac48c3857ddb 100644 --- a/arch/x86_64/kernel/vsyscall.c +++ b/arch/x86_64/kernel/vsyscall.c | |||
@@ -77,7 +77,8 @@ static __always_inline void do_vgettimeofday(struct timeval * tv) | |||
77 | __vxtime.tsc_quot) >> 32; | 77 | __vxtime.tsc_quot) >> 32; |
78 | /* See comment in x86_64 do_gettimeofday. */ | 78 | /* See comment in x86_64 do_gettimeofday. */ |
79 | } else { | 79 | } else { |
80 | usec += ((readl((void *)fix_to_virt(VSYSCALL_HPET) + 0xf0) - | 80 | usec += ((readl((void __iomem *) |
81 | fix_to_virt(VSYSCALL_HPET) + 0xf0) - | ||
81 | __vxtime.last) * __vxtime.quot) >> 32; | 82 | __vxtime.last) * __vxtime.quot) >> 32; |
82 | } | 83 | } |
83 | } while (read_seqretry(&__xtime_lock, sequence)); | 84 | } while (read_seqretry(&__xtime_lock, sequence)); |
@@ -191,7 +192,8 @@ static int vsyscall_sysctl_change(ctl_table *ctl, int write, struct file * filp, | |||
191 | void __user *buffer, size_t *lenp, loff_t *ppos) | 192 | void __user *buffer, size_t *lenp, loff_t *ppos) |
192 | { | 193 | { |
193 | extern u16 vsysc1, vsysc2; | 194 | extern u16 vsysc1, vsysc2; |
194 | u16 *map1, *map2; | 195 | u16 __iomem *map1; |
196 | u16 __iomem *map2; | ||
195 | int ret = proc_dointvec(ctl, write, filp, buffer, lenp, ppos); | 197 | int ret = proc_dointvec(ctl, write, filp, buffer, lenp, ppos); |
196 | if (!write) | 198 | if (!write) |
197 | return ret; | 199 | return ret; |
@@ -206,11 +208,11 @@ static int vsyscall_sysctl_change(ctl_table *ctl, int write, struct file * filp, | |||
206 | goto out; | 208 | goto out; |
207 | } | 209 | } |
208 | if (!sysctl_vsyscall) { | 210 | if (!sysctl_vsyscall) { |
209 | *map1 = SYSCALL; | 211 | writew(SYSCALL, map1); |
210 | *map2 = SYSCALL; | 212 | writew(SYSCALL, map2); |
211 | } else { | 213 | } else { |
212 | *map1 = NOP2; | 214 | writew(NOP2, map1); |
213 | *map2 = NOP2; | 215 | writew(NOP2, map2); |
214 | } | 216 | } |
215 | iounmap(map2); | 217 | iounmap(map2); |
216 | out: | 218 | out: |