* [linux-next:master 13878/13946] fs/namespace.c:3031:55: error: expected ')' before ';' token
@ 2019-09-26 21:02 kbuild test robot
0 siblings, 0 replies; only message in thread
From: kbuild test robot @ 2019-09-26 21:02 UTC (permalink / raw)
To: Andrey Konovalov
Cc: kbuild-all, Mark Brown, Khalid Aziz, Vincenzo Frascino,
Kees Cook, Catalin Marinas, Andrew Morton,
Linux Memory Management List
[-- Attachment #1: Type: text/plain, Size: 2643 bytes --]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head: d47175169c28eedd2cc2ab8c01f38764cb0269cc
commit: c1e6784607ec548d505ff2dab0312141a20d04ed [13878/13946] fs/namespace: untag user pointers in copy_mount_options
config: sparc64-allmodconfig (attached as .config)
compiler: sparc64-linux-gcc (GCC) 7.4.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout c1e6784607ec548d505ff2dab0312141a20d04ed
# 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 <lkp@intel.com>
All error/warnings (new ones prefixed by >>):
fs/namespace.c: In function 'copy_mount_options':
>> fs/namespace.c:3031:55: error: expected ')' before ';' token
size = TASK_SIZE - (unsigned long)untagged_addr(data);
^
>> fs/namespace.c:3043:1: error: expected ';' before '}' token
}
^
fs/namespace.c:3015:6: warning: unused variable 'i' [-Wunused-variable]
int i;
^
>> fs/namespace.c:3043:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^
At top level:
fs/namespace.c:2991:13: warning: 'exact_copy_from_user' defined but not used [-Wunused-function]
static long exact_copy_from_user(void *to, const void __user * from,
^~~~~~~~~~~~~~~~~~~~
vim +3031 fs/namespace.c
3012
3013 void *copy_mount_options(const void __user * data)
3014 {
3015 int i;
3016 unsigned long size;
3017 char *copy;
3018
3019 if (!data)
3020 return NULL;
3021
3022 copy = kmalloc(PAGE_SIZE, GFP_KERNEL);
3023 if (!copy)
3024 return ERR_PTR(-ENOMEM);
3025
3026 /* We only care that *some* data at the address the user
3027 * gave us is valid. Just in case, we'll zero
3028 * the remainder of the page.
3029 */
3030 /* copy_from_user cannot cross TASK_SIZE ! */
> 3031 size = TASK_SIZE - (unsigned long)untagged_addr(data);
3032 if (size > PAGE_SIZE)
3033 size = PAGE_SIZE;
3034
3035 i = size - exact_copy_from_user(copy, data, size);
3036 if (!i) {
3037 kfree(copy);
3038 return ERR_PTR(-EFAULT);
3039 }
3040 if (i != PAGE_SIZE)
3041 memset(copy + i, 0, PAGE_SIZE - i);
3042 return copy;
> 3043 }
3044
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 59052 bytes --]
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2019-09-26 21:02 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-26 21:02 [linux-next:master 13878/13946] fs/namespace.c:3031:55: error: expected ')' before ';' token kbuild test robot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox