lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202210140618.pwwBsRCu-lkp@intel.com>
Date:   Fri, 14 Oct 2022 06:34:34 +0800
From:   kernel test robot <lkp@...el.com>
To:     Jiri Olsa <jolsa@...nel.org>
Cc:     kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org
Subject: [jolsa-perf:bpf/tracing_multi_ng_4 13/23]
 samples/ftrace/ftrace-direct-set.c:104:9: error: implicit declaration of
 function 'ftrace_test_0'; did you mean 'ftrace_stub'?

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git bpf/tracing_multi_ng_4
head:   e3fa3b908cc734f85477c07a0ba93480bd80702c
commit: 9b87a14f00b80b0eb8edf9027177af0b09e5b25e [13/23] ftrace/samples: Add a sample module that implements set_ftrace_direct
config: x86_64-rhel-8.3-kselftests
compiler: gcc-11 (Debian 11.3.0-8) 11.3.0
reproduce (this is a W=1 build):
        # https://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git/commit/?id=9b87a14f00b80b0eb8edf9027177af0b09e5b25e
        git remote add jolsa-perf https://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git
        git fetch --no-tags jolsa-perf bpf/tracing_multi_ng_4
        git checkout 9b87a14f00b80b0eb8edf9027177af0b09e5b25e
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        make W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash samples/ftrace/

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

All errors (new ones prefixed by >>):

   samples/ftrace/ftrace-direct-set.c: In function 'runall':
>> samples/ftrace/ftrace-direct-set.c:104:9: error: implicit declaration of function 'ftrace_test_0'; did you mean 'ftrace_stub'? [-Werror=implicit-function-declaration]
     104 |         ftrace_test_0();
         |         ^~~~~~~~~~~~~
         |         ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:105:9: error: implicit declaration of function 'ftrace_test_1'; did you mean 'ftrace_stub'? [-Werror=implicit-function-declaration]
     105 |         ftrace_test_1();
         |         ^~~~~~~~~~~~~
         |         ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:106:9: error: implicit declaration of function 'ftrace_test_2'; did you mean 'ftrace_stub'? [-Werror=implicit-function-declaration]
     106 |         ftrace_test_2();
         |         ^~~~~~~~~~~~~
         |         ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:107:9: error: implicit declaration of function 'ftrace_test_3'; did you mean 'ftrace_stub'? [-Werror=implicit-function-declaration]
     107 |         ftrace_test_3();
         |         ^~~~~~~~~~~~~
         |         ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:108:9: error: implicit declaration of function 'ftrace_test_4'; did you mean 'ftrace_stub'? [-Werror=implicit-function-declaration]
     108 |         ftrace_test_4();
         |         ^~~~~~~~~~~~~
         |         ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:109:9: error: implicit declaration of function 'ftrace_test_5'; did you mean 'ftrace_stub'? [-Werror=implicit-function-declaration]
     109 |         ftrace_test_5();
         |         ^~~~~~~~~~~~~
         |         ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:110:9: error: implicit declaration of function 'ftrace_test_6'; did you mean 'ftrace_stub'? [-Werror=implicit-function-declaration]
     110 |         ftrace_test_6();
         |         ^~~~~~~~~~~~~
         |         ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:111:9: error: implicit declaration of function 'ftrace_test_7'; did you mean 'ftrace_stub'? [-Werror=implicit-function-declaration]
     111 |         ftrace_test_7();
         |         ^~~~~~~~~~~~~
         |         ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:112:9: error: implicit declaration of function 'ftrace_test_8'; did you mean 'ftrace_stub'? [-Werror=implicit-function-declaration]
     112 |         ftrace_test_8();
         |         ^~~~~~~~~~~~~
         |         ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:113:9: error: implicit declaration of function 'ftrace_test_9'; did you mean 'ftrace_stub'? [-Werror=implicit-function-declaration]
     113 |         ftrace_test_9();
         |         ^~~~~~~~~~~~~
         |         ftrace_stub
   samples/ftrace/ftrace-direct-set.c: In function 'ftrace_direct_set_init':
>> samples/ftrace/ftrace-direct-set.c:136:18: error: 'ftrace_test_0' undeclared (first use in this function); did you mean 'ftrace_stub'?
     136 |         hash_set(ftrace_test_0, tramp_0);
         |                  ^~~~~~~~~~~~~
         |                  ftrace_stub
   samples/ftrace/ftrace-direct-set.c:136:18: note: each undeclared identifier is reported only once for each function it appears in
>> samples/ftrace/ftrace-direct-set.c:137:18: error: 'ftrace_test_1' undeclared (first use in this function); did you mean 'ftrace_stub'?
     137 |         hash_set(ftrace_test_1, tramp_1);
         |                  ^~~~~~~~~~~~~
         |                  ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:158:18: error: 'ftrace_test_2' undeclared (first use in this function); did you mean 'ftrace_stub'?
     158 |         hash_set(ftrace_test_2, tramp_0);
         |                  ^~~~~~~~~~~~~
         |                  ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:159:18: error: 'ftrace_test_3' undeclared (first use in this function); did you mean 'ftrace_stub'?
     159 |         hash_set(ftrace_test_3, tramp_0);
         |                  ^~~~~~~~~~~~~
         |                  ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:160:18: error: 'ftrace_test_4' undeclared (first use in this function); did you mean 'ftrace_stub'?
     160 |         hash_set(ftrace_test_4, tramp_4);
         |                  ^~~~~~~~~~~~~
         |                  ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:161:18: error: 'ftrace_test_5' undeclared (first use in this function); did you mean 'ftrace_stub'?
     161 |         hash_set(ftrace_test_5, tramp_5);
         |                  ^~~~~~~~~~~~~
         |                  ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:162:18: error: 'ftrace_test_6' undeclared (first use in this function); did you mean 'ftrace_stub'?
     162 |         hash_set(ftrace_test_6, tramp_6);
         |                  ^~~~~~~~~~~~~
         |                  ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:163:18: error: 'ftrace_test_7' undeclared (first use in this function); did you mean 'ftrace_stub'?
     163 |         hash_set(ftrace_test_7, tramp_7);
         |                  ^~~~~~~~~~~~~
         |                  ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:164:18: error: 'ftrace_test_8' undeclared (first use in this function); did you mean 'ftrace_stub'?
     164 |         hash_set(ftrace_test_8, tramp_8);
         |                  ^~~~~~~~~~~~~
         |                  ftrace_stub
>> samples/ftrace/ftrace-direct-set.c:165:18: error: 'ftrace_test_9' undeclared (first use in this function); did you mean 'ftrace_stub'?
     165 |         hash_set(ftrace_test_9, tramp_9);
         |                  ^~~~~~~~~~~~~
         |                  ftrace_stub
   cc1: some warnings being treated as errors


vim +104 samples/ftrace/ftrace-direct-set.c

    88	
    89	static void runall(const char *str)
    90	{
    91		tramp_0_cnt = 0;
    92		tramp_1_cnt = 0;
    93		tramp_2_cnt = 0;
    94		tramp_3_cnt = 0;
    95		tramp_4_cnt = 0;
    96		tramp_5_cnt = 0;
    97		tramp_6_cnt = 0;
    98		tramp_7_cnt = 0;
    99		tramp_8_cnt = 0;
   100		tramp_9_cnt = 0;
   101	
   102		printk("\nrunning '%s':\n", str);
   103	
 > 104		ftrace_test_0();
 > 105		ftrace_test_1();
 > 106		ftrace_test_2();
 > 107		ftrace_test_3();
 > 108		ftrace_test_4();
 > 109		ftrace_test_5();
 > 110		ftrace_test_6();
 > 111		ftrace_test_7();
 > 112		ftrace_test_8();
 > 113		ftrace_test_9();
   114	
   115		printk("  result: %d%d%d%d%d%d%d%d%d%d\n\n",
   116			tramp_0_cnt,
   117			tramp_1_cnt,
   118			tramp_2_cnt,
   119			tramp_3_cnt,
   120			tramp_4_cnt,
   121			tramp_5_cnt,
   122			tramp_6_cnt,
   123			tramp_7_cnt,
   124			tramp_8_cnt,
   125			tramp_9_cnt);
   126	}
   127	
   128	static int __init ftrace_direct_set_init(void)
   129	{
   130		int err;
   131	
   132		hash = ftrace_hash_alloc(FTRACE_HASH_DEFAULT_BITS);
   133		if (!hash)
   134			return -ENOMEM;
   135	
 > 136		hash_set(ftrace_test_0, tramp_0);
 > 137		hash_set(ftrace_test_1, tramp_1);
   138		hash_printk();
   139	
   140		err = set_ftrace_direct(hash);
   141		if (err)
   142			goto out_free;
   143	
   144		runall("tramp_0|1");
   145	
   146		hash_set(ftrace_test_0, tramp_2);
   147		hash_set(ftrace_test_1, tramp_3);
   148		hash_printk();
   149	
   150		err = set_ftrace_direct(hash);
   151		if (err)
   152			goto out_free;
   153	
   154		runall("tramp_2|3");
   155	
   156		hash_set(ftrace_test_0, tramp_0);
   157		hash_set(ftrace_test_1, tramp_0);
 > 158		hash_set(ftrace_test_2, tramp_0);
 > 159		hash_set(ftrace_test_3, tramp_0);
 > 160		hash_set(ftrace_test_4, tramp_4);
 > 161		hash_set(ftrace_test_5, tramp_5);
 > 162		hash_set(ftrace_test_6, tramp_6);
 > 163		hash_set(ftrace_test_7, tramp_7);
 > 164		hash_set(ftrace_test_8, tramp_8);
 > 165		hash_set(ftrace_test_9, tramp_9);
   166		hash_printk();
   167	
   168		err = set_ftrace_direct(hash);
   169		if (err)
   170			goto out_free;
   171	
   172		runall("tramp_0(4)|4|5|6|7|8|9");
   173	
   174		hash_set(ftrace_test_0, tramp_1);
   175		hash_set(ftrace_test_1, tramp_1);
   176		hash_set(ftrace_test_2, tramp_1);
   177		hash_set(ftrace_test_3, tramp_2);
   178		hash_set(ftrace_test_4, tramp_2);
   179		hash_set(ftrace_test_5, tramp_2);
   180		hash_set(ftrace_test_6, tramp_3);
   181		hash_set(ftrace_test_7, tramp_3);
   182		hash_set(ftrace_test_8, tramp_3);
   183		hash_set(ftrace_test_9, tramp_4);
   184		hash_printk();
   185	
   186		err = set_ftrace_direct(hash);
   187		if (err)
   188			goto out_free;
   189	
   190		runall("tramp_1(3)|2(3)|3(3)|4");
   191		return 0;
   192	
   193	out_free:
   194		ftrace_hash_free(hash);
   195		return -ENOMEM;
   196	}
   197	

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

View attachment "config" of type "text/plain" (168544 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ