lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:   Wed, 22 Dec 2021 15:54:25 +0800
From:   kernel test robot <lkp@...el.com>
To:     Guo Ren <guoren@...ux.alibaba.com>
Cc:     kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org
Subject: [csky-linux:riscv_compat_v1 12/13]
 arch/riscv/kernel/compat_signal.c:199:5: warning: no previous prototype for
 'compat_setup_rt_frame'

tree:   https://github.com/c-sky/csky-linux riscv_compat_v1
head:   60f122c486d0c1c8b30e0b264c215db4a5a0124d
commit: 341104ec427222e0500c50837a7661fb57e42c0f [12/13] riscv: compat: signal: Add rt_frame implementation
config: riscv-allyesconfig (https://download.01.org/0day-ci/archive/20211222/202112221514.cPqrnZR0-lkp@intel.com/config)
compiler: riscv64-linux-gcc (GCC) 11.2.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/c-sky/csky-linux/commit/341104ec427222e0500c50837a7661fb57e42c0f
        git remote add csky-linux https://github.com/c-sky/csky-linux
        git fetch --no-tags csky-linux riscv_compat_v1
        git checkout 341104ec427222e0500c50837a7661fb57e42c0f
        # save the config file to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=riscv SHELL=/bin/bash arch/riscv/kernel/ arch/riscv/mm/

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>

All warnings (new ones prefixed by >>):

>> arch/riscv/kernel/compat_signal.c:199:5: warning: no previous prototype for 'compat_setup_rt_frame' [-Wmissing-prototypes]
     199 | int compat_setup_rt_frame(struct ksignal *ksig, sigset_t *set,
         |     ^~~~~~~~~~~~~~~~~~~~~


vim +/compat_setup_rt_frame +199 arch/riscv/kernel/compat_signal.c

   198	
 > 199	int compat_setup_rt_frame(struct ksignal *ksig, sigset_t *set,
   200		struct pt_regs *regs)
   201	{
   202		struct compat_rt_sigframe __user *frame;
   203		long err = 0;
   204	
   205		frame = compat_get_sigframe(ksig, regs, sizeof(*frame));
   206		if (!access_ok(frame, sizeof(*frame)))
   207			return -EFAULT;
   208	
   209		err |= copy_siginfo_to_user32(&frame->info, &ksig->info);
   210	
   211		/* Create the ucontext. */
   212		err |= __put_user(0, &frame->uc.uc_flags);
   213		err |= __put_user(NULL, &frame->uc.uc_link);
   214		err |= __compat_save_altstack(&frame->uc.uc_stack, regs->sp);
   215		err |= compat_setup_sigcontext(frame, regs);
   216		err |= __copy_to_user(&frame->uc.uc_sigmask, set, sizeof(*set));
   217		if (err)
   218			return -EFAULT;
   219	
   220		regs->ra = (unsigned long)COMPAT_VDSO_SYMBOL(
   221				current->mm->context.vdso, rt_sigreturn);
   222	
   223		/*
   224		 * Set up registers for signal handler.
   225		 * Registers that we don't modify keep the value they had from
   226		 * user-space at the time we took the signal.
   227		 * We always pass siginfo and mcontext, regardless of SA_SIGINFO,
   228		 * since some things rely on this (e.g. glibc's debug/segfault.c).
   229		 */
   230		regs->epc = (unsigned long)ksig->ka.sa.sa_handler;
   231		regs->sp = (unsigned long)frame;
   232		regs->a0 = ksig->sig;                     /* a0: signal number */
   233		regs->a1 = (unsigned long)(&frame->info); /* a1: siginfo pointer */
   234		regs->a2 = (unsigned long)(&frame->uc);   /* a2: ucontext pointer */
   235	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ