]> Git Repo - linux.git/commitdiff
x86/shstk: Change order of __user in type
authorRick Edgecombe <[email protected]>
Fri, 25 Aug 2023 01:45:54 +0000 (18:45 -0700)
committerDave Hansen <[email protected]>
Wed, 30 Aug 2023 17:35:53 +0000 (10:35 -0700)
0day reports a sparse warning:
arch/x86/kernel/shstk.c:295:55: sparse: sparse: cast removes address space
'__user' of expression

The __user is in the wrong spot. Move it to right spot and make sparse
happy.

Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/
Reported-by: kernel test robot <[email protected]>
Signed-off-by: Rick Edgecombe <[email protected]>
Signed-off-by: Dave Hansen <[email protected]>
Link: https://lore.kernel.org/all/20230825014554.1769194-1-rick.p.edgecombe%40intel.com
arch/x86/kernel/shstk.c

index cd10d074a44442d7efe39ecc85277e5231ee84f1..fd689921a1dbad3c4036132d977d9b4bee438b98 100644 (file)
@@ -275,7 +275,7 @@ static int shstk_push_sigframe(unsigned long *ssp)
                return -EINVAL;
 
        *ssp -= SS_FRAME_SIZE;
-       if (put_shstk_data((void *__user)*ssp, target_ssp))
+       if (put_shstk_data((void __user *)*ssp, target_ssp))
                return -EFAULT;
 
        return 0;
This page took 0.057875 seconds and 4 git commands to generate.