linux-next: build warning after merge of the chrome-platform tree
Hi all,
After merging the chrome-platform tree, today's linux-next build (arm multi_v7_defconfig) produced this warning:
In file included from include/trace/define_trace.h:102,
from drivers/platform/chrome/cros_ec_trace.h:178,
from drivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h: In function 'trace_raw_output_cros_ec_sensorhub_timestamp':drivers/platform/chrome/./cros_ec_trace.h:95:12: warning: format '%lld' expects argument of type 'long long int', but argument 3 has type 'u32' {aka 'unsigned int'} [-Wformat=]
95 | TP_printk("ec_ts: %12lld, ec_fifo_ts: %12lld, fifo_ts: %12lld, curr_ts: %12lld, curr_time: %12lld, delta %12lld",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/trace/trace_events.h:399:27: note: in definition of macro 'DECLARE_EVENT_CLASS'
399 | trace_event_printf(iter, print); \
| ^~~~~include/trace/trace_events.h:80:9: note: in expansion of macro 'PARAMS'
80 | PARAMS(print)); \
| ^~~~~~
drivers/platform/chrome/./cros_ec_trace.h:74:1: note: in expansion of macro 'TRACE_EVENT'
74 | TRACE_EVENT(cros_ec_sensorhub_timestamp,
| ^~~~~~~~~~~
drivers/platform/chrome/./cros_ec_trace.h:95:2: note: in expansion of macro 'TP_printk'
95 | TP_printk("ec_ts: %12lld, ec_fifo_ts: %12lld, fifo_ts: %12lld, curr_ts: %12lld, curr_time: %12lld, delta %12lld",
| ^~~~~~~~~In file included from include/trace/trace_events.h:433,
from include/trace/define_trace.h:102,
from drivers/platform/chrome/cros_ec_trace.h:178, from drivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h:95:25: note: format string is defined here
95 | TP_printk("ec_ts: %12lld, ec_fifo_ts: %12lld, fifo_ts: %12lld, curr_ts: %12lld, curr_time: %12lld, delta %12lld",
| ~~~~~^
| |
| long long int
| %12dIn file included from include/trace/define_trace.h:102,
from drivers/platform/chrome/cros_ec_trace.h:178,
from drivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h:95:12: warning: format '%lld' expects argument of type 'long long int', but argument 4 has type 'u32' {aka 'unsigned int'} [-Wformat=]
95 | TP_printk("ec_ts: %12lld, ec_fifo_ts: %12lld, fifo_ts: %12lld, curr_ts: %12lld, curr_time: %12lld, delta %12lld",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/trace/trace_events.h:399:27: note: in definition of macro 'DECLARE_EVENT_CLASS'
399 | trace_event_printf(iter, print); \
| ^~~~~include/trace/trace_events.h:80:9: note: in expansion of macro 'PARAMS'
80 | PARAMS(print)); \
| ^~~~~~
drivers/platform/chrome/./cros_ec_trace.h:74:1: note: in expansion of macro 'TRACE_EVENT'
74 | TRACE_EVENT(cros_ec_sensorhub_timestamp,
| ^~~~~~~~~~~
drivers/platform/chrome/./cros_ec_trace.h:95:2: note: in expansion of macro 'TP_printk'
95 | TP_printk("ec_ts: %12lld, ec_fifo_ts: %12lld, fifo_ts: %12lld, curr_ts: %12lld, curr_time: %12lld, delta %12lld",
| ^~~~~~~~~In file included from include/trace/trace_events.h:433,
from include/trace/define_trace.h:102,
from drivers/platform/chrome/cros_ec_trace.h:178, from drivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h:95:45: note: format string is defined here
95 | TP_printk("ec_ts: %12lld, ec_fifo_ts: %12lld, fifo_ts: %12lld, curr_ts: %12lld, curr_time: %12lld, delta %12lld",
| ~~~~~^
| |
| long long int
| %12dIn file included from include/trace/define_trace.h:102,
from drivers/platform/chrome/cros_ec_trace.h:178,
from drivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h: In function 'trace_raw_output_cros_ec_sensorhub_data':drivers/platform/chrome/./cros_ec_trace.h:125:12: warning: format '%lld' expects argument of type 'long long int', but argument 4 has type 'u32' {aka 'unsigned int'} [-Wformat=]
125 | TP_printk("ec_num: %4d, ec_fifo_ts: %12lld, fifo_ts: %12lld, curr_ts: %12lld, curr_time: %12lld, delta %12lld",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/trace/trace_events.h:399:27: note: in definition of macro 'DECLARE_EVENT_CLASS'
399 | trace_event_printf(iter, print); \
| ^~~~~include/trace/trace_events.h:80:9: note: in expansion of macro 'PARAMS'
80 | PARAMS(print)); \
| ^~~~~~
drivers/platform/chrome/./cros_ec_trace.h:105:1: note: in expansion of macro 'TRACE_EVENT'
105 | TRACE_EVENT(cros_ec_sensorhub_data,
| ^~~~~~~~~~~
drivers/platform/chrome/./cros_ec_trace.h:125:2: note: in expansion of macro 'TP_printk'
125 | TP_printk("ec_num: %4d, ec_fifo_ts: %12lld, fifo_ts: %12lld, curr_ts: %12lld, curr_time: %12lld, delta %12lld",
| ^~~~~~~~~In file included from include/trace/trace_events.h:433,
from include/trace/define_trace.h:102,
from drivers/platform/chrome/cros_ec_trace.h:178,
from drivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h:125:43: note: format string is defined here
125 | TP_printk("ec_num: %4d, ec_fifo_ts: %12lld, fifo_ts: %12lld, curr_ts: %12lld, curr_time: %12lld, delta %12lld",
| ~~~~~^
| |
| long long int
| %12dIn file included from include/trace/define_trace.h:102,
from drivers/platform/chrome/cros_ec_trace.h:178,
from drivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h: In function 'trace_raw_output_cros_ec_sensorhub_filter':drivers/platform/chrome/./cros_ec_trace.h:156:12: warning: format '%d' expects argument of type 'int', but argument 7 has type 's64' {aka 'long long int'} [-Wformat=]
156 | TP_printk("dx: %12lld. dy: %12lld median_m: %12lld median_error: %12lld len: %d x: %12lld y: %12lld",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/trace/trace_events.h:399:27: note: in definition of macro 'DECLARE_EVENT_CLASS'
399 | trace_event_printf(iter, print); \
| ^~~~~include/trace/trace_events.h:80:9: note: in expansion of macro 'PARAMS'
80 | PARAMS(print)); \
| ^~~~~~
drivers/platform/chrome/./cros_ec_trace.h:135:1: note: in expansion of macro 'TRACE_EVENT'
135 | TRACE_EVENT(cros_ec_sensorhub_filter,
| ^~~~~~~~~~~
drivers/platform/chrome/./cros_ec_trace.h:156:2: note: in expansion of macro 'TP_printk'
156 | TP_printk("dx: %12lld. dy: %12lld median_m: %12lld median_error: %12lld len: %d x: %12lld y: %12lld",
| ^~~~~~~~~In file included from include/trace/trace_events.h:433,
from include/trace/define_trace.h:102,
from drivers/platform/chrome/cros_ec_trace.h:178,
from drivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h:156:80: note: format string is defined here
156 | TP_printk("dx: %12lld. dy: %12lld median_m: %12lld median_error: %12lld len: %d x: %12lld y: %12lld",
| ~^
| |
| int
| %lldIntroduced by commit
d453ceb6549a ("platform/chrome: sensorhub: Add trace events for sample")
Signature · 2 lines
Cheers, Stephen Rothwell
Hi all,
Quoted 120 lines · On Mon, 23 Aug 2021 15:21:34 +1000 Stephen Rothwell <[email protected]>…
After merging the chrome-platform tree, today's linux-next build (arm
multi_v7_defconfig) produced this warning:In file included from
include/trace/define_trace.h:102,
fromdrivers/platform/chrome/cros_ec_trace.h:178,
fromdrivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h: In function 'trace_raw_output_cros_ec_sensorhub_timestamp':drivers/platform/chrome/./cros_ec_trace.h:95:12: warning: format '%lld' expects argument of type 'long long int', but argument 3 has type 'u32' {aka 'unsigned int'} [-Wformat=]
95 | TP_printk("ec_ts: %12lld,ec_fifo_ts: %12lld,fifo_ts: %12lld,curr_ts: %12lld,curr_time: %12lld, delta %12lld",| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/trace/trace_events.h:399:27: note: in definition of macro 'DECLARE_EVENT_CLASS'
399 |trace_event_printf(iter, print); \
| ^~~~~include/trace/trace_events.h:80:9: note: in expansion of macro 'PARAMS'80 | PARAMS(print)); \ | ^~~~~~ drivers/platform/chrome/./cros_ec_trace.h:74:1: note: in expansion of macro 'TRACE_EVENT' 74 | TRACE_EVENT(cros_ec_sensorhub_timestamp, | ^~~~~~~~~~~ drivers/platform/chrome/./cros_ec_trace.h:95:2: note: in expansion of macro 'TP_printk' 95 | TP_printk("ec_ts: %12lld, ec_fifo_ts: %12lld, fifo_ts: %12lld, curr_ts: %12lld, curr_time: %12lld, delta %12lld", | ^~~~~~~~~In file included from
include/trace/trace_events.h:433,
frominclude/trace/define_trace.h:102,
fromdrivers/platform/chrome/cros_ec_trace.h:178, fromdrivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h:95:25: note: format string is defined here95 | TP_printk("ec_ts: %12lld, ec_fifo_ts: %12lld, fifo_ts: %12lld, curr_ts: %12lld, curr_time: %12lld, delta %12lld", | ~~~~~^ | | | long long int | %12dIn file included from
include/trace/define_trace.h:102,
fromdrivers/platform/chrome/cros_ec_trace.h:178,
fromdrivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h:95:12: warning: format '%lld' expects argument of type 'long long int', but argument 4 has type 'u32' {aka 'unsigned int'} [-Wformat=]
95 | TP_printk("ec_ts: %12lld,ec_fifo_ts: %12lld,fifo_ts: %12lld,curr_ts: %12lld,curr_time: %12lld, delta %12lld",| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/trace/trace_events.h:399:27: note: in definition of macro 'DECLARE_EVENT_CLASS'
399 |trace_event_printf(iter, print); \
| ^~~~~include/trace/trace_events.h:80:9: note: in expansion of macro 'PARAMS'80 | PARAMS(print)); \ | ^~~~~~ drivers/platform/chrome/./cros_ec_trace.h:74:1: note: in expansion of macro 'TRACE_EVENT' 74 | TRACE_EVENT(cros_ec_sensorhub_timestamp, | ^~~~~~~~~~~ drivers/platform/chrome/./cros_ec_trace.h:95:2: note: in expansion of macro 'TP_printk' 95 | TP_printk("ec_ts: %12lld, ec_fifo_ts: %12lld, fifo_ts: %12lld, curr_ts: %12lld, curr_time: %12lld, delta %12lld", | ^~~~~~~~~In file included from
include/trace/trace_events.h:433,
frominclude/trace/define_trace.h:102,
fromdrivers/platform/chrome/cros_ec_trace.h:178, fromdrivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h:95:45: note: format string is defined here95 | TP_printk("ec_ts: %12lld, ec_fifo_ts: %12lld, fifo_ts: %12lld, curr_ts: %12lld, curr_time: %12lld, delta %12lld", | ~~~~~^ | | | long long int | %12dIn file included from
include/trace/define_trace.h:102,
fromdrivers/platform/chrome/cros_ec_trace.h:178,
fromdrivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h: In function 'trace_raw_output_cros_ec_sensorhub_data':drivers/platform/chrome/./cros_ec_trace.h:125:12: warning: format '%lld' expects argument of type 'long long int', but argument 4 has type 'u32' {aka 'unsigned int'} [-Wformat=]
125 | TP_printk("ec_num: %4d,ec_fifo_ts: %12lld,fifo_ts: %12lld,curr_ts: %12lld,curr_time: %12lld, delta %12lld",| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/trace/trace_events.h:399:27: note: in definition of macro 'DECLARE_EVENT_CLASS'
399 |trace_event_printf(iter, print); \
| ^~~~~include/trace/trace_events.h:80:9: note: in expansion of macro 'PARAMS'80 | PARAMS(print)); \ | ^~~~~~ drivers/platform/chrome/./cros_ec_trace.h:105:1: note: in expansion of macro 'TRACE_EVENT' 105 | TRACE_EVENT(cros_ec_sensorhub_data, | ^~~~~~~~~~~ drivers/platform/chrome/./cros_ec_trace.h:125:2: note: in expansion of macro 'TP_printk' 125 | TP_printk("ec_num: %4d, ec_fifo_ts: %12lld, fifo_ts: %12lld, curr_ts: %12lld, curr_time: %12lld, delta %12lld", | ^~~~~~~~~In file included from
include/trace/trace_events.h:433,
frominclude/trace/define_trace.h:102,
fromdrivers/platform/chrome/cros_ec_trace.h:178,
fromdrivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h:125:43: note: format string is defined here125 | TP_printk("ec_num: %4d, ec_fifo_ts: %12lld, fifo_ts: %12lld, curr_ts: %12lld, curr_time: %12lld, delta %12lld", | ~~~~~^ | | | long long int | %12dIn file included from
include/trace/define_trace.h:102,
fromdrivers/platform/chrome/cros_ec_trace.h:178,
fromdrivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h: In function 'trace_raw_output_cros_ec_sensorhub_filter':drivers/platform/chrome/./cros_ec_trace.h:156:12: warning: format '%d' expects argument of type 'int', but argument 7 has type 's64' {aka 'long long int'} [-Wformat=]
156 | TP_printk("dx: %12lld. dy: %12lldmedian_m: %12lldmedian_error: %12lld len: %d x: %12lld y: %12lld",| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/trace/trace_events.h:399:27: note: in definition of macro 'DECLARE_EVENT_CLASS'
399 |trace_event_printf(iter, print); \
| ^~~~~include/trace/trace_events.h:80:9: note: in expansion of macro 'PARAMS'80 | PARAMS(print)); \ | ^~~~~~ drivers/platform/chrome/./cros_ec_trace.h:135:1: note: in expansion of macro 'TRACE_EVENT' 135 | TRACE_EVENT(cros_ec_sensorhub_filter, | ^~~~~~~~~~~ drivers/platform/chrome/./cros_ec_trace.h:156:2: note: in expansion of macro 'TP_printk' 156 | TP_printk("dx: %12lld. dy: %12lld median_m: %12lld median_error: %12lld len: %d x: %12lld y: %12lld", | ^~~~~~~~~In file included from
include/trace/trace_events.h:433,
frominclude/trace/define_trace.h:102,
fromdrivers/platform/chrome/cros_ec_trace.h:178,
fromdrivers/platform/chrome/cros_ec_trace.c:215:drivers/platform/chrome/./cros_ec_trace.h:156:80: note: format string is defined here156 | TP_printk("dx: %12lld. dy: %12lld median_m: %12lld median_error: %12lld len: %d x: %12lld y: %12lld", | ~^ | | | int | %lld
Quoted 3 lines
Introduced by commit
d453ceb6549a("platform/chrome: sensorhub: Add trace events for sample")
I am still seeing these warnings.
Signature · 2 lines
Cheers, Stephen Rothwell
Hi Stephen,
Quoted 8 lines · Stephen Rothwell
Quoted 3 lines
Introduced by commit
d453ceb6549a("platform/chrome: sensorhub: Add trace events for sample")I am still seeing these warnings.
Signature · 2 lines
Cheers, Stephen Rothwell
I've just pushed this to chrome-platform's for-next:
5a51bdb0ae26 ("platform/chrome: cros_ec_trace: Fix format warnings")
This should fix those warnings. Sorry for the long delay.
Signature · 7 lines
Benson Leung Staff Software Engineer Chrome OS Kernel Google Inc. [email protected] Chromium OS Project [email protected]
Hi Benson,
Quoted 11 lines · On Mon, 30 Aug 2021 17:17:45 -0700 Benson Leung <[email protected]> wrote:
Quoted 8 lines · Stephen Rothwell
Quoted 3 lines
Introduced by commit
d453ceb6549a("platform/chrome: sensorhub: Add trace events for sample")I am still seeing these warnings.
Signature · 2 lines
Cheers, Stephen Rothwell
Quoted 4 lines
I've just pushed this to chrome-platform's for-next:
5a51bdb0ae26("platform/chrome:cros_ec_trace: Fix format warnings")This should fix those warnings. Sorry for the long delay.
Thanks.
Signature · 2 lines
Cheers, Stephen Rothwell