All of lore.kernel.org
 help / color / mirror / Atom feed
* arch/nds32/kernel/ftrace.c:29:29: warning: cast between incompatible function types from 'void (*)(long unsigned int,  long unsigned int,  struct ftrace_ops *, struct ftrace_regs *)' to 'void (*)(struct ftrace_graph_ret *)'
@ 2021-07-05  7:13 ` kernel test robot
  0 siblings, 0 replies; 4+ messages in thread
From: kernel test robot @ 2021-07-05  7:13 UTC (permalink / raw)
  To: Steven Rostedt (VMware); +Cc: kbuild-all, linux-kernel, Masami Hiramatsu

[-- Attachment #1: Type: text/plain, Size: 4272 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   a180bd1d7e16173d965b263c5a536aa40afa2a2a
commit: d19ad0775dcd64b49eecf4fa79c17959ebfbd26b ftrace: Have the callbacks receive a struct ftrace_regs instead of pt_regs
date:   8 months ago
config: nds32-randconfig-r016-20210705 (attached as .config)
compiler: nds32le-linux-gcc (GCC) 9.3.0
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
        # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=d19ad0775dcd64b49eecf4fa79c17959ebfbd26b
        git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
        git fetch --no-tags linus master
        git checkout d19ad0775dcd64b49eecf4fa79c17959ebfbd26b
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=nds32 

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

All warnings (new ones prefixed by >>):

   arch/nds32/kernel/ftrace.c: In function '_mcount':
   arch/nds32/kernel/ftrace.c:24:28: warning: comparison of distinct pointer types lacks a cast
      24 |  if (ftrace_trace_function != ftrace_stub)
         |                            ^~
>> arch/nds32/kernel/ftrace.c:29:29: warning: cast between incompatible function types from 'void (*)(long unsigned int,  long unsigned int,  struct ftrace_ops *, struct ftrace_regs *)' to 'void (*)(struct ftrace_graph_ret *)' [-Wcast-function-type]
      29 |  if (ftrace_graph_return != (trace_func_graph_ret_t)ftrace_stub
         |                             ^
   arch/nds32/kernel/ftrace.c: At top level:
   arch/nds32/kernel/ftrace.c:198:6: warning: no previous prototype for 'prepare_ftrace_return' [-Wmissing-prototypes]
     198 | void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr,
         |      ^~~~~~~~~~~~~~~~~~~~~
   arch/nds32/kernel/ftrace.c:275:15: warning: no previous prototype for '__trace_hardirqs_off' [-Wmissing-prototypes]
     275 | noinline void __trace_hardirqs_off(void)
         |               ^~~~~~~~~~~~~~~~~~~~
   arch/nds32/kernel/ftrace.c:279:15: warning: no previous prototype for '__trace_hardirqs_on' [-Wmissing-prototypes]
     279 | noinline void __trace_hardirqs_on(void)
         |               ^~~~~~~~~~~~~~~~~~~


vim +29 arch/nds32/kernel/ftrace.c

a18082575c6648 Zong Li 2018-08-15  17  
a18082575c6648 Zong Li 2018-08-15  18  noinline void _mcount(unsigned long parent_ip)
a18082575c6648 Zong Li 2018-08-15  19  {
a18082575c6648 Zong Li 2018-08-15  20  	/* save all state by the compiler prologue */
a18082575c6648 Zong Li 2018-08-15  21  
a18082575c6648 Zong Li 2018-08-15  22  	unsigned long ip = (unsigned long)__builtin_return_address(0);
a18082575c6648 Zong Li 2018-08-15  23  
a18082575c6648 Zong Li 2018-08-15  24  	if (ftrace_trace_function != ftrace_stub)
a18082575c6648 Zong Li 2018-08-15  25  		ftrace_trace_function(ip - MCOUNT_INSN_SIZE, parent_ip,
a18082575c6648 Zong Li 2018-08-15  26  				      NULL, NULL);
a18082575c6648 Zong Li 2018-08-15  27  
1e9b14c0d92b61 Zong Li 2018-08-15  28  #ifdef CONFIG_FUNCTION_GRAPH_TRACER
1e9b14c0d92b61 Zong Li 2018-08-15 @29  	if (ftrace_graph_return != (trace_func_graph_ret_t)ftrace_stub
1e9b14c0d92b61 Zong Li 2018-08-15  30  	    || ftrace_graph_entry != ftrace_graph_entry_stub)
1e9b14c0d92b61 Zong Li 2018-08-15  31  		ftrace_graph_caller();
1e9b14c0d92b61 Zong Li 2018-08-15  32  #endif
1e9b14c0d92b61 Zong Li 2018-08-15  33  
a18082575c6648 Zong Li 2018-08-15  34  	/* restore all state by the compiler epilogue */
a18082575c6648 Zong Li 2018-08-15  35  }
a18082575c6648 Zong Li 2018-08-15  36  EXPORT_SYMBOL(_mcount);
1e9b14c0d92b61 Zong Li 2018-08-15  37  

:::::: The code at line 29 was first introduced by commit
:::::: 1e9b14c0d92b61a0979fd5ee24d5e7f080f11030 nds32/ftrace: Support static function graph tracer

:::::: TO: Zong Li <zong@andestech.com>
:::::: CC: Greentime Hu <greentime@andestech.com>

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

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 35690 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* arch/nds32/kernel/ftrace.c:29:29: warning: cast between incompatible function types from 'void (*)(long unsigned int, long unsigned int, struct ftrace_ops *, struct ftrace_regs *)' to 'void (*)(struct ftrace_graph_ret *)'
@ 2021-07-05  7:13 ` kernel test robot
  0 siblings, 0 replies; 4+ messages in thread
From: kernel test robot @ 2021-07-05  7:13 UTC (permalink / raw)
  To: kbuild-all

[-- Attachment #1: Type: text/plain, Size: 4347 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   a180bd1d7e16173d965b263c5a536aa40afa2a2a
commit: d19ad0775dcd64b49eecf4fa79c17959ebfbd26b ftrace: Have the callbacks receive a struct ftrace_regs instead of pt_regs
date:   8 months ago
config: nds32-randconfig-r016-20210705 (attached as .config)
compiler: nds32le-linux-gcc (GCC) 9.3.0
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
        # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=d19ad0775dcd64b49eecf4fa79c17959ebfbd26b
        git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
        git fetch --no-tags linus master
        git checkout d19ad0775dcd64b49eecf4fa79c17959ebfbd26b
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=nds32 

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

All warnings (new ones prefixed by >>):

   arch/nds32/kernel/ftrace.c: In function '_mcount':
   arch/nds32/kernel/ftrace.c:24:28: warning: comparison of distinct pointer types lacks a cast
      24 |  if (ftrace_trace_function != ftrace_stub)
         |                            ^~
>> arch/nds32/kernel/ftrace.c:29:29: warning: cast between incompatible function types from 'void (*)(long unsigned int,  long unsigned int,  struct ftrace_ops *, struct ftrace_regs *)' to 'void (*)(struct ftrace_graph_ret *)' [-Wcast-function-type]
      29 |  if (ftrace_graph_return != (trace_func_graph_ret_t)ftrace_stub
         |                             ^
   arch/nds32/kernel/ftrace.c: At top level:
   arch/nds32/kernel/ftrace.c:198:6: warning: no previous prototype for 'prepare_ftrace_return' [-Wmissing-prototypes]
     198 | void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr,
         |      ^~~~~~~~~~~~~~~~~~~~~
   arch/nds32/kernel/ftrace.c:275:15: warning: no previous prototype for '__trace_hardirqs_off' [-Wmissing-prototypes]
     275 | noinline void __trace_hardirqs_off(void)
         |               ^~~~~~~~~~~~~~~~~~~~
   arch/nds32/kernel/ftrace.c:279:15: warning: no previous prototype for '__trace_hardirqs_on' [-Wmissing-prototypes]
     279 | noinline void __trace_hardirqs_on(void)
         |               ^~~~~~~~~~~~~~~~~~~


vim +29 arch/nds32/kernel/ftrace.c

a18082575c6648 Zong Li 2018-08-15  17  
a18082575c6648 Zong Li 2018-08-15  18  noinline void _mcount(unsigned long parent_ip)
a18082575c6648 Zong Li 2018-08-15  19  {
a18082575c6648 Zong Li 2018-08-15  20  	/* save all state by the compiler prologue */
a18082575c6648 Zong Li 2018-08-15  21  
a18082575c6648 Zong Li 2018-08-15  22  	unsigned long ip = (unsigned long)__builtin_return_address(0);
a18082575c6648 Zong Li 2018-08-15  23  
a18082575c6648 Zong Li 2018-08-15  24  	if (ftrace_trace_function != ftrace_stub)
a18082575c6648 Zong Li 2018-08-15  25  		ftrace_trace_function(ip - MCOUNT_INSN_SIZE, parent_ip,
a18082575c6648 Zong Li 2018-08-15  26  				      NULL, NULL);
a18082575c6648 Zong Li 2018-08-15  27  
1e9b14c0d92b61 Zong Li 2018-08-15  28  #ifdef CONFIG_FUNCTION_GRAPH_TRACER
1e9b14c0d92b61 Zong Li 2018-08-15 @29  	if (ftrace_graph_return != (trace_func_graph_ret_t)ftrace_stub
1e9b14c0d92b61 Zong Li 2018-08-15  30  	    || ftrace_graph_entry != ftrace_graph_entry_stub)
1e9b14c0d92b61 Zong Li 2018-08-15  31  		ftrace_graph_caller();
1e9b14c0d92b61 Zong Li 2018-08-15  32  #endif
1e9b14c0d92b61 Zong Li 2018-08-15  33  
a18082575c6648 Zong Li 2018-08-15  34  	/* restore all state by the compiler epilogue */
a18082575c6648 Zong Li 2018-08-15  35  }
a18082575c6648 Zong Li 2018-08-15  36  EXPORT_SYMBOL(_mcount);
1e9b14c0d92b61 Zong Li 2018-08-15  37  

:::::: The code at line 29 was first introduced by commit
:::::: 1e9b14c0d92b61a0979fd5ee24d5e7f080f11030 nds32/ftrace: Support static function graph tracer

:::::: TO: Zong Li <zong@andestech.com>
:::::: CC: Greentime Hu <greentime@andestech.com>

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

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 35690 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* arch/nds32/kernel/ftrace.c:29:29: warning: cast between incompatible function types from 'void (*)(long unsigned int,  long unsigned int,  struct ftrace_ops *, struct ftrace_regs *)' to 'void (*)(struct ftrace_graph_ret *)'
@ 2021-08-13 10:35 ` kernel test robot
  0 siblings, 0 replies; 4+ messages in thread
From: kernel test robot @ 2021-08-13 10:35 UTC (permalink / raw)
  To: Steven Rostedt (VMware); +Cc: kbuild-all, linux-kernel, Masami Hiramatsu

[-- Attachment #1: Type: text/plain, Size: 3894 bytes --]

Hi Steven,

FYI, the error/warning still remains.

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   f8e6dfc64f6135d1b6c5215c14cd30b9b60a0008
commit: d19ad0775dcd64b49eecf4fa79c17959ebfbd26b ftrace: Have the callbacks receive a struct ftrace_regs instead of pt_regs
date:   9 months ago
config: nds32-randconfig-r001-20210813 (attached as .config)
compiler: nds32le-linux-gcc (GCC) 10.3.0
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
        # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=d19ad0775dcd64b49eecf4fa79c17959ebfbd26b
        git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
        git fetch --no-tags linus master
        git checkout d19ad0775dcd64b49eecf4fa79c17959ebfbd26b
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-10.3.0 make.cross ARCH=nds32 

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

All warnings (new ones prefixed by >>):

   arch/nds32/kernel/ftrace.c: In function '_mcount':
   arch/nds32/kernel/ftrace.c:24:28: warning: comparison of distinct pointer types lacks a cast
      24 |  if (ftrace_trace_function != ftrace_stub)
         |                            ^~
>> arch/nds32/kernel/ftrace.c:29:29: warning: cast between incompatible function types from 'void (*)(long unsigned int,  long unsigned int,  struct ftrace_ops *, struct ftrace_regs *)' to 'void (*)(struct ftrace_graph_ret *)' [-Wcast-function-type]
      29 |  if (ftrace_graph_return != (trace_func_graph_ret_t)ftrace_stub
         |                             ^
   arch/nds32/kernel/ftrace.c: At top level:
   arch/nds32/kernel/ftrace.c:198:6: warning: no previous prototype for 'prepare_ftrace_return' [-Wmissing-prototypes]
     198 | void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr,
         |      ^~~~~~~~~~~~~~~~~~~~~


vim +29 arch/nds32/kernel/ftrace.c

a18082575c6648 Zong Li 2018-08-15  17  
a18082575c6648 Zong Li 2018-08-15  18  noinline void _mcount(unsigned long parent_ip)
a18082575c6648 Zong Li 2018-08-15  19  {
a18082575c6648 Zong Li 2018-08-15  20  	/* save all state by the compiler prologue */
a18082575c6648 Zong Li 2018-08-15  21  
a18082575c6648 Zong Li 2018-08-15  22  	unsigned long ip = (unsigned long)__builtin_return_address(0);
a18082575c6648 Zong Li 2018-08-15  23  
a18082575c6648 Zong Li 2018-08-15 @24  	if (ftrace_trace_function != ftrace_stub)
a18082575c6648 Zong Li 2018-08-15  25  		ftrace_trace_function(ip - MCOUNT_INSN_SIZE, parent_ip,
a18082575c6648 Zong Li 2018-08-15  26  				      NULL, NULL);
a18082575c6648 Zong Li 2018-08-15  27  
1e9b14c0d92b61 Zong Li 2018-08-15  28  #ifdef CONFIG_FUNCTION_GRAPH_TRACER
1e9b14c0d92b61 Zong Li 2018-08-15 @29  	if (ftrace_graph_return != (trace_func_graph_ret_t)ftrace_stub
1e9b14c0d92b61 Zong Li 2018-08-15  30  	    || ftrace_graph_entry != ftrace_graph_entry_stub)
1e9b14c0d92b61 Zong Li 2018-08-15  31  		ftrace_graph_caller();
1e9b14c0d92b61 Zong Li 2018-08-15  32  #endif
1e9b14c0d92b61 Zong Li 2018-08-15  33  
a18082575c6648 Zong Li 2018-08-15  34  	/* restore all state by the compiler epilogue */
a18082575c6648 Zong Li 2018-08-15  35  }
a18082575c6648 Zong Li 2018-08-15  36  EXPORT_SYMBOL(_mcount);
1e9b14c0d92b61 Zong Li 2018-08-15  37  

:::::: The code at line 29 was first introduced by commit
:::::: 1e9b14c0d92b61a0979fd5ee24d5e7f080f11030 nds32/ftrace: Support static function graph tracer

:::::: TO: Zong Li <zong@andestech.com>
:::::: CC: Greentime Hu <greentime@andestech.com>

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

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 32835 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* arch/nds32/kernel/ftrace.c:29:29: warning: cast between incompatible function types from 'void (*)(long unsigned int, long unsigned int, struct ftrace_ops *, struct ftrace_regs *)' to 'void (*)(struct ftrace_graph_ret *)'
@ 2021-08-13 10:35 ` kernel test robot
  0 siblings, 0 replies; 4+ messages in thread
From: kernel test robot @ 2021-08-13 10:35 UTC (permalink / raw)
  To: kbuild-all

[-- Attachment #1: Type: text/plain, Size: 3967 bytes --]

Hi Steven,

FYI, the error/warning still remains.

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   f8e6dfc64f6135d1b6c5215c14cd30b9b60a0008
commit: d19ad0775dcd64b49eecf4fa79c17959ebfbd26b ftrace: Have the callbacks receive a struct ftrace_regs instead of pt_regs
date:   9 months ago
config: nds32-randconfig-r001-20210813 (attached as .config)
compiler: nds32le-linux-gcc (GCC) 10.3.0
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
        # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=d19ad0775dcd64b49eecf4fa79c17959ebfbd26b
        git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
        git fetch --no-tags linus master
        git checkout d19ad0775dcd64b49eecf4fa79c17959ebfbd26b
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-10.3.0 make.cross ARCH=nds32 

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

All warnings (new ones prefixed by >>):

   arch/nds32/kernel/ftrace.c: In function '_mcount':
   arch/nds32/kernel/ftrace.c:24:28: warning: comparison of distinct pointer types lacks a cast
      24 |  if (ftrace_trace_function != ftrace_stub)
         |                            ^~
>> arch/nds32/kernel/ftrace.c:29:29: warning: cast between incompatible function types from 'void (*)(long unsigned int,  long unsigned int,  struct ftrace_ops *, struct ftrace_regs *)' to 'void (*)(struct ftrace_graph_ret *)' [-Wcast-function-type]
      29 |  if (ftrace_graph_return != (trace_func_graph_ret_t)ftrace_stub
         |                             ^
   arch/nds32/kernel/ftrace.c: At top level:
   arch/nds32/kernel/ftrace.c:198:6: warning: no previous prototype for 'prepare_ftrace_return' [-Wmissing-prototypes]
     198 | void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr,
         |      ^~~~~~~~~~~~~~~~~~~~~


vim +29 arch/nds32/kernel/ftrace.c

a18082575c6648 Zong Li 2018-08-15  17  
a18082575c6648 Zong Li 2018-08-15  18  noinline void _mcount(unsigned long parent_ip)
a18082575c6648 Zong Li 2018-08-15  19  {
a18082575c6648 Zong Li 2018-08-15  20  	/* save all state by the compiler prologue */
a18082575c6648 Zong Li 2018-08-15  21  
a18082575c6648 Zong Li 2018-08-15  22  	unsigned long ip = (unsigned long)__builtin_return_address(0);
a18082575c6648 Zong Li 2018-08-15  23  
a18082575c6648 Zong Li 2018-08-15 @24  	if (ftrace_trace_function != ftrace_stub)
a18082575c6648 Zong Li 2018-08-15  25  		ftrace_trace_function(ip - MCOUNT_INSN_SIZE, parent_ip,
a18082575c6648 Zong Li 2018-08-15  26  				      NULL, NULL);
a18082575c6648 Zong Li 2018-08-15  27  
1e9b14c0d92b61 Zong Li 2018-08-15  28  #ifdef CONFIG_FUNCTION_GRAPH_TRACER
1e9b14c0d92b61 Zong Li 2018-08-15 @29  	if (ftrace_graph_return != (trace_func_graph_ret_t)ftrace_stub
1e9b14c0d92b61 Zong Li 2018-08-15  30  	    || ftrace_graph_entry != ftrace_graph_entry_stub)
1e9b14c0d92b61 Zong Li 2018-08-15  31  		ftrace_graph_caller();
1e9b14c0d92b61 Zong Li 2018-08-15  32  #endif
1e9b14c0d92b61 Zong Li 2018-08-15  33  
a18082575c6648 Zong Li 2018-08-15  34  	/* restore all state by the compiler epilogue */
a18082575c6648 Zong Li 2018-08-15  35  }
a18082575c6648 Zong Li 2018-08-15  36  EXPORT_SYMBOL(_mcount);
1e9b14c0d92b61 Zong Li 2018-08-15  37  

:::::: The code at line 29 was first introduced by commit
:::::: 1e9b14c0d92b61a0979fd5ee24d5e7f080f11030 nds32/ftrace: Support static function graph tracer

:::::: TO: Zong Li <zong@andestech.com>
:::::: CC: Greentime Hu <greentime@andestech.com>

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

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 32835 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-08-13 10:36 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-05  7:13 arch/nds32/kernel/ftrace.c:29:29: warning: cast between incompatible function types from 'void (*)(long unsigned int, long unsigned int, struct ftrace_ops *, struct ftrace_regs *)' to 'void (*)(struct ftrace_graph_ret *)' kernel test robot
2021-07-05  7:13 ` kernel test robot
2021-08-13 10:35 kernel test robot
2021-08-13 10:35 ` kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.