Re: [PATCH bpf-next v3 1/6] xsk: add tracepoints for packet drops
From: kernel test robot <hidden>
Date: 2021-02-02 20:05:48
Also in:
netdev, oe-kbuild-all
Hi Ciara, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on bpf-next/master] url: https://github.com/0day-ci/linux/commits/Ciara-Loftus/AF_XDP-Packet-Drop-Tracing/20210203-020056 base: https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git master config: x86_64-randconfig-s022-20210202 (attached as .config) compiler: gcc-9 (Debian 9.3.0-15) 9.3.0 reproduce: # apt-get install sparse # sparse version: v0.6.3-215-g0fb77bb6-dirty # https://github.com/0day-ci/linux/commit/8566dfd5799adb0033d56bc33146947b9469c362 git remote add linux-review https://github.com/0day-ci/linux git fetch --no-tags linux-review Ciara-Loftus/AF_XDP-Packet-Drop-Tracing/20210203-020056 git checkout 8566dfd5799adb0033d56bc33146947b9469c362 # save the attached .config to linux build tree make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=x86_64 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <redacted> All warnings (new ones prefixed by >>): kernel/bpf/core.c:1350:12: warning: no previous prototype for 'bpf_probe_read_kernel' [-Wmissing-prototypes] 1350 | u64 __weak bpf_probe_read_kernel(void *dst, u32 size, const void *unsafe_ptr) | ^~~~~~~~~~~~~~~~~~~~~ In file included from include/trace/define_trace.h:102, from include/trace/events/xsk.h:73, from include/linux/bpf_trace.h:6, from kernel/bpf/core.c:2361: include/trace/events/xsk.h: In function 'trace_raw_output_xsk_packet_drop':
quoted
include/trace/events/xsk.h:63:12: warning: format '%lu' expects argument of type 'long unsigned int', but argument 7 has type 'u64' {aka 'long long unsigned int'} [-Wformat=]
63 | TP_printk("netdev: %s qid %u reason: %s: %s %lu %s %lu %s %lu",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/trace/trace_events.h:367:22: note: in definition of macro 'DECLARE_EVENT_CLASS'
367 | trace_seq_printf(s, print); \
| ^~~~~
include/trace/trace_events.h:80:9: note: in expansion of macro 'PARAMS'
80 | PARAMS(print)); \
| ^~~~~~
include/trace/events/xsk.h:39:1: note: in expansion of macro 'TRACE_EVENT'
39 | TRACE_EVENT(xsk_packet_drop,
| ^~~~~~~~~~~
include/trace/events/xsk.h:63:2: note: in expansion of macro 'TP_printk'
63 | TP_printk("netdev: %s qid %u reason: %s: %s %lu %s %lu %s %lu",
| ^~~~~~~~~
In file included from include/trace/trace_events.h:401,
from include/trace/define_trace.h:102,
from include/trace/events/xsk.h:73,
from include/linux/bpf_trace.h:6,
from kernel/bpf/core.c:2361:
include/trace/events/xsk.h:63:48: note: format string is defined here
63 | TP_printk("netdev: %s qid %u reason: %s: %s %lu %s %lu %s %lu",
| ~~^
| |
| long unsigned int
| %llu
In file included from include/trace/define_trace.h:102,
from include/trace/events/xsk.h:73,
from include/linux/bpf_trace.h:6,
from kernel/bpf/core.c:2361:
include/trace/events/xsk.h:63:12: warning: format '%lu' expects argument of type 'long unsigned int', but argument 9 has type 'u64' {aka 'long long unsigned int'} [-Wformat=]
63 | TP_printk("netdev: %s qid %u reason: %s: %s %lu %s %lu %s %lu",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/trace/trace_events.h:367:22: note: in definition of macro 'DECLARE_EVENT_CLASS'
367 | trace_seq_printf(s, print); \
| ^~~~~
include/trace/trace_events.h:80:9: note: in expansion of macro 'PARAMS'
80 | PARAMS(print)); \
| ^~~~~~
include/trace/events/xsk.h:39:1: note: in expansion of macro 'TRACE_EVENT'
39 | TRACE_EVENT(xsk_packet_drop,
| ^~~~~~~~~~~
include/trace/events/xsk.h:63:2: note: in expansion of macro 'TP_printk'
63 | TP_printk("netdev: %s qid %u reason: %s: %s %lu %s %lu %s %lu",
| ^~~~~~~~~
In file included from include/trace/trace_events.h:401,
from include/trace/define_trace.h:102,
from include/trace/events/xsk.h:73,
from include/linux/bpf_trace.h:6,
from kernel/bpf/core.c:2361:
include/trace/events/xsk.h:63:55: note: format string is defined here
63 | TP_printk("netdev: %s qid %u reason: %s: %s %lu %s %lu %s %lu",
| ~~^
| |
| long unsigned int
| %llu
In file included from include/trace/define_trace.h:102,
from include/trace/events/xsk.h:73,
from include/linux/bpf_trace.h:6,
from kernel/bpf/core.c:2361:
include/trace/events/xsk.h:63:12: warning: format '%lu' expects argument of type 'long unsigned int', but argument 11 has type 'u64' {aka 'long long unsigned int'} [-Wformat=]
63 | TP_printk("netdev: %s qid %u reason: %s: %s %lu %s %lu %s %lu",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/trace/trace_events.h:367:22: note: in definition of macro 'DECLARE_EVENT_CLASS'
367 | trace_seq_printf(s, print); \
| ^~~~~
include/trace/trace_events.h:80:9: note: in expansion of macro 'PARAMS'
80 | PARAMS(print)); \
| ^~~~~~
include/trace/events/xsk.h:39:1: note: in expansion of macro 'TRACE_EVENT'
39 | TRACE_EVENT(xsk_packet_drop,
| ^~~~~~~~~~~
include/trace/events/xsk.h:63:2: note: in expansion of macro 'TP_printk'
63 | TP_printk("netdev: %s qid %u reason: %s: %s %lu %s %lu %s %lu",
| ^~~~~~~~~
In file included from include/trace/trace_events.h:401,
from include/trace/define_trace.h:102,
from include/trace/events/xsk.h:73,
from include/linux/bpf_trace.h:6,
from kernel/bpf/core.c:2361:
include/trace/events/xsk.h:63:62: note: format string is defined here
63 | TP_printk("netdev: %s qid %u reason: %s: %s %lu %s %lu %s %lu",
| ~~^
| |
| long unsigned int
| %llu
vim +63 include/trace/events/xsk.h
40
41 TP_PROTO(char *name, u16 queue_id, u32 reason, u64 val1, u64 val2, u64 val3),
42
43 TP_ARGS(name, queue_id, reason, val1, val2, val3),
44
45 TP_STRUCT__entry(
46 __field(char *, name)
47 __field(u16, queue_id)
48 __field(u32, reason)
49 __field(u64, val1)
50 __field(u64, val2)
51 __field(u64, val3)
52 ),
53
54 TP_fast_assign(
55 __entry->name = name;
56 __entry->queue_id = queue_id;
57 __entry->reason = reason;
58 __entry->val1 = val1;
59 __entry->val2 = val2;
60 __entry->val3 = val3;
61 ),
62
> 63 TP_printk("netdev: %s qid %u reason: %s: %s %lu %s %lu %s %lu",
64 __entry->name, __entry->queue_id, print_reason(__entry->reason),
65 print_val1(__entry->reason), __entry->val1,
66 print_val2(__entry->reason), __entry->val2,
67 print_val3(__entry->reason), __entry->val3
68 )
69 );
70
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org Attachments
- .config.gz [application/gzip] 27384 bytes