All of lore.kernel.org
 help / color / mirror / Atom feed
* [jlayton:kdevops 18/18] fs/fcntl.c:557:3: error: too many arguments to function 'fcntl_getdeleg'
@ 2025-11-02  2:38 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2025-11-02  2:38 UTC (permalink / raw)
  To: Jeff Layton; +Cc: oe-kbuild-all

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/jlayton/linux.git kdevops
head:   9e5f70681a5f212d01e4e4177a1271b28fcdaf60
commit: 9e5f70681a5f212d01e4e4177a1271b28fcdaf60 [18/18] vfs: expose delegation support to userland
config: nios2-randconfig-r072-20251102 (https://download.01.org/0day-ci/archive/20251102/202511021005.JtkVfCS5-lkp@intel.com/config)
compiler: nios2-linux-gcc (GCC) 9.5.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20251102/202511021005.JtkVfCS5-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202511021005.JtkVfCS5-lkp@intel.com/

All errors (new ones prefixed by >>):

   fs/fcntl.c: In function 'do_fcntl':
>> fs/fcntl.c:557:3: error: too many arguments to function 'fcntl_getdeleg'
     557 |   fcntl_getdeleg(filp, &deleg);
         |   ^~~~~~~~~~~~~~
   In file included from fs/fcntl.c:13:
   include/linux/filelock.h:288:19: note: declared here
     288 | static inline int fcntl_getdeleg(struct file *filp)
         |                   ^~~~~~~~~~~~~~


vim +/fcntl_getdeleg +557 fs/fcntl.c

   443	
   444	static long do_fcntl(int fd, unsigned int cmd, unsigned long arg,
   445			struct file *filp)
   446	{
   447		void __user *argp = (void __user *)arg;
   448		struct delegation deleg;
   449		int argi = (int)arg;
   450		struct flock flock;
   451		long err = -EINVAL;
   452	
   453		switch (cmd) {
   454		case F_CREATED_QUERY:
   455			err = f_created_query(filp);
   456			break;
   457		case F_DUPFD:
   458			err = f_dupfd(argi, filp, 0);
   459			break;
   460		case F_DUPFD_CLOEXEC:
   461			err = f_dupfd(argi, filp, O_CLOEXEC);
   462			break;
   463		case F_DUPFD_QUERY:
   464			err = f_dupfd_query(argi, filp);
   465			break;
   466		case F_GETFD:
   467			err = get_close_on_exec(fd) ? FD_CLOEXEC : 0;
   468			break;
   469		case F_SETFD:
   470			err = 0;
   471			set_close_on_exec(fd, argi & FD_CLOEXEC);
   472			break;
   473		case F_GETFL:
   474			err = filp->f_flags;
   475			break;
   476		case F_SETFL:
   477			err = setfl(fd, filp, argi);
   478			break;
   479	#if BITS_PER_LONG != 32
   480		/* 32-bit arches must use fcntl64() */
   481		case F_OFD_GETLK:
   482	#endif
   483		case F_GETLK:
   484			if (copy_from_user(&flock, argp, sizeof(flock)))
   485				return -EFAULT;
   486			err = fcntl_getlk(filp, cmd, &flock);
   487			if (!err && copy_to_user(argp, &flock, sizeof(flock)))
   488				return -EFAULT;
   489			break;
   490	#if BITS_PER_LONG != 32
   491		/* 32-bit arches must use fcntl64() */
   492		case F_OFD_SETLK:
   493		case F_OFD_SETLKW:
   494			fallthrough;
   495	#endif
   496		case F_SETLK:
   497		case F_SETLKW:
   498			if (copy_from_user(&flock, argp, sizeof(flock)))
   499				return -EFAULT;
   500			err = fcntl_setlk(fd, filp, cmd, &flock);
   501			break;
   502		case F_GETOWN:
   503			/*
   504			 * XXX If f_owner is a process group, the
   505			 * negative return value will get converted
   506			 * into an error.  Oops.  If we keep the
   507			 * current syscall conventions, the only way
   508			 * to fix this will be in libc.
   509			 */
   510			err = f_getown(filp);
   511			force_successful_syscall_return();
   512			break;
   513		case F_SETOWN:
   514			err = f_setown(filp, argi, 1);
   515			break;
   516		case F_GETOWN_EX:
   517			err = f_getown_ex(filp, arg);
   518			break;
   519		case F_SETOWN_EX:
   520			err = f_setown_ex(filp, arg);
   521			break;
   522		case F_GETOWNER_UIDS:
   523			err = f_getowner_uids(filp, arg);
   524			break;
   525		case F_GETSIG:
   526			err = f_owner_sig(filp, 0, false);
   527			break;
   528		case F_SETSIG:
   529			err = f_owner_sig(filp, argi, true);
   530			break;
   531		case F_GETLEASE:
   532			err = fcntl_getlease(filp);
   533			break;
   534		case F_SETLEASE:
   535			err = fcntl_setlease(fd, filp, argi);
   536			break;
   537		case F_NOTIFY:
   538			err = fcntl_dirnotify(fd, filp, argi);
   539			break;
   540		case F_SETPIPE_SZ:
   541		case F_GETPIPE_SZ:
   542			err = pipe_fcntl(filp, cmd, argi);
   543			break;
   544		case F_ADD_SEALS:
   545		case F_GET_SEALS:
   546			err = memfd_fcntl(filp, cmd, argi);
   547			break;
   548		case F_GET_RW_HINT:
   549			err = fcntl_get_rw_hint(filp, arg);
   550			break;
   551		case F_SET_RW_HINT:
   552			err = fcntl_set_rw_hint(filp, arg);
   553			break;
   554		case F_GETDELEG:
   555			if (copy_from_user(&deleg, argp, sizeof(deleg)))
   556				return -EFAULT;
 > 557			fcntl_getdeleg(filp, &deleg);
   558			if (copy_to_user(argp, &deleg, sizeof(deleg)))
   559				return -EFAULT;
   560			err = 0;
   561			break;
   562		case F_SETDELEG:
   563			if (copy_from_user(&deleg, argp, sizeof(deleg)))
   564				return -EFAULT;
   565			err = fcntl_setdeleg(fd, filp, &deleg);
   566			break;
   567		default:
   568			break;
   569		}
   570		return err;
   571	}
   572	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2025-11-02  2:39 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-11-02  2:38 [jlayton:kdevops 18/18] fs/fcntl.c:557:3: error: too many arguments to function 'fcntl_getdeleg' kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.