* [intel-linux-intel-lts:5.4/yocto 414/1142] include/linux/string.h:294:30: error: '__builtin_strncpy' output truncated before terminating nul copying 8 bytes from a string of the same length
@ 2020-08-20 11:54 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2020-08-20 11:54 UTC (permalink / raw)
To: kbuild-all
[-- Attachment #1: Type: text/plain, Size: 8747 bytes --]
tree: https://github.com/intel/linux-intel-lts.git 5.4/yocto
head: eeb611e5394c56d45c5cc8f7dc484c9f19e93143
commit: 792c8003efc4d75b5f52db70e7380b6a425bdba8 [414/1142] xlink-pcie: XLink PCIe Remote and Local Host driver
config: powerpc-allyesconfig (attached as .config)
compiler: powerpc64-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
git checkout 792c8003efc4d75b5f52db70e7380b6a425bdba8
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=powerpc
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 >>):
drivers/misc/xlink-pcie/local_host/mxlk_epf.c:104:6: error: no previous prototype for 'mxlk_register_host_irq' [-Werror=missing-prototypes]
104 | void mxlk_register_host_irq(struct mxlk *mxlk, irq_handler_t func)
| ^~~~~~~~~~~~~~~~~~~~~~
drivers/misc/xlink-pcie/local_host/mxlk_epf.c:111:5: error: no previous prototype for 'mxlk_raise_irq' [-Werror=missing-prototypes]
111 | int mxlk_raise_irq(struct mxlk *mxlk, enum mxlk_doorbell_type type)
| ^~~~~~~~~~~~~~
drivers/misc/xlink-pcie/local_host/mxlk_epf.c:144:5: error: no previous prototype for 'mxlk_copy_from_host_ll' [-Werror=missing-prototypes]
144 | int mxlk_copy_from_host_ll(struct mxlk *mxlk, int chan, int descs_num)
| ^~~~~~~~~~~~~~~~~~~~~~
drivers/misc/xlink-pcie/local_host/mxlk_epf.c:152:5: error: no previous prototype for 'mxlk_copy_to_host_ll' [-Werror=missing-prototypes]
152 | int mxlk_copy_to_host_ll(struct mxlk *mxlk, int chan, int descs_num)
| ^~~~~~~~~~~~~~~~~~~~
drivers/misc/xlink-pcie/local_host/mxlk_epf.c: In function 'epf_bind':
drivers/misc/xlink-pcie/local_host/mxlk_epf.c:306:7: error: variable 'msi_capable' set but not used [-Werror=unused-but-set-variable]
306 | bool msi_capable = true;
| ^~~~~~~~~~~
In file included from arch/powerpc/include/asm/paca.h:15,
from arch/powerpc/include/asm/current.h:13,
from include/linux/thread_info.h:21,
from include/asm-generic/preempt.h:5,
from ./arch/powerpc/include/generated/asm/preempt.h:1,
from include/linux/preempt.h:78,
from include/linux/spinlock.h:51,
from include/linux/seqlock.h:36,
from include/linux/time.h:6,
from include/linux/stat.h:19,
from include/linux/module.h:10,
from drivers/misc/xlink-pcie/local_host/mxlk_epf.c:11:
In function 'strncpy',
inlined from 'epf_bind' at drivers/misc/xlink-pcie/local_host/mxlk_epf.c:392:2:
>> include/linux/string.h:294:30: error: '__builtin_strncpy' output truncated before terminating nul copying 8 bytes from a string of the same length [-Werror=stringop-truncation]
294 | #define __underlying_strncpy __builtin_strncpy
| ^
include/linux/string.h:304:9: note: in expansion of macro '__underlying_strncpy'
304 | return __underlying_strncpy(p, q, size);
| ^~~~~~~~~~~~~~~~~~~~
In function 'strncpy',
inlined from 'epf_bind' at drivers/misc/xlink-pcie/local_host/mxlk_epf.c:399:2:
>> include/linux/string.h:294:30: error: '__builtin_strncpy' output truncated before terminating nul copying 8 bytes from a string of the same length [-Werror=stringop-truncation]
294 | #define __underlying_strncpy __builtin_strncpy
| ^
include/linux/string.h:304:9: note: in expansion of macro '__underlying_strncpy'
304 | return __underlying_strncpy(p, q, size);
| ^~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
In file included from arch/powerpc/include/asm/paca.h:15,
from arch/powerpc/include/asm/current.h:13,
from include/linux/thread_info.h:21,
from include/asm-generic/preempt.h:5,
from ./arch/powerpc/include/generated/asm/preempt.h:1,
from include/linux/preempt.h:78,
from include/linux/spinlock.h:51,
from include/linux/seqlock.h:36,
from include/linux/time.h:6,
from include/linux/stat.h:19,
from include/linux/module.h:10,
from drivers/misc/xlink-pcie/local_host/mxlk_inf.c:11:
In function 'strncpy',
inlined from 'xlink_pcie_get_device_name' at drivers/misc/xlink-pcie/local_host/mxlk_inf.c:41:2:
>> include/linux/string.h:294:30: error: '__builtin_strncpy' output truncated copying between 0 and 13 bytes from a string of length 13 [-Werror=stringop-truncation]
294 | #define __underlying_strncpy __builtin_strncpy
| ^
include/linux/string.h:304:9: note: in expansion of macro '__underlying_strncpy'
304 | return __underlying_strncpy(p, q, size);
| ^~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
# https://github.com/intel/linux-intel-lts/commit/792c8003efc4d75b5f52db70e7380b6a425bdba8
git remote add intel-linux-intel-lts https://github.com/intel/linux-intel-lts.git
git fetch --no-tags intel-linux-intel-lts 5.4/yocto
git checkout 792c8003efc4d75b5f52db70e7380b6a425bdba8
vim +/__builtin_strncpy +294 include/linux/string.h
b008ae4cc74d3a Daniel Axtens 2020-06-03 272
b008ae4cc74d3a Daniel Axtens 2020-06-03 273 #ifdef CONFIG_KASAN
b008ae4cc74d3a Daniel Axtens 2020-06-03 274 extern void *__underlying_memchr(const void *p, int c, __kernel_size_t size) __RENAME(memchr);
b008ae4cc74d3a Daniel Axtens 2020-06-03 275 extern int __underlying_memcmp(const void *p, const void *q, __kernel_size_t size) __RENAME(memcmp);
b008ae4cc74d3a Daniel Axtens 2020-06-03 276 extern void *__underlying_memcpy(void *p, const void *q, __kernel_size_t size) __RENAME(memcpy);
b008ae4cc74d3a Daniel Axtens 2020-06-03 277 extern void *__underlying_memmove(void *p, const void *q, __kernel_size_t size) __RENAME(memmove);
b008ae4cc74d3a Daniel Axtens 2020-06-03 278 extern void *__underlying_memset(void *p, int c, __kernel_size_t size) __RENAME(memset);
b008ae4cc74d3a Daniel Axtens 2020-06-03 279 extern char *__underlying_strcat(char *p, const char *q) __RENAME(strcat);
b008ae4cc74d3a Daniel Axtens 2020-06-03 280 extern char *__underlying_strcpy(char *p, const char *q) __RENAME(strcpy);
b008ae4cc74d3a Daniel Axtens 2020-06-03 281 extern __kernel_size_t __underlying_strlen(const char *p) __RENAME(strlen);
b008ae4cc74d3a Daniel Axtens 2020-06-03 282 extern char *__underlying_strncat(char *p, const char *q, __kernel_size_t count) __RENAME(strncat);
b008ae4cc74d3a Daniel Axtens 2020-06-03 283 extern char *__underlying_strncpy(char *p, const char *q, __kernel_size_t size) __RENAME(strncpy);
b008ae4cc74d3a Daniel Axtens 2020-06-03 284 #else
b008ae4cc74d3a Daniel Axtens 2020-06-03 285 #define __underlying_memchr __builtin_memchr
b008ae4cc74d3a Daniel Axtens 2020-06-03 286 #define __underlying_memcmp __builtin_memcmp
b008ae4cc74d3a Daniel Axtens 2020-06-03 287 #define __underlying_memcpy __builtin_memcpy
b008ae4cc74d3a Daniel Axtens 2020-06-03 288 #define __underlying_memmove __builtin_memmove
b008ae4cc74d3a Daniel Axtens 2020-06-03 289 #define __underlying_memset __builtin_memset
b008ae4cc74d3a Daniel Axtens 2020-06-03 290 #define __underlying_strcat __builtin_strcat
b008ae4cc74d3a Daniel Axtens 2020-06-03 291 #define __underlying_strcpy __builtin_strcpy
b008ae4cc74d3a Daniel Axtens 2020-06-03 292 #define __underlying_strlen __builtin_strlen
b008ae4cc74d3a Daniel Axtens 2020-06-03 293 #define __underlying_strncat __builtin_strncat
b008ae4cc74d3a Daniel Axtens 2020-06-03 @294 #define __underlying_strncpy __builtin_strncpy
b008ae4cc74d3a Daniel Axtens 2020-06-03 295 #endif
b008ae4cc74d3a Daniel Axtens 2020-06-03 296
:::::: The code at line 294 was first introduced by commit
:::::: b008ae4cc74d3ab43074099746f6c32d353e01aa string.h: fix incompatibility between FORTIFY_SOURCE and KASAN
:::::: TO: Daniel Axtens <dja@axtens.net>
:::::: CC: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 63907 bytes --]
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2020-08-20 11:54 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-08-20 11:54 [intel-linux-intel-lts:5.4/yocto 414/1142] include/linux/string.h:294:30: error: '__builtin_strncpy' output truncated before terminating nul copying 8 bytes from a string of the same length 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.