arch/parisc/kernel/sys_parisc.c:415:17: warning: no previous prototype for 'parisc_compat_signalfd4'

From: kernel test robot
Date: Wed May 19 2021 - 06:54:28 EST


tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 8ac91e6c6033ebc12c5c1e4aa171b81a662bd70f
commit: 44a4c9e443674e6cd3368d3e642dfe9c429d5525 parisc: Add wrapper syscalls to fix O_NONBLOCK flag usage
date: 7 months ago
config: parisc-randconfig-r001-20210519 (attached as .config)
compiler: hppa64-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://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=44a4c9e443674e6cd3368d3e642dfe9c429d5525
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 44a4c9e443674e6cd3368d3e642dfe9c429d5525
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=parisc

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/parisc/kernel/sys_parisc.c:228:15: warning: no previous prototype for 'arch_mmap_rnd' [-Wmissing-prototypes]
228 | unsigned long arch_mmap_rnd(void)
| ^~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:256:26: warning: no previous prototype for 'sys_mmap2' [-Wmissing-prototypes]
256 | asmlinkage unsigned long sys_mmap2(unsigned long addr, unsigned long len,
| ^~~~~~~~~
arch/parisc/kernel/sys_parisc.c:266:26: warning: no previous prototype for 'sys_mmap' [-Wmissing-prototypes]
266 | asmlinkage unsigned long sys_mmap(unsigned long addr, unsigned long len,
| ^~~~~~~~
arch/parisc/kernel/sys_parisc.c:281:17: warning: no previous prototype for 'parisc_truncate64' [-Wmissing-prototypes]
281 | asmlinkage long parisc_truncate64(const char __user * path,
| ^~~~~~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:287:17: warning: no previous prototype for 'parisc_ftruncate64' [-Wmissing-prototypes]
287 | asmlinkage long parisc_ftruncate64(unsigned int fd,
| ^~~~~~~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:295:17: warning: no previous prototype for 'sys_truncate64' [-Wmissing-prototypes]
295 | asmlinkage long sys_truncate64(const char __user * path, unsigned long length)
| ^~~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:299:17: warning: no previous prototype for 'sys_ftruncate64' [-Wmissing-prototypes]
299 | asmlinkage long sys_ftruncate64(unsigned int fd, unsigned long length)
| ^~~~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:303:17: warning: no previous prototype for 'sys_fcntl64' [-Wmissing-prototypes]
303 | asmlinkage long sys_fcntl64(unsigned int fd, unsigned int cmd, unsigned long arg)
| ^~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:322:20: warning: no previous prototype for 'parisc_pread64' [-Wmissing-prototypes]
322 | asmlinkage ssize_t parisc_pread64(unsigned int fd, char __user *buf, size_t count,
| ^~~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:328:20: warning: no previous prototype for 'parisc_pwrite64' [-Wmissing-prototypes]
328 | asmlinkage ssize_t parisc_pwrite64(unsigned int fd, const char __user *buf,
| ^~~~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:334:20: warning: no previous prototype for 'parisc_readahead' [-Wmissing-prototypes]
334 | asmlinkage ssize_t parisc_readahead(int fd, unsigned int high, unsigned int low,
| ^~~~~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:340:17: warning: no previous prototype for 'parisc_fadvise64_64' [-Wmissing-prototypes]
340 | asmlinkage long parisc_fadvise64_64(int fd,
| ^~~~~~~~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:348:17: warning: no previous prototype for 'parisc_sync_file_range' [-Wmissing-prototypes]
348 | asmlinkage long parisc_sync_file_range(int fd,
| ^~~~~~~~~~~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:356:17: warning: no previous prototype for 'parisc_fallocate' [-Wmissing-prototypes]
356 | asmlinkage long parisc_fallocate(int fd, int mode, u32 offhi, u32 offlo,
| ^~~~~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:363:6: warning: no previous prototype for 'parisc_personality' [-Wmissing-prototypes]
363 | long parisc_personality(unsigned long personality)
| ^~~~~~~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:401:17: warning: no previous prototype for 'parisc_timerfd_create' [-Wmissing-prototypes]
401 | asmlinkage long parisc_timerfd_create(int clockid, int flags)
| ^~~~~~~~~~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:407:17: warning: no previous prototype for 'parisc_signalfd4' [-Wmissing-prototypes]
407 | asmlinkage long parisc_signalfd4(int ufd, sigset_t __user *user_mask,
| ^~~~~~~~~~~~~~~~
>> arch/parisc/kernel/sys_parisc.c:415:17: warning: no previous prototype for 'parisc_compat_signalfd4' [-Wmissing-prototypes]
415 | asmlinkage long parisc_compat_signalfd4(int ufd,
| ^~~~~~~~~~~~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:424:17: warning: no previous prototype for 'parisc_eventfd2' [-Wmissing-prototypes]
424 | asmlinkage long parisc_eventfd2(unsigned int count, int flags)
| ^~~~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:430:17: warning: no previous prototype for 'parisc_userfaultfd' [-Wmissing-prototypes]
430 | asmlinkage long parisc_userfaultfd(int flags)
| ^~~~~~~~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:436:17: warning: no previous prototype for 'parisc_pipe2' [-Wmissing-prototypes]
436 | asmlinkage long parisc_pipe2(int __user *fildes, int flags)
| ^~~~~~~~~~~~
arch/parisc/kernel/sys_parisc.c:442:17: warning: no previous prototype for 'parisc_inotify_init1' [-Wmissing-prototypes]
442 | asmlinkage long parisc_inotify_init1(int flags)
| ^~~~~~~~~~~~~~~~~~~~


vim +/parisc_compat_signalfd4 +415 arch/parisc/kernel/sys_parisc.c

362
> 363 long parisc_personality(unsigned long personality)
364 {
365 long err;
366
367 if (personality(current->personality) == PER_LINUX32
368 && personality(personality) == PER_LINUX)
369 personality = (personality & ~PER_MASK) | PER_LINUX32;
370
371 err = sys_personality(personality);
372 if (personality(err) == PER_LINUX32)
373 err = (err & ~PER_MASK) | PER_LINUX;
374
375 return err;
376 }
377
378 /*
379 * Up to kernel v5.9 we defined O_NONBLOCK as 000200004,
380 * since then O_NONBLOCK is defined as 000200000.
381 *
382 * The following wrapper functions mask out the old
383 * O_NDELAY bit from calls which use O_NONBLOCK.
384 *
385 * XXX: Remove those in year 2022 (or later)?
386 */
387
388 #define O_NONBLOCK_OLD 000200004
389 #define O_NONBLOCK_MASK_OUT (O_NONBLOCK_OLD & ~O_NONBLOCK)
390
391 static int FIX_O_NONBLOCK(int flags)
392 {
393 if (flags & O_NONBLOCK_MASK_OUT) {
394 struct task_struct *tsk = current;
395 pr_warn_once("%s(%d) uses a deprecated O_NONBLOCK value.\n",
396 tsk->comm, tsk->pid);
397 }
398 return flags & ~O_NONBLOCK_MASK_OUT;
399 }
400
401 asmlinkage long parisc_timerfd_create(int clockid, int flags)
402 {
403 flags = FIX_O_NONBLOCK(flags);
404 return sys_timerfd_create(clockid, flags);
405 }
406
407 asmlinkage long parisc_signalfd4(int ufd, sigset_t __user *user_mask,
408 size_t sizemask, int flags)
409 {
410 flags = FIX_O_NONBLOCK(flags);
411 return sys_signalfd4(ufd, user_mask, sizemask, flags);
412 }
413
414 #ifdef CONFIG_COMPAT
> 415 asmlinkage long parisc_compat_signalfd4(int ufd,
416 compat_sigset_t __user *user_mask,
417 compat_size_t sizemask, int flags)
418 {
419 flags = FIX_O_NONBLOCK(flags);
420 return compat_sys_signalfd4(ufd, user_mask, sizemask, flags);
421 }
422 #endif
423

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

Attachment: .config.gz
Description: application/gzip