[lkml]   [2019]   [Jun]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH -mm 1/1] signal: simplify set_user_sigmask/restore_user_sigmask
Hi Oleg,

I love your patch! Perhaps something to improve:

[auto build test WARNING on mmotm/master]

base: git:// master
config: sparc64-allyesconfig (attached as .config)
compiler: sparc64-linux-gcc (GCC) 7.4.0
wget -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
GCC_VERSION=7.4.0 make.cross ARCH=sparc64

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <>

Note: it may well be a FALSE warning. FWIW you are at least aware of it now.

All warnings (new ones prefixed by >>):

In file included from include/linux/poll.h:12:0,
from include/linux/ring_buffer.h:7,
from include/linux/trace_events.h:6,
from include/trace/syscall.h:7,
from include/linux/syscalls.h:86,
from kernel/signal.c:30:
kernel/signal.c: In function 'set_user_sigmask':
include/linux/uaccess.h:113:7: warning: 'kmask' may be used uninitialized in this function [-Wmaybe-uninitialized]
res = raw_copy_from_user(to, from, n);
kernel/signal.c:2960:12: note: 'kmask' was declared here
sigset_t *kmask;
kernel/signal.c: In function 'set_compat_user_sigmask':
>> kernel/signal.c:2986:6: warning: 'kmask' may be used uninitialized in this function [-Wmaybe-uninitialized]
if (get_compat_sigset(kmask, umask))

vim +/kmask +2986 kernel/signal.c

2976 #ifdef CONFIG_COMPAT
2977 int set_compat_user_sigmask(const compat_sigset_t __user *umask,
2978 size_t sigsetsize)
2979 {
2980 sigset_t *kmask;
2982 if (!umask)
2983 return 0;
2984 if (sigsetsize != sizeof(compat_sigset_t))
2985 return -EINVAL;
> 2986 if (get_compat_sigset(kmask, umask))
2987 return -EFAULT;
2989 set_restore_sigmask();
2990 current->saved_sigmask = current->blocked;
2991 set_current_blocked(kmask);
2993 return 0;
2994 }
2995 #endif

0-DAY kernel test infrastructure Open Source Technology Center Intel Corporation
[unhandled content-type:application/gzip]
 \ /
  Last update: 2019-06-06 03:06    [W:0.216 / U:5.860 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site