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: <202005210635.XWCHvH78%lkp@intel.com>
Date:   Thu, 21 May 2020 06:30:43 +0800
From:   kbuild test robot <lkp@...el.com>
To:     Rajan Shanmugavelu <rajan.shanmugavelu@...cle.com>
Cc:     kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org,
        "Martin K. Petersen" <martin.petersen@...cle.com>,
        Joe Jin <joe.jin@...cle.com>
Subject: include/linux/compiler.h:61:16: warning: function
 'trace_event_raw_event_qla_log_event' might be a candidate for 'gnu_printf'
 format attribute

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   115a54162a6c0d0ef2aef25ebd0b61fc5e179ebe
commit: 598a90f2002c4c4daee24d76d24e8270c7075eef scsi: qla2xxx: add ring buffer for tracing debug logs
date:   2 months ago
config: arc-randconfig-r032-20200520 (attached as .config)
compiler: arc-elf-gcc (GCC) 9.3.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout 598a90f2002c4c4daee24d76d24e8270c7075eef
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arc 

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

All warnings (new ones prefixed by >>, old ones prefixed by <<):

In file included from include/linux/kernel.h:11,
from drivers/scsi/qla2xxx/qla_def.h:10,
from drivers/scsi/qla2xxx/qla_dbg.c:73:
include/trace/events/qla.h: In function 'trace_event_raw_event_qla_log_event':
>> include/linux/compiler.h:61:16: warning: function 'trace_event_raw_event_qla_log_event' might be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format]
61 |  static struct ftrace_branch_data           |                ^~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:69: note: in expansion of macro '__trace_if_value'
58 | #define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
|                                                                     ^~~~~~~~~~~~~~~~
include/linux/compiler.h:56:28: note: in expansion of macro '__trace_if_var'
56 | #define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
|                            ^~~~~~~~~~~~~~
include/trace/trace_events.h:702:2: note: in expansion of macro 'if'
702 |  if (!entry)                |  ^~
include/trace/events/qla.h:12:1: note: in expansion of macro 'DECLARE_EVENT_CLASS'
12 | DECLARE_EVENT_CLASS(qla_log_event,
| ^~~~~~~~~~~~~~~~~~~

vim +61 include/linux/compiler.h

a15fd609ad53a6 Linus Torvalds   2019-03-20  59  
a15fd609ad53a6 Linus Torvalds   2019-03-20  60  #define __trace_if_value(cond) ({			\
2bcd521a684cc9 Steven Rostedt   2008-11-21 @61  	static struct ftrace_branch_data		\
e04462fb82f8dd Miguel Ojeda     2018-09-03  62  		__aligned(4)				\
bfafddd8de426d Nick Desaulniers 2019-08-28  63  		__section(_ftrace_branch)		\
a15fd609ad53a6 Linus Torvalds   2019-03-20  64  		__if_trace = {				\
2bcd521a684cc9 Steven Rostedt   2008-11-21  65  			.func = __func__,		\
2bcd521a684cc9 Steven Rostedt   2008-11-21  66  			.file = __FILE__,		\
2bcd521a684cc9 Steven Rostedt   2008-11-21  67  			.line = __LINE__,		\
2bcd521a684cc9 Steven Rostedt   2008-11-21  68  		};					\
a15fd609ad53a6 Linus Torvalds   2019-03-20  69  	(cond) ?					\
a15fd609ad53a6 Linus Torvalds   2019-03-20  70  		(__if_trace.miss_hit[1]++,1) :		\
a15fd609ad53a6 Linus Torvalds   2019-03-20  71  		(__if_trace.miss_hit[0]++,0);		\
a15fd609ad53a6 Linus Torvalds   2019-03-20  72  })
a15fd609ad53a6 Linus Torvalds   2019-03-20  73  

:::::: The code at line 61 was first introduced by commit
:::::: 2bcd521a684cc94befbe2ce7d5b613c841b0d304 trace: profile all if conditionals

:::::: TO: Steven Rostedt <srostedt@...hat.com>
:::::: CC: Ingo Molnar <mingo@...e.hu>

---
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" (33716 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ