Hi Ivan,
kernel test robot noticed the following build warnings:
[auto build test WARNING on shuah-kselftest/kunit] [also build test WARNING on linus/master v6.9-rc7 next-20240508] [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#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Ivan-Orlov/kunit-Cover-assert... base: https://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest.git kunit patch link: https://lore.kernel.org/r/20240508132557.599213-1-ivan.orlov0322%40gmail.com patch subject: [PATCH v2] kunit: Cover 'assert.c' with tests config: x86_64-randconfig-121-20240509 (https://download.01.org/0day-ci/archive/20240509/202405091128.Rh6iS2He-lkp@i...) compiler: clang version 18.1.4 (https://github.com/llvm/llvm-project e6c3289804a67ea0bb6a86fadbe454dd93b8d855) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240509/202405091128.Rh6iS2He-lkp@i...)
If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot lkp@intel.com | Closes: https://lore.kernel.org/oe-kbuild-all/202405091128.Rh6iS2He-lkp@intel.com/
sparse warnings: (new ones prefixed by >>)
lib/kunit/assert_test.c:368:19: sparse: sparse: symbol 'assert_test_cases' was not declared. Should it be static? lib/kunit/assert_test.c:383:20: sparse: sparse: symbol 'assert_test_suite' was not declared. Should it be static?
vim +/assert_test_cases +368 lib/kunit/assert_test.c
367
368 struct kunit_case assert_test_cases[] = {
369 KUNIT_CASE(kunit_test_is_literal), 370 KUNIT_CASE(kunit_test_is_str_literal), 371 KUNIT_CASE(kunit_test_assert_prologue), 372 KUNIT_CASE(kunit_test_assert_print_msg), 373 KUNIT_CASE(kunit_test_unary_assert_format), 374 KUNIT_CASE(kunit_test_ptr_not_err_assert_format), 375 KUNIT_CASE(kunit_test_binary_assert_format), 376 KUNIT_CASE(kunit_test_binary_ptr_assert_format), 377 KUNIT_CASE(kunit_test_binary_str_assert_format), 378 KUNIT_CASE(kunit_test_assert_hexdump), 379 KUNIT_CASE(kunit_test_mem_assert_format), 380 {} 381 }; 382
383 struct kunit_suite assert_test_suite = {
384 .name = "kunit-assert", 385 .test_cases = assert_test_cases, 386 }; 387