Hi Alexander, I love your patch! Perhaps something to improve: [auto build test WARNING on tip/x86/core] [also build test WARNING on tip/x86/mm linus/master v5.18-rc4 next-20220427] [cannot apply to hnaz-mm/master] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch] url: https://github.com/intel-lab-lkp/linux/commits/Alexander-Potapenko/Add-KernelMemorySanitizer-infrastructure/20220427-004851 base: https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git 203d8919a9eda5d1bc68ac3cd7637588334c9dc1 config: i386-randconfig-s002-20220425 (https://download.01.org/0day-ci/archive/20220427/202204272235.9uw8ns1T-lkp@xxxxxxxxx/config) compiler: gcc-11 (Debian 11.2.0-20) 11.2.0 reproduce: # apt-get install sparse # sparse version: v0.6.4-dirty # https://github.com/intel-lab-lkp/linux/commit/d216de19c8dd97fb6b0eac84fce4362489a61b2e git remote add linux-review https://github.com/intel-lab-lkp/linux git fetch --no-tags linux-review Alexander-Potapenko/Add-KernelMemorySanitizer-infrastructure/20220427-004851 git checkout d216de19c8dd97fb6b0eac84fce4362489a61b2e # save the config file mkdir build_dir && cp config build_dir/.config make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=i386 SHELL=/bin/bash arch/x86/kernel/ kernel/ mm/ If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <lkp@xxxxxxxxx> sparse warnings: (new ones prefixed by >>) arch/x86/kernel/signal.c:360:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:360:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:360:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:360:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __user *ptr @@ got unsigned long long [usertype] * @@ arch/x86/kernel/signal.c:360:9: sparse: expected void const volatile [noderef] __user *ptr arch/x86/kernel/signal.c:360:9: sparse: got unsigned long long [usertype] * arch/x86/kernel/signal.c:360:9: sparse: sparse: cast removes address space '__user' of expression >> arch/x86/kernel/signal.c:360:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void [noderef] __user *to @@ got unsigned long long [usertype] * @@ arch/x86/kernel/signal.c:360:9: sparse: expected void [noderef] __user *to arch/x86/kernel/signal.c:360:9: sparse: got unsigned long long [usertype] * arch/x86/kernel/signal.c:360:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:360:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:360:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:360:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:360:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:360:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:360:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:360:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:360:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:360:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:420:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:420:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:420:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:420:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __user *ptr @@ got unsigned long long [usertype] * @@ arch/x86/kernel/signal.c:420:9: sparse: expected void const volatile [noderef] __user *ptr arch/x86/kernel/signal.c:420:9: sparse: got unsigned long long [usertype] * arch/x86/kernel/signal.c:420:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:420:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void [noderef] __user *to @@ got unsigned long long [usertype] * @@ arch/x86/kernel/signal.c:420:9: sparse: expected void [noderef] __user *to arch/x86/kernel/signal.c:420:9: sparse: got unsigned long long [usertype] * arch/x86/kernel/signal.c:420:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:420:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:420:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:420:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:420:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:420:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:420:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:420:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:420:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:420:9: sparse: sparse: cast removes address space '__user' of expression arch/x86/kernel/signal.c:953:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct lockdep_map const *lock @@ got struct lockdep_map [noderef] __rcu * @@ arch/x86/kernel/signal.c:953:9: sparse: expected struct lockdep_map const *lock arch/x86/kernel/signal.c:953:9: sparse: got struct lockdep_map [noderef] __rcu * -- kernel/signal.c: note: in included file (through arch/x86/include/uapi/asm/signal.h, arch/x86/include/asm/signal.h, include/uapi/linux/signal.h, ...): include/uapi/asm-generic/signal-defs.h:83:29: sparse: sparse: multiple address spaces given kernel/signal.c:195:31: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:195:31: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:195:31: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:198:33: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:198:33: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:198:33: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:480:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:480:9: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:480:9: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:484:34: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:484:34: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:484:34: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:517:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:517:9: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:517:9: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:520:36: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:520:36: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:520:36: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:542:53: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected struct k_sigaction *ka @@ got struct k_sigaction [noderef] __rcu * @@ kernel/signal.c:542:53: sparse: expected struct k_sigaction *ka kernel/signal.c:542:53: sparse: got struct k_sigaction [noderef] __rcu * include/uapi/asm-generic/signal-defs.h:83:29: sparse: sparse: multiple address spaces given kernel/signal.c:698:33: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:698:33: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:698:33: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:700:31: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:700:31: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:700:31: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:1263:29: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __user *ptr @@ got unsigned char * @@ kernel/signal.c:1263:29: sparse: expected void const volatile [noderef] __user *ptr kernel/signal.c:1263:29: sparse: got unsigned char * >> kernel/signal.c:1263:29: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void const [noderef] __user *from @@ got unsigned char * @@ kernel/signal.c:1263:29: sparse: expected void const [noderef] __user *from kernel/signal.c:1263:29: sparse: got unsigned char * >> kernel/signal.c:1263:29: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void const [noderef] __user *from @@ got unsigned char * @@ kernel/signal.c:1263:29: sparse: expected void const [noderef] __user *from kernel/signal.c:1263:29: sparse: got unsigned char * kernel/signal.c:1330:9: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:1330:9: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:1330:9: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:1331:16: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct k_sigaction *action @@ got struct k_sigaction [noderef] __rcu * @@ kernel/signal.c:1331:16: sparse: expected struct k_sigaction *action kernel/signal.c:1331:16: sparse: got struct k_sigaction [noderef] __rcu * kernel/signal.c:1351:34: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:1351:34: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:1351:34: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:1929:36: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:1929:36: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:1929:36: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:2039:44: sparse: sparse: cast removes address space '__rcu' of expression kernel/signal.c:2058:65: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct task_struct *tsk @@ got struct task_struct [noderef] __rcu *parent @@ kernel/signal.c:2058:65: sparse: expected struct task_struct *tsk kernel/signal.c:2058:65: sparse: got struct task_struct [noderef] __rcu *parent kernel/signal.c:2059:40: sparse: sparse: cast removes address space '__rcu' of expression kernel/signal.c:2077:14: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct sighand_struct *psig @@ got struct sighand_struct [noderef] __rcu *[noderef] __rcu sighand @@ kernel/signal.c:2077:14: sparse: expected struct sighand_struct *psig kernel/signal.c:2077:14: sparse: got struct sighand_struct [noderef] __rcu *[noderef] __rcu sighand kernel/signal.c:2106:46: sparse: sparse: incorrect type in argument 3 (different address spaces) @@ expected struct task_struct *t @@ got struct task_struct [noderef] __rcu *parent @@ kernel/signal.c:2106:46: sparse: expected struct task_struct *t kernel/signal.c:2106:46: sparse: got struct task_struct [noderef] __rcu *parent kernel/signal.c:2107:34: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected struct task_struct *parent @@ got struct task_struct [noderef] __rcu *parent @@ kernel/signal.c:2107:34: sparse: expected struct task_struct *parent kernel/signal.c:2107:34: sparse: got struct task_struct [noderef] __rcu *parent kernel/signal.c:2136:24: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct task_struct *parent @@ got struct task_struct [noderef] __rcu *parent @@ kernel/signal.c:2136:24: sparse: expected struct task_struct *parent kernel/signal.c:2136:24: sparse: got struct task_struct [noderef] __rcu *parent kernel/signal.c:2139:24: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct task_struct *parent @@ got struct task_struct [noderef] __rcu *real_parent @@ kernel/signal.c:2139:24: sparse: expected struct task_struct *parent kernel/signal.c:2139:24: sparse: got struct task_struct [noderef] __rcu *real_parent kernel/signal.c:2172:17: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct sighand_struct *sighand @@ got struct sighand_struct [noderef] __rcu *sighand @@ kernel/signal.c:2172:17: sparse: expected struct sighand_struct *sighand kernel/signal.c:2172:17: sparse: got struct sighand_struct [noderef] __rcu *sighand kernel/signal.c:2213:41: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:2213:41: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:2213:41: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:2215:39: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:2215:39: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:2215:39: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:2266:33: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:2266:33: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:2266:33: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:2322:31: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:2322:31: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:2322:31: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:2363:31: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:2363:31: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:2363:31: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:2365:33: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:2365:33: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:2365:33: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:2464:41: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:2464:41: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:2464:41: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:2548:41: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:2548:41: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:2548:41: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:2560:33: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:2560:33: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:2560:33: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:2595:52: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct task_struct *tsk @@ got struct task_struct [noderef] __rcu *parent @@ kernel/signal.c:2595:52: sparse: expected struct task_struct *tsk kernel/signal.c:2595:52: sparse: got struct task_struct [noderef] __rcu *parent kernel/signal.c:2597:49: sparse: sparse: cast removes address space '__rcu' of expression kernel/signal.c:2635:49: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected struct sighand_struct *sighand @@ got struct sighand_struct [noderef] __rcu *sighand @@ kernel/signal.c:2635:49: sparse: expected struct sighand_struct *sighand kernel/signal.c:2635:49: sparse: got struct sighand_struct [noderef] __rcu *sighand kernel/signal.c:2964:27: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:2964:27: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:2964:27: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:2984:29: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:2984:29: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:2984:29: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:3051:27: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:3051:27: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:3051:27: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:3053:29: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:3053:29: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:3053:29: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:3204:31: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:3204:31: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:3204:31: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:3207:33: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:3207:33: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:3207:33: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:3594:27: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:3594:27: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:3594:27: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:3606:37: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:3606:37: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:3606:37: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:3611:35: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:3611:35: sparse: expected struct spinlock [usertype] *lock kernel/signal.c:3611:35: sparse: got struct spinlock [noderef] __rcu * kernel/signal.c:3616:29: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct spinlock [usertype] *lock @@ got struct spinlock [noderef] __rcu * @@ kernel/signal.c:3616:29: sparse: expected struct spinlock [usertype] *lock vim +360 arch/x86/kernel/signal.c 75779f05264b996 arch/x86/kernel/signal.c Hiroshi Shimamoto 2009-02-27 325 7e907f48980d666 arch/x86/kernel/signal_32.c Ingo Molnar 2008-03-06 326 static int 235b80226b986da arch/x86/kernel/signal.c Al Viro 2012-11-09 327 __setup_frame(int sig, struct ksignal *ksig, sigset_t *set, 7e907f48980d666 arch/x86/kernel/signal_32.c Ingo Molnar 2008-03-06 328 struct pt_regs *regs) ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 329 { ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 330 struct sigframe __user *frame; 7e907f48980d666 arch/x86/kernel/signal_32.c Ingo Molnar 2008-03-06 331 void __user *restorer; b00d8f8f0b2b392 arch/x86/kernel/signal.c Al Viro 2020-02-15 332 void __user *fp = NULL; ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 333 b00d8f8f0b2b392 arch/x86/kernel/signal.c Al Viro 2020-02-15 334 frame = get_sigframe(&ksig->ka, regs, sizeof(*frame), &fp); ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 335 5c1f178094631e8 arch/x86/kernel/signal.c Al Viro 2020-02-15 336 if (!user_access_begin(frame, sizeof(*frame))) 3d0aedd9538e6be arch/x86/kernel/signal_32.c Hiroshi Shimamoto 2008-09-12 337 return -EFAULT; ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 338 5c1f178094631e8 arch/x86/kernel/signal.c Al Viro 2020-02-15 339 unsafe_put_user(sig, &frame->sig, Efault); b00d8f8f0b2b392 arch/x86/kernel/signal.c Al Viro 2020-02-15 340 unsafe_put_sigcontext(&frame->sc, fp, regs, set, Efault); 5c1f178094631e8 arch/x86/kernel/signal.c Al Viro 2020-02-15 341 unsafe_put_user(set->sig[1], &frame->extramask[0], Efault); 1a3e4ca41c5a389 arch/x86/kernel/signal_32.c Roland McGrath 2008-04-09 342 if (current->mm->context.vdso) 6f121e548f83674 arch/x86/kernel/signal.c Andy Lutomirski 2014-05-05 343 restorer = current->mm->context.vdso + 0a6d1fa0d2b48fb arch/x86/kernel/signal.c Andy Lutomirski 2015-10-05 344 vdso_image_32.sym___kernel_sigreturn; 9fbbd4dd17d0712 arch/i386/kernel/signal.c Andi Kleen 2007-02-13 345 else ade1af77129dea6 arch/x86/kernel/signal_32.c Jan Engelhardt 2008-01-30 346 restorer = &frame->retcode; 235b80226b986da arch/x86/kernel/signal.c Al Viro 2012-11-09 347 if (ksig->ka.sa.sa_flags & SA_RESTORER) 235b80226b986da arch/x86/kernel/signal.c Al Viro 2012-11-09 348 restorer = ksig->ka.sa.sa_restorer; ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 349 ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 350 /* Set up to return from userspace. */ 5c1f178094631e8 arch/x86/kernel/signal.c Al Viro 2020-02-15 351 unsafe_put_user(restorer, &frame->pretcode, Efault); ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 352 ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 353 /* 7e907f48980d666 arch/x86/kernel/signal_32.c Ingo Molnar 2008-03-06 354 * This is popl %eax ; movl $__NR_sigreturn, %eax ; int $0x80 ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 355 * ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 356 * WE DO NOT USE IT ANY MORE! It's only left here for historical ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 357 * reasons and because gdb uses it as a signature to notice ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 358 * signal handler stack frames. ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 359 */ 5c1f178094631e8 arch/x86/kernel/signal.c Al Viro 2020-02-15 @360 unsafe_put_user(*((u64 *)&retcode), (u64 *)frame->retcode, Efault); 5c1f178094631e8 arch/x86/kernel/signal.c Al Viro 2020-02-15 361 user_access_end(); ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 362 ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 363 /* Set up registers for signal handler */ 65ea5b034990358 arch/x86/kernel/signal_32.c H. Peter Anvin 2008-01-30 364 regs->sp = (unsigned long)frame; 235b80226b986da arch/x86/kernel/signal.c Al Viro 2012-11-09 365 regs->ip = (unsigned long)ksig->ka.sa.sa_handler; 65ea5b034990358 arch/x86/kernel/signal_32.c H. Peter Anvin 2008-01-30 366 regs->ax = (unsigned long)sig; 92bc2056855b325 arch/x86/kernel/signal_32.c Harvey Harrison 2008-02-08 367 regs->dx = 0; 92bc2056855b325 arch/x86/kernel/signal_32.c Harvey Harrison 2008-02-08 368 regs->cx = 0; ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 369 65ea5b034990358 arch/x86/kernel/signal_32.c H. Peter Anvin 2008-01-30 370 regs->ds = __USER_DS; 65ea5b034990358 arch/x86/kernel/signal_32.c H. Peter Anvin 2008-01-30 371 regs->es = __USER_DS; 65ea5b034990358 arch/x86/kernel/signal_32.c H. Peter Anvin 2008-01-30 372 regs->ss = __USER_DS; 65ea5b034990358 arch/x86/kernel/signal_32.c H. Peter Anvin 2008-01-30 373 regs->cs = __USER_CS; ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 374 283828f3c19ceb3 arch/i386/kernel/signal.c David Howells 2006-01-18 375 return 0; b00d8f8f0b2b392 arch/x86/kernel/signal.c Al Viro 2020-02-15 376 b00d8f8f0b2b392 arch/x86/kernel/signal.c Al Viro 2020-02-15 377 Efault: b00d8f8f0b2b392 arch/x86/kernel/signal.c Al Viro 2020-02-15 378 user_access_end(); b00d8f8f0b2b392 arch/x86/kernel/signal.c Al Viro 2020-02-15 379 return -EFAULT; ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 380 } ^1da177e4c3f415 arch/i386/kernel/signal.c Linus Torvalds 2005-04-16 381 -- 0-DAY CI Kernel Test Service https://01.org/lkp