[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202212022147.SaQf5HjT-lkp@intel.com>
Date: Fri, 2 Dec 2022 21:43:53 +0800
From: kernel test robot <lkp@...el.com>
To: jeffxu@...omium.org, skhan@...uxfoundation.org,
keescook@...omium.org
Cc: llvm@...ts.linux.dev, oe-kbuild-all@...ts.linux.dev,
akpm@...ux-foundation.org, dmitry.torokhov@...il.com,
dverkamp@...omium.org, hughd@...gle.com, jeffxu@...gle.com,
jorgelo@...omium.org, linux-kernel@...r.kernel.org,
linux-kselftest@...r.kernel.org, linux-mm@...ck.org,
mnissler@...omium.org, jannh@...gle.com,
linux-hardening@...r.kernel.org, Jeff Xu <jeffxu@...omium.org>
Subject: Re: [PATCH v3] mm/memfd: add MFD_NOEXEC_SEAL and MFD_EXEC
Hi,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on akpm-mm/mm-everything]
url: https://github.com/intel-lab-lkp/linux/commits/jeffxu-chromium-org/mm-memfd-add-MFD_NOEXEC_SEAL-and-MFD_EXEC/20221202-093847
base: https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything
patch link: https://lore.kernel.org/r/20221202013404.163143-3-jeffxu%40google.com
patch subject: [PATCH v3] mm/memfd: add MFD_NOEXEC_SEAL and MFD_EXEC
config: i386-randconfig-a013
compiler: clang version 14.0.6 (https://github.com/llvm/llvm-project f28c006a5895fc0e329fe15fead81e37457cb1d1)
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/intel-lab-lkp/linux/commit/d6b8fec1440cb9206bef29eb27359a61e6c73f41
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review jeffxu-chromium-org/mm-memfd-add-MFD_NOEXEC_SEAL-and-MFD_EXEC/20221202-093847
git checkout d6b8fec1440cb9206bef29eb27359a61e6c73f41
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=i386 SHELL=/bin/bash
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@...el.com>
All warnings (new ones prefixed by >>):
>> kernel/pid_namespace.c:263:5: warning: no previous prototype for function 'pid_mfd_noexec_dointvec_minmax' [-Wmissing-prototypes]
int pid_mfd_noexec_dointvec_minmax(struct ctl_table *table, int write,
^
kernel/pid_namespace.c:263:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
int pid_mfd_noexec_dointvec_minmax(struct ctl_table *table, int write,
^
static
1 warning generated.
vim +/pid_mfd_noexec_dointvec_minmax +263 kernel/pid_namespace.c
261
262 #if defined(CONFIG_SYSCTL) && defined(CONFIG_MEMFD_CREATE)
> 263 int pid_mfd_noexec_dointvec_minmax(struct ctl_table *table, int write,
264 void *buffer, size_t *lenp, loff_t *ppos)
265 {
266 struct pid_namespace *ns = task_active_pid_ns(current);
267 struct ctl_table table_copy;
268
269 if (write && !capable(CAP_SYS_ADMIN))
270 return -EPERM;
271
272 table_copy = *table;
273 if (ns != &init_pid_ns)
274 table_copy.data = &ns->memfd_noexec_scope;
275
276 /*
277 * set minimum to current value, the effect is only bigger
278 * value is accepted.
279 */
280 if (*(int *)table_copy.data > *(int *)table_copy.extra1)
281 table_copy.extra1 = table_copy.data;
282
283 return proc_dointvec_minmax(&table_copy, write, buffer, lenp, ppos);
284 }
285
--
0-DAY CI Kernel Test Service
https://01.org/lkp
View attachment "config" of type "text/plain" (156073 bytes)
Powered by blists - more mailing lists