lkml.org 
[lkml]   [2022]   [Jul]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v4 4/4] selftest: Taint kernel when test module loaded
Hi David,

I love your patch! Yet something to improve:

[auto build test ERROR on masahiroy-kbuild/for-next]
[also build test ERROR on shuah-kselftest/next linus/master v5.19-rc4 next-20220701]
[cannot apply to mcgrof/modules-next]
[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/intel-lab-lkp/linux/commits/David-Gow/panic-Taint-kernel-if-tests-are-run/20220701-164843
base: https://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild.git for-next
config: arm-randconfig-r024-20220629 (https://download.01.org/0day-ci/archive/20220702/202207020131.L5kV3eDf-lkp@intel.com/config)
compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project a9119143a2d1f4d0d0bc1fe0d819e5351b4e0deb)
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
# install arm cross compiling tool for clang build
# apt-get install binutils-arm-linux-gnueabi
# https://github.com/intel-lab-lkp/linux/commit/42b6461d6cca4baeeeed474b1400e203057c2b9b
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review David-Gow/panic-Taint-kernel-if-tests-are-run/20220701-164843
git checkout 42b6461d6cca4baeeeed474b1400e203057c2b9b
# 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=arm SHELL=/bin/bash lib/

If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

lib/test_printf.c:157:52: warning: format specifies type 'unsigned char' but the argument has type 'int' [-Wformat]
test("0|1|1|128|255", "%hhu|%hhu|%hhu|%hhu|%hhu", 0, 1, 257, 128, -1);
~~~~ ^
%d
lib/test_printf.c:137:40: note: expanded from macro 'test'
__test(expect, strlen(expect), fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
lib/test_printf.c:157:55: warning: format specifies type 'unsigned char' but the argument has type 'int' [-Wformat]
test("0|1|1|128|255", "%hhu|%hhu|%hhu|%hhu|%hhu", 0, 1, 257, 128, -1);
~~~~ ^
%d
lib/test_printf.c:137:40: note: expanded from macro 'test'
__test(expect, strlen(expect), fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
lib/test_printf.c:157:58: warning: format specifies type 'unsigned char' but the argument has type 'int' [-Wformat]
test("0|1|1|128|255", "%hhu|%hhu|%hhu|%hhu|%hhu", 0, 1, 257, 128, -1);
~~~~ ^~~
%d
lib/test_printf.c:137:40: note: expanded from macro 'test'
__test(expect, strlen(expect), fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
lib/test_printf.c:157:63: warning: format specifies type 'unsigned char' but the argument has type 'int' [-Wformat]
test("0|1|1|128|255", "%hhu|%hhu|%hhu|%hhu|%hhu", 0, 1, 257, 128, -1);
~~~~ ^~~
%d
lib/test_printf.c:137:40: note: expanded from macro 'test'
__test(expect, strlen(expect), fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
lib/test_printf.c:157:68: warning: format specifies type 'unsigned char' but the argument has type 'int' [-Wformat]
test("0|1|1|128|255", "%hhu|%hhu|%hhu|%hhu|%hhu", 0, 1, 257, 128, -1);
~~~~ ^~
%d
lib/test_printf.c:137:40: note: expanded from macro 'test'
__test(expect, strlen(expect), fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
lib/test_printf.c:158:52: warning: format specifies type 'char' but the argument has type 'int' [-Wformat]
test("0|1|1|-128|-1", "%hhd|%hhd|%hhd|%hhd|%hhd", 0, 1, 257, 128, -1);
~~~~ ^
%d
lib/test_printf.c:137:40: note: expanded from macro 'test'
__test(expect, strlen(expect), fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
lib/test_printf.c:158:55: warning: format specifies type 'char' but the argument has type 'int' [-Wformat]
test("0|1|1|-128|-1", "%hhd|%hhd|%hhd|%hhd|%hhd", 0, 1, 257, 128, -1);
~~~~ ^
%d
lib/test_printf.c:137:40: note: expanded from macro 'test'
__test(expect, strlen(expect), fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
lib/test_printf.c:158:58: warning: format specifies type 'char' but the argument has type 'int' [-Wformat]
test("0|1|1|-128|-1", "%hhd|%hhd|%hhd|%hhd|%hhd", 0, 1, 257, 128, -1);
~~~~ ^~~
%d
lib/test_printf.c:137:40: note: expanded from macro 'test'
__test(expect, strlen(expect), fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
lib/test_printf.c:158:63: warning: format specifies type 'char' but the argument has type 'int' [-Wformat]
test("0|1|1|-128|-1", "%hhd|%hhd|%hhd|%hhd|%hhd", 0, 1, 257, 128, -1);
~~~~ ^~~
%d
lib/test_printf.c:137:40: note: expanded from macro 'test'
__test(expect, strlen(expect), fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
lib/test_printf.c:158:68: warning: format specifies type 'char' but the argument has type 'int' [-Wformat]
test("0|1|1|-128|-1", "%hhd|%hhd|%hhd|%hhd|%hhd", 0, 1, 257, 128, -1);
~~~~ ^~
%d
lib/test_printf.c:137:40: note: expanded from macro 'test'
__test(expect, strlen(expect), fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
lib/test_printf.c:159:41: warning: format specifies type 'unsigned short' but the argument has type 'int' [-Wformat]
test("2015122420151225", "%ho%ho%#ho", 1037, 5282, -11627);
~~~ ^~~~
%o
lib/test_printf.c:137:40: note: expanded from macro 'test'
__test(expect, strlen(expect), fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
lib/test_printf.c:159:47: warning: format specifies type 'unsigned short' but the argument has type 'int' [-Wformat]
test("2015122420151225", "%ho%ho%#ho", 1037, 5282, -11627);
~~~ ^~~~
%o
lib/test_printf.c:137:40: note: expanded from macro 'test'
__test(expect, strlen(expect), fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
lib/test_printf.c:159:53: warning: format specifies type 'unsigned short' but the argument has type 'int' [-Wformat]
test("2015122420151225", "%ho%ho%#ho", 1037, 5282, -11627);
~~~~ ^~~~~~
%#o
lib/test_printf.c:137:40: note: expanded from macro 'test'
__test(expect, strlen(expect), fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
>> lib/test_printf.c:801:1: error: use of undeclared identifier 'TAINT_KUNIT'
KSTM_MODULE_LOADERS(test_printf);
^
lib/../tools/testing/selftests/kselftest_module.h:45:12: note: expanded from macro 'KSTM_MODULE_LOADERS'
add_taint(TAINT_KUNIT, LOCKDEP_STILL_OK); \
^
13 warnings and 1 error generated.
--
>> lib/test_scanf.c:811:1: error: use of undeclared identifier 'TAINT_KUNIT'
KSTM_MODULE_LOADERS(test_scanf);
^
lib/../tools/testing/selftests/kselftest_module.h:45:12: note: expanded from macro 'KSTM_MODULE_LOADERS'
add_taint(TAINT_KUNIT, LOCKDEP_STILL_OK); \
^
1 error generated.
--
>> lib/test_bitmap.c:889:1: error: use of undeclared identifier 'TAINT_KUNIT'
KSTM_MODULE_LOADERS(test_bitmap);
^
lib/../tools/testing/selftests/kselftest_module.h:45:12: note: expanded from macro 'KSTM_MODULE_LOADERS'
add_taint(TAINT_KUNIT, LOCKDEP_STILL_OK); \
^
1 error generated.


vim +/TAINT_KUNIT +801 lib/test_printf.c

707cc7280f452a1 Rasmus Villemoes 2015-11-06 800
6b1a4d5b1a26ae8 Tobin C. Harding 2019-04-05 @801 KSTM_MODULE_LOADERS(test_printf);

--
0-DAY CI Kernel Test Service
https://01.org/lkp

\
 
 \ /
  Last update: 2022-07-01 19:18    [W:2.372 / U:0.036 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site