* [asm-generic:asm-generic-uaccess-5 1/8] arch/um/kernel/skas/uaccess.c:246:17: error: 'src' undeclared
@ 2021-07-22 12:43 kernel test robot
2021-07-22 13:27 ` Arnd Bergmann
0 siblings, 1 reply; 2+ messages in thread
From: kernel test robot @ 2021-07-22 12:43 UTC (permalink / raw)
To: Arnd Bergmann; +Cc: kbuild-all, linux-arch
[-- Attachment #1: Type: text/plain, Size: 3073 bytes --]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/arnd/asm-generic.git asm-generic-uaccess-5
head: a8cdb21b715276b7638a636237489f2425c24180
commit: 3a68cb1dbf65aa5c86ae185e5c51c5c26c31a54a [1/8] asm-generic/uaccess.h: remove __strncpy_from_user/__strnlen_user
config: um-x86_64_defconfig (attached as .config)
compiler: gcc-10 (Ubuntu 10.3.0-1ubuntu1~20.04) 10.3.0
reproduce (this is a W=1 build):
# https://git.kernel.org/pub/scm/linux/kernel/git/arnd/asm-generic.git/commit/?id=3a68cb1dbf65aa5c86ae185e5c51c5c26c31a54a
git remote add asm-generic https://git.kernel.org/pub/scm/linux/kernel/git/arnd/asm-generic.git
git fetch --no-tags asm-generic asm-generic-uaccess-5
git checkout 3a68cb1dbf65aa5c86ae185e5c51c5c26c31a54a
# save the attached .config to linux build tree
mkdir build_dir
make W=1 O=build_dir ARCH=um SUBARCH=x86_64 SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
In file included from arch/um/include/asm/uaccess.h:39,
from include/linux/uaccess.h:11,
from include/linux/sched/task.h:11,
from include/linux/sched/signal.h:9,
from include/linux/rcuwait.h:6,
from include/linux/percpu-rwsem.h:7,
from include/linux/fs.h:33,
from include/linux/highmem.h:5,
from arch/um/kernel/skas/uaccess.c:7:
arch/um/kernel/skas/uaccess.c: In function 'strnlen_user':
>> arch/um/kernel/skas/uaccess.c:246:17: error: 'src' undeclared (first use in this function)
246 | if (!access_ok(src, 1))
| ^~~
include/asm-generic/uaccess.h:124:59: note: in definition of macro 'access_ok'
124 | #define access_ok(addr, size) __access_ok((unsigned long)(addr),(size))
| ^~~~
arch/um/kernel/skas/uaccess.c:246:17: note: each undeclared identifier is reported only once for each function it appears in
246 | if (!access_ok(src, 1))
| ^~~
include/asm-generic/uaccess.h:124:59: note: in definition of macro 'access_ok'
124 | #define access_ok(addr, size) __access_ok((unsigned long)(addr),(size))
| ^~~~
vim +/src +246 arch/um/kernel/skas/uaccess.c
241
242 long strnlen_user(const void __user *str, long len)
243 {
244 int count = 0, n;
245
> 246 if (!access_ok(src, 1))
247 return -EFAULT;
248
249 if (uaccess_kernel())
250 return strnlen((__force char*)str, len) + 1;
251
252 n = buffer_op((unsigned long) str, len, 0, strnlen_chunk, &count);
253 if (n == 0)
254 return count + 1;
255 return 0;
256 }
257 EXPORT_SYMBOL(strnlen_user);
258
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 9551 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [asm-generic:asm-generic-uaccess-5 1/8] arch/um/kernel/skas/uaccess.c:246:17: error: 'src' undeclared
2021-07-22 12:43 [asm-generic:asm-generic-uaccess-5 1/8] arch/um/kernel/skas/uaccess.c:246:17: error: 'src' undeclared kernel test robot
@ 2021-07-22 13:27 ` Arnd Bergmann
0 siblings, 0 replies; 2+ messages in thread
From: Arnd Bergmann @ 2021-07-22 13:27 UTC (permalink / raw)
To: kernel test robot; +Cc: Arnd Bergmann, kbuild-all, linux-arch
On Thu, Jul 22, 2021 at 2:43 PM kernel test robot <lkp@intel.com> wrote:
>
> In file included from arch/um/include/asm/uaccess.h:39,
> from include/linux/uaccess.h:11,
> from include/linux/sched/task.h:11,
> from include/linux/sched/signal.h:9,
> from include/linux/rcuwait.h:6,
> from include/linux/percpu-rwsem.h:7,
> from include/linux/fs.h:33,
> from include/linux/highmem.h:5,
> from arch/um/kernel/skas/uaccess.c:7:
> arch/um/kernel/skas/uaccess.c: In function 'strnlen_user':
> >> arch/um/kernel/skas/uaccess.c:246:17: error: 'src' undeclared (first use in this function)
> 246 | if (!access_ok(src, 1))
> | ^~~
Thanks for the report, fixed now.
Arnd
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-07-22 13:28 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-07-22 12:43 [asm-generic:asm-generic-uaccess-5 1/8] arch/um/kernel/skas/uaccess.c:246:17: error: 'src' undeclared kernel test robot
2021-07-22 13:27 ` Arnd Bergmann
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox