Hi Dmitry, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on c34f157421f6905e6b4a79a312e9175dce2bc607] url: https://github.com/0day-ci/linux/commits/Dmitry-Safonov/Add-generic-user_landing-tracking/20201109-090354 base: c34f157421f6905e6b4a79a312e9175dce2bc607 config: mips-randconfig-p002-20201109 (attached as .config) compiler: mips-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # https://github.com/0day-ci/linux/commit/cf47146993b3d1866163ee1815829d9e76b48807 git remote add linux-review https://github.com/0day-ci/linux git fetch --no-tags linux-review Dmitry-Safonov/Add-generic-user_landing-tracking/20201109-090354 git checkout cf47146993b3d1866163ee1815829d9e76b48807 # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=mips If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <lkp@xxxxxxxxx> All warnings (new ones prefixed by >>): arch/mips/kernel/signal.c:439:5: warning: no previous prototype for 'setup_sigcontext' [-Wmissing-prototypes] 439 | int setup_sigcontext(struct pt_regs *regs, struct sigcontext __user *sc) | ^~~~~~~~~~~~~~~~ arch/mips/kernel/signal.c:516:5: warning: no previous prototype for 'restore_sigcontext' [-Wmissing-prototypes] 516 | int restore_sigcontext(struct pt_regs *regs, struct sigcontext __user *sc) | ^~~~~~~~~~~~~~~~~~ arch/mips/kernel/signal.c:630:17: warning: no previous prototype for 'sys_sigreturn' [-Wmissing-prototypes] 630 | asmlinkage void sys_sigreturn(void) | ^~~~~~~~~~~~~ arch/mips/kernel/signal.c:667:17: warning: no previous prototype for 'sys_rt_sigreturn' [-Wmissing-prototypes] 667 | asmlinkage void sys_rt_sigreturn(void) | ^~~~~~~~~~~~~~~~ In file included from include/linux/mmzone.h:21, from include/linux/gfp.h:6, from include/linux/mm.h:10, from arch/mips/kernel/signal.c:15: arch/mips/kernel/signal.c: In function 'handle_signal': include/linux/mm_types.h:500:31: error: 'TASK_SIZE_MAX' undeclared (first use in this function); did you mean 'TASK_SIZE_OF'? 500 | #define UNMAPPED_USER_LANDING TASK_SIZE_MAX | ^~~~~~~~~~~~~ arch/mips/kernel/signal.c:814:14: note: in expansion of macro 'UNMAPPED_USER_LANDING' 814 | if (land == UNMAPPED_USER_LANDING) | ^~~~~~~~~~~~~~~~~~~~~ include/linux/mm_types.h:500:31: note: each undeclared identifier is reported only once for each function it appears in 500 | #define UNMAPPED_USER_LANDING TASK_SIZE_MAX | ^~~~~~~~~~~~~ arch/mips/kernel/signal.c:814:14: note: in expansion of macro 'UNMAPPED_USER_LANDING' 814 | if (land == UNMAPPED_USER_LANDING) | ^~~~~~~~~~~~~~~~~~~~~ >> arch/mips/kernel/signal.c:848:34: warning: passing argument 1 of 'abi->setup_rt_frame' makes pointer from integer without a cast [-Wint-conversion] 848 | ret = abi->setup_rt_frame(land + abi->vdso->off_rt_sigreturn, | ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | | | long unsigned int arch/mips/kernel/signal.c:848:34: note: expected 'void *' but argument is of type 'long unsigned int' >> arch/mips/kernel/signal.c:851:31: warning: passing argument 1 of 'abi->setup_frame' makes pointer from integer without a cast [-Wint-conversion] 851 | ret = abi->setup_frame(land + abi->vdso->off_sigreturn, | ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~ | | | long unsigned int arch/mips/kernel/signal.c:851:31: note: expected 'void *' but argument is of type 'long unsigned int' arch/mips/kernel/signal.c: At top level: arch/mips/kernel/signal.c:898:17: warning: no previous prototype for 'do_notify_resume' [-Wmissing-prototypes] 898 | asmlinkage void do_notify_resume(struct pt_regs *regs, void *unused, | ^~~~~~~~~~~~~~~~ vim +848 arch/mips/kernel/signal.c 806 807 static void handle_signal(struct ksignal *ksig, struct pt_regs *regs) 808 { 809 unsigned long land = (unsigned long)current->mm->user_landing; 810 sigset_t *oldset = sigmask_to_save(); 811 int ret = 1; 812 struct mips_abi *abi = current->thread.abi; 813 814 if (land == UNMAPPED_USER_LANDING) 815 goto err; 816 /* 817 * If we were emulating a delay slot instruction, exit that frame such 818 * that addresses in the sigframe are as expected for userland and we 819 * don't have a problem if we reuse the thread's frame for an 820 * instruction within the signal handler. 821 */ 822 dsemul_thread_rollback(regs); 823 824 if (regs->regs[0]) { 825 switch(regs->regs[2]) { 826 case ERESTART_RESTARTBLOCK: 827 case ERESTARTNOHAND: 828 regs->regs[2] = EINTR; 829 break; 830 case ERESTARTSYS: 831 if (!(ksig->ka.sa.sa_flags & SA_RESTART)) { 832 regs->regs[2] = EINTR; 833 break; 834 } 835 fallthrough; 836 case ERESTARTNOINTR: 837 regs->regs[7] = regs->regs[26]; 838 regs->regs[2] = regs->regs[0]; 839 regs->cp0_epc -= 4; 840 } 841 842 regs->regs[0] = 0; /* Don't deal with this again. */ 843 } 844 845 rseq_signal_deliver(ksig, regs); 846 847 if (sig_uses_siginfo(&ksig->ka, abi)) > 848 ret = abi->setup_rt_frame(land + abi->vdso->off_rt_sigreturn, 849 ksig, regs, oldset); 850 else > 851 ret = abi->setup_frame(land + abi->vdso->off_sigreturn, 852 ksig, regs, oldset); 853 854 err: 855 signal_setup_done(ret, ksig, 0); 856 } 857 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx
Attachment:
.config.gz
Description: application/gzip