Re: [PATCH v2] tracing: Make is_signed_type() compatible with sparse
From: Bart Van Assche
Date: Wed Sep 02 2026 - 12:43:32 EST
On 9/2/26 6:36 AM, Steven Rostedt wrote:
On Wed, 2 Sep 2026 09:24:37 +0100
David Laight <david.laight.linux@xxxxxxxxx> wrote:
Yeah, it was originally used for the tracing format files so that
tooling can know how to display the raw values it parses. Also it is
used for the filtering logic to know how to compare to the raw values.
And, in this case, the value is __bitwise so the 'tooling' doesn't know
how to display/compare them and you get a compile error.
Doesn't seem wrong :-)
Where is __bitwise used for a trace event field? Or is this an issue for
one of the other users of is_signed_type()?
An example is any code that traces blk_opf_t or enum req_op values (there are probably more examples):
$ git grep -nHE '__field.*(blk_opf_t|enum req_op)' include/trace
include/trace/events/f2fs.h:1185: __field(enum req_op, op)
include/trace/events/f2fs.h:1186: __field(blk_opf_t, op_flags)
include/trace/events/f2fs.h:1241: __field(enum req_op, op)
include/trace/events/f2fs.h:1242: __field(blk_opf_t, op_flags)
include/trace/events/jbd2.h:364: __field( blk_opf_t, write_flags )
include/trace/events/nilfs2.h:207: __field_struct(enum req_op, mode)
Thanks,
Bart.