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  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]
Date:   Wed, 6 Oct 2021 06:16:21 +0800
From:   kernel test robot <lkp@...el.com>
To:     Steven Rostedt <rostedt@...dmis.org>
Cc:     kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org,
        0day robot <lkp@...el.com>
Subject: kernel/trace/ftrace.c:208: undefined reference to
 `ftrace_ops_list_func'

tree:   https://github.com/0day-ci/linux/commits/UPDATE-20211006-003617/Gustavo-A-R-Silva/ftrace-Fix-Wcast-function-type-warnings-on-powerpc64/20211005-133606
head:   200d9dd9fd167dae7f84464ff025b6d9bb2bc635
commit: 200d9dd9fd167dae7f84464ff025b6d9bb2bc635 ftrace: Fix -Wcast-function-type warnings on powerpc64
date:   6 hours ago
config: x86_64-randconfig-a012-20211004 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
        # https://github.com/0day-ci/linux/commit/200d9dd9fd167dae7f84464ff025b6d9bb2bc635
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review UPDATE-20211006-003617/Gustavo-A-R-Silva/ftrace-Fix-Wcast-function-type-warnings-on-powerpc64/20211005-133606
        git checkout 200d9dd9fd167dae7f84464ff025b6d9bb2bc635
        # save the attached .config to linux build tree
        mkdir build_dir
        make W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash

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

All errors (new ones prefixed by >>):

   ld: kernel/trace/ftrace.o: in function `update_ftrace_function':
>> kernel/trace/ftrace.c:208: undefined reference to `ftrace_ops_list_func'
>> ld: kernel/trace/ftrace.c:216: undefined reference to `ftrace_ops_list_func'
   ld: kernel/trace/ftrace.c:215: undefined reference to `ftrace_ops_list_func'
   ld: kernel/trace/ftrace.c:235: undefined reference to `ftrace_ops_list_func'


vim +208 kernel/trace/ftrace.c

00ccbf2f5b7580 Steven Rostedt (Red Hat  2015-02-19  173) 
2b499381bc50ed Steven Rostedt           2011-05-03  174  static void update_ftrace_function(void)
2b499381bc50ed Steven Rostedt           2011-05-03  175  {
2b499381bc50ed Steven Rostedt           2011-05-03  176  	ftrace_func_t func;
2b499381bc50ed Steven Rostedt           2011-05-03  177  
f7aad4e1a82212 Steven Rostedt (Red Hat  2014-09-10  178) 	/*
f7aad4e1a82212 Steven Rostedt (Red Hat  2014-09-10  179) 	 * Prepare the ftrace_ops that the arch callback will use.
f7aad4e1a82212 Steven Rostedt (Red Hat  2014-09-10  180) 	 * If there's only one ftrace_ops registered, the ftrace_ops_list
f7aad4e1a82212 Steven Rostedt (Red Hat  2014-09-10  181) 	 * will point to the ops we want.
f7aad4e1a82212 Steven Rostedt (Red Hat  2014-09-10  182) 	 */
f86f418059b94a Chunyan Zhang            2017-06-07  183  	set_function_trace_op = rcu_dereference_protected(ftrace_ops_list,
f86f418059b94a Chunyan Zhang            2017-06-07  184  						lockdep_is_held(&ftrace_lock));
f7aad4e1a82212 Steven Rostedt (Red Hat  2014-09-10  185) 
f7aad4e1a82212 Steven Rostedt (Red Hat  2014-09-10  186) 	/* If there's no ftrace_ops registered, just call the stub function */
f86f418059b94a Chunyan Zhang            2017-06-07  187  	if (set_function_trace_op == &ftrace_list_end) {
f7aad4e1a82212 Steven Rostedt (Red Hat  2014-09-10  188) 		func = ftrace_stub;
f7aad4e1a82212 Steven Rostedt (Red Hat  2014-09-10  189) 
cdbe61bfe70440 Steven Rostedt           2011-05-05  190  	/*
cdbe61bfe70440 Steven Rostedt           2011-05-05  191  	 * If we are at the end of the list and this ops is
4740974a684415 Steven Rostedt           2012-07-20  192  	 * recursion safe and not dynamic and the arch supports passing ops,
4740974a684415 Steven Rostedt           2012-07-20  193  	 * then have the mcount trampoline call the function directly.
cdbe61bfe70440 Steven Rostedt           2011-05-05  194  	 */
f86f418059b94a Chunyan Zhang            2017-06-07  195  	} else if (rcu_dereference_protected(ftrace_ops_list->next,
f86f418059b94a Chunyan Zhang            2017-06-07  196  			lockdep_is_held(&ftrace_lock)) == &ftrace_list_end) {
00ccbf2f5b7580 Steven Rostedt (Red Hat  2015-02-19  197) 		func = ftrace_ops_get_list_func(ftrace_ops_list);
f7aad4e1a82212 Steven Rostedt (Red Hat  2014-09-10  198) 
2f5f6ad9390c1e Steven Rostedt           2011-08-08  199  	} else {
2f5f6ad9390c1e Steven Rostedt           2011-08-08  200  		/* Just use the default ftrace_ops */
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  201) 		set_function_trace_op = &ftrace_list_end;
b848914ce39589 Steven Rostedt           2011-05-04  202  		func = ftrace_ops_list_func;
2f5f6ad9390c1e Steven Rostedt           2011-08-08  203  	}
2b499381bc50ed Steven Rostedt           2011-05-03  204  
5f8bf2d263a20b Steven Rostedt (Red Hat  2014-07-15  205) 	update_function_graph_func();
5f8bf2d263a20b Steven Rostedt (Red Hat  2014-07-15  206) 
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  207) 	/* If there's no change, then do nothing more here */
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08 @208) 	if (ftrace_trace_function == func)
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  209) 		return;
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  210) 
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  211) 	/*
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  212) 	 * If we are using the list function, it doesn't care
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  213) 	 * about the function_trace_ops.
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  214) 	 */
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  215) 	if (func == ftrace_ops_list_func) {
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08 @216) 		ftrace_trace_function = func;
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  217) 		/*
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  218) 		 * Don't even bother setting function_trace_ops,
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  219) 		 * it would be racy to do so anyway.
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  220) 		 */
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  221) 		return;
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  222) 	}
405e1d834807e5 Steven Rostedt (Red Hat  2013-11-08  223) 

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

Download attachment ".config.gz" of type "application/gzip" (35493 bytes)

Powered by blists - more mailing lists