Hi, [FYI, it's a private test report for your RFC patch.] [auto build test WARNING on linus/master] [also build test WARNING on v5.11-rc2 next-20210104] [cannot apply to linux/master hnaz-linux-mm/master] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch] url: https://github.com/0day-ci/linux/commits/laniel_francis-privacyrequired-com/Create-header-for-fortified-string-functions/20210107-230744 base: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git e71ba9452f0b5b2e8dc8aa5445198cd9214a6a62 config: arm-randconfig-s032-20210107 (attached as .config) compiler: arm-linux-gnueabi-gcc (GCC) 9.3.0 reproduce: wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # apt-get install sparse # sparse version: v0.6.3-208-g46a52ca4-dirty # https://github.com/0day-ci/linux/commit/81d740d53ef9c7156a507c3782dab9dac21927d3 git remote add linux-review https://github.com/0day-ci/linux git fetch --no-tags linux-review laniel_francis-privacyrequired-com/Create-header-for-fortified-string-functions/20210107-230744 git checkout 81d740d53ef9c7156a507c3782dab9dac21927d3 # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=arm If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All warnings (new ones prefixed by >>): In file included from include/linux/string.h:269, from include/linux/bitmap.h:9, from include/linux/cpumask.h:12, from include/linux/smp.h:13, from include/linux/lockdep.h:14, from include/linux/spinlock.h:59, from include/linux/ipc.h:5, from include/uapi/linux/sem.h:5, from include/linux/sem.h:5, from include/linux/compat.h:14, from drivers/hid/uhid.c:11: In function 'strncpy', inlined from 'uhid_dev_create2' at drivers/hid/uhid.c:499:2, inlined from 'uhid_char_write' at drivers/hid/uhid.c:738:9: >> include/linux/fortify-string.h:27:30: warning: '__builtin_strncpy' output may be truncated copying 127 bytes from a string of length 127 [-Wstringop-truncation] 27 | #define __underlying_strncpy __builtin_strncpy | ^ include/linux/fortify-string.h:38:9: note: in expansion of macro '__underlying_strncpy' 38 | return __underlying_strncpy(p, q, size); | ^~~~~~~~~~~~~~~~~~~~ In function 'strncpy', inlined from 'uhid_dev_create2' at drivers/hid/uhid.c:501:2, inlined from 'uhid_char_write' at drivers/hid/uhid.c:738:9: include/linux/fortify-string.h:27:30: warning: '__builtin_strncpy' output may be truncated copying 63 bytes from a string of length 63 [-Wstringop-truncation] 27 | #define __underlying_strncpy __builtin_strncpy | ^ include/linux/fortify-string.h:38:9: note: in expansion of macro '__underlying_strncpy' 38 | return __underlying_strncpy(p, q, size); | ^~~~~~~~~~~~~~~~~~~~ In function 'strncpy', inlined from 'uhid_dev_create2' at drivers/hid/uhid.c:503:2, inlined from 'uhid_char_write' at drivers/hid/uhid.c:738:9: include/linux/fortify-string.h:27:30: warning: '__builtin_strncpy' output may be truncated copying 63 bytes from a string of length 63 [-Wstringop-truncation] 27 | #define __underlying_strncpy __builtin_strncpy | ^ include/linux/fortify-string.h:38:9: note: in expansion of macro '__underlying_strncpy' 38 | return __underlying_strncpy(p, q, size); | ^~~~~~~~~~~~~~~~~~~~ -- In file included from include/linux/string.h:269, from include/linux/bitmap.h:9, from include/linux/cpumask.h:12, from include/linux/smp.h:13, from include/linux/lockdep.h:14, from include/linux/rcupdate.h:29, from include/linux/rculist.h:11, from include/linux/pid.h:5, from include/linux/sched.h:14, from include/linux/ratelimit.h:6, from include/linux/dev_printk.h:16, from include/linux/device.h:15, from drivers/i3c/master.c:10: In function 'strncpy', inlined from 'i3c_master_i2c_adapter_init' at drivers/i3c/master.c:2186:2, inlined from 'i3c_master_register' at drivers/i3c/master.c:2550:8: >> include/linux/fortify-string.h:27:30: warning: '__builtin_strncpy' specified bound 48 equals destination size [-Wstringop-truncation] 27 | #define __underlying_strncpy __builtin_strncpy | ^ include/linux/fortify-string.h:38:9: note: in expansion of macro '__underlying_strncpy' 38 | return __underlying_strncpy(p, q, size); | ^~~~~~~~~~~~~~~~~~~~ vim +/__builtin_strncpy +27 include/linux/fortify-string.h 4 5 6 #if defined(CONFIG_KASAN_GENERIC) || defined(CONFIG_KASAN_SW_TAGS) 7 extern void *__underlying_memchr(const void *p, int c, __kernel_size_t size) __RENAME(memchr); 8 extern int __underlying_memcmp(const void *p, const void *q, __kernel_size_t size) __RENAME(memcmp); 9 extern void *__underlying_memcpy(void *p, const void *q, __kernel_size_t size) __RENAME(memcpy); 10 extern void *__underlying_memmove(void *p, const void *q, __kernel_size_t size) __RENAME(memmove); 11 extern void *__underlying_memset(void *p, int c, __kernel_size_t size) __RENAME(memset); 12 extern char *__underlying_strcat(char *p, const char *q) __RENAME(strcat); 13 extern char *__underlying_strcpy(char *p, const char *q) __RENAME(strcpy); 14 extern __kernel_size_t __underlying_strlen(const char *p) __RENAME(strlen); 15 extern char *__underlying_strncat(char *p, const char *q, __kernel_size_t count) __RENAME(strncat); 16 extern char *__underlying_strncpy(char *p, const char *q, __kernel_size_t size) __RENAME(strncpy); 17 #else 18 #define __underlying_memchr __builtin_memchr 19 #define __underlying_memcmp __builtin_memcmp 20 #define __underlying_memcpy __builtin_memcpy 21 #define __underlying_memmove __builtin_memmove 22 #define __underlying_memset __builtin_memset 23 #define __underlying_strcat __builtin_strcat 24 #define __underlying_strcpy __builtin_strcpy 25 #define __underlying_strlen __builtin_strlen 26 #define __underlying_strncat __builtin_strncat > 27 #define __underlying_strncpy __builtin_strncpy 28 #endif 29 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org