tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master head: 9f9b9a2972eb8dcaad09d826c5c6d7488eaca3e6 commit: a1f4ccd25cc256255813f584f10e5527369d4a02 [5092/8035] arm64/sme: Provide Kconfig for SME config: arm64-allyesconfig (https://download.01.org/0day-ci/archive/20220502/202205022210.v0Ir7omB-lkp@xxxxxxxxx/config) compiler: aarch64-linux-gcc (GCC) 11.3.0 reproduce: wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # apt-get install sparse # sparse version: v0.6.4-dirty # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=a1f4ccd25cc256255813f584f10e5527369d4a02 git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git git fetch --no-tags linux-next master git checkout a1f4ccd25cc256255813f584f10e5527369d4a02 # save the config file mkdir build_dir && cp config build_dir/.config COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=arm64 SHELL=/bin/bash arch/arm64/kernel/ 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/arm64/kernel/signal.c:663:43: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected struct user_ctxs [noderef] __user *user @@ got struct user_ctxs * @@ arch/arm64/kernel/signal.c:663:43: sparse: expected struct user_ctxs [noderef] __user *user arch/arm64/kernel/signal.c:663:43: sparse: got struct user_ctxs * arch/arm64/kernel/signal.c:933:26: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected void ( [noderef] [usertype] __user *[assigned] [usertype] sigtramp )( ... ) @@ got void * @@ arch/arm64/kernel/signal.c:933:26: sparse: expected void ( [noderef] [usertype] __user *[assigned] [usertype] sigtramp )( ... ) arch/arm64/kernel/signal.c:933:26: sparse: got void * >> arch/arm64/kernel/signal.c:394:35: sparse: sparse: dereference of noderef expression >> arch/arm64/kernel/signal.c:394:35: sparse: sparse: dereference of noderef expression arch/arm64/kernel/signal.c:428:53: sparse: sparse: dereference of noderef expression arch/arm64/kernel/signal.c:428:53: sparse: sparse: dereference of noderef expression vim +663 arch/arm64/kernel/signal.c 47ccb02868cead3 Dave Martin 2017-06-15 620 2c020ed8d148f75 Catalin Marinas 2012-03-05 621 static int restore_sigframe(struct pt_regs *regs, 2c020ed8d148f75 Catalin Marinas 2012-03-05 622 struct rt_sigframe __user *sf) 2c020ed8d148f75 Catalin Marinas 2012-03-05 623 { 2c020ed8d148f75 Catalin Marinas 2012-03-05 624 sigset_t set; 2c020ed8d148f75 Catalin Marinas 2012-03-05 625 int i, err; 47ccb02868cead3 Dave Martin 2017-06-15 626 struct user_ctxs user; 2c020ed8d148f75 Catalin Marinas 2012-03-05 627 2c020ed8d148f75 Catalin Marinas 2012-03-05 628 err = __copy_from_user(&set, &sf->uc.uc_sigmask, sizeof(set)); 2c020ed8d148f75 Catalin Marinas 2012-03-05 629 if (err == 0) 2c020ed8d148f75 Catalin Marinas 2012-03-05 630 set_current_blocked(&set); 2c020ed8d148f75 Catalin Marinas 2012-03-05 631 2c020ed8d148f75 Catalin Marinas 2012-03-05 632 for (i = 0; i < 31; i++) 2c020ed8d148f75 Catalin Marinas 2012-03-05 633 __get_user_error(regs->regs[i], &sf->uc.uc_mcontext.regs[i], 2c020ed8d148f75 Catalin Marinas 2012-03-05 634 err); 2c020ed8d148f75 Catalin Marinas 2012-03-05 635 __get_user_error(regs->sp, &sf->uc.uc_mcontext.sp, err); 2c020ed8d148f75 Catalin Marinas 2012-03-05 636 __get_user_error(regs->pc, &sf->uc.uc_mcontext.pc, err); 2c020ed8d148f75 Catalin Marinas 2012-03-05 637 __get_user_error(regs->pstate, &sf->uc.uc_mcontext.pstate, err); 2c020ed8d148f75 Catalin Marinas 2012-03-05 638 2c020ed8d148f75 Catalin Marinas 2012-03-05 639 /* 2c020ed8d148f75 Catalin Marinas 2012-03-05 640 * Avoid sys_rt_sigreturn() restarting. 2c020ed8d148f75 Catalin Marinas 2012-03-05 641 */ 17c289586009281 Dave Martin 2017-08-01 642 forget_syscall(regs); 2c020ed8d148f75 Catalin Marinas 2012-03-05 643 dbd4d7ca563fd0a Mark Rutland 2016-03-01 644 err |= !valid_user_regs(®s->user_regs, current); 47ccb02868cead3 Dave Martin 2017-06-15 645 if (err == 0) 47ccb02868cead3 Dave Martin 2017-06-15 646 err = parse_user_sigframe(&user, sf); 2c020ed8d148f75 Catalin Marinas 2012-03-05 647 6d502b6ba1b267b Suzuki K Poulose 2020-01-13 648 if (err == 0 && system_supports_fpsimd()) { 8cd969d28fd2848 Dave Martin 2017-10-31 649 if (!user.fpsimd) 8cd969d28fd2848 Dave Martin 2017-10-31 650 return -EINVAL; 8cd969d28fd2848 Dave Martin 2017-10-31 651 8cd969d28fd2848 Dave Martin 2017-10-31 652 if (user.sve) { 8cd969d28fd2848 Dave Martin 2017-10-31 653 if (!system_supports_sve()) 8cd969d28fd2848 Dave Martin 2017-10-31 654 return -EINVAL; 8cd969d28fd2848 Dave Martin 2017-10-31 655 8cd969d28fd2848 Dave Martin 2017-10-31 656 err = restore_sve_fpsimd_context(&user); 8cd969d28fd2848 Dave Martin 2017-10-31 657 } else { 47ccb02868cead3 Dave Martin 2017-06-15 658 err = restore_fpsimd_context(user.fpsimd); 8cd969d28fd2848 Dave Martin 2017-10-31 659 } 8cd969d28fd2848 Dave Martin 2017-10-31 660 } 2c020ed8d148f75 Catalin Marinas 2012-03-05 661 39782210eb7e876 Mark Brown 2022-04-19 662 if (err == 0 && system_supports_sme() && user.za) 39782210eb7e876 Mark Brown 2022-04-19 @663 err = restore_za_context(&user); 39782210eb7e876 Mark Brown 2022-04-19 664 2c020ed8d148f75 Catalin Marinas 2012-03-05 665 return err; 2c020ed8d148f75 Catalin Marinas 2012-03-05 666 } 2c020ed8d148f75 Catalin Marinas 2012-03-05 667 :::::: The code at line 663 was first introduced by commit :::::: 39782210eb7e87634d96cacb6ece370bc59d74ba arm64/sme: Implement ZA signal handling :::::: TO: Mark Brown <broonie@xxxxxxxxxx> :::::: CC: Catalin Marinas <catalin.marinas@xxxxxxx> -- 0-DAY CI Kernel Test Service https://01.org/lkp