]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
x86: two trivial sparse annotations
authorHarvey Harrison <harvey.harrison@gmail.com>
Wed, 29 Oct 2008 06:05:22 +0000 (23:05 -0700)
committerIngo Molnar <mingo@elte.hu>
Wed, 29 Oct 2008 07:02:28 +0000 (08:02 +0100)
Impact: fewer sparse warnings, no functional changes

arch/x86/kernel/vsmp_64.c:87:14: warning: incorrect type in argument 1 (different address spaces)
arch/x86/kernel/vsmp_64.c:87:14:    expected void const volatile [noderef] <asn:2>*addr
arch/x86/kernel/vsmp_64.c:87:14:    got void *[assigned] address
arch/x86/kernel/vsmp_64.c:88:22: warning: incorrect type in argument 1 (different address spaces)
arch/x86/kernel/vsmp_64.c:88:22:    expected void const volatile [noderef] <asn:2>*addr
arch/x86/kernel/vsmp_64.c:88:22:    got void *
arch/x86/kernel/vsmp_64.c:100:23: warning: incorrect type in argument 2 (different address spaces)
arch/x86/kernel/vsmp_64.c:100:23:    expected void volatile [noderef] <asn:2>*addr
arch/x86/kernel/vsmp_64.c:100:23:    got void *
arch/x86/kernel/vsmp_64.c:101:23: warning: incorrect type in argument 1 (different address spaces)
arch/x86/kernel/vsmp_64.c:101:23:    expected void const volatile [noderef] <asn:2>*addr
arch/x86/kernel/vsmp_64.c:101:23:    got void *
arch/x86/mm/gup.c:235:6: warning: incorrect type in argument 1 (different base types)
arch/x86/mm/gup.c:235:6:    expected void const volatile [noderef] <asn:1>*<noident>
arch/x86/mm/gup.c:235:6:    got unsigned long [unsigned] [assigned] start

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
arch/x86/kernel/vsmp_64.c
arch/x86/mm/gup.c

index 7766d36983fcd7440f82435bcfbbcd37c1d80a6b..a688f3bfaec2df184760f836dda4947edede828d 100644 (file)
@@ -78,7 +78,7 @@ static unsigned __init_or_module vsmp_patch(u8 type, u16 clobbers, void *ibuf,
 
 static void __init set_vsmp_pv_ops(void)
 {
-       void *address;
+       void __iomem *address;
        unsigned int cap, ctl, cfg;
 
        /* set vSMP magic bits to indicate vSMP capable kernel */
index 4ba373c5b8c8b94eec4902f2ec3f1448b8b1f6af..be54176e9eb2ee3fa374d6bdc55ed917a4ea4106 100644 (file)
@@ -233,7 +233,7 @@ int get_user_pages_fast(unsigned long start, int nr_pages, int write,
        len = (unsigned long) nr_pages << PAGE_SHIFT;
        end = start + len;
        if (unlikely(!access_ok(write ? VERIFY_WRITE : VERIFY_READ,
-                                       start, len)))
+                                       (void __user *)start, len)))
                goto slow_irqon;
 
        /*