linux-yocto/include/trace/stages
Steven Rostedt e13358c488 tracing: Add __print_dynamic_array() helper
[ Upstream commit e52750fb14 ]

When printing a dynamic array in a trace event, the method is rather ugly.
It has the format of:

  __print_array(__get_dynamic_array(array),
            __get_dynmaic_array_len(array) / el_size, el_size)

Since dynamic arrays are known to the tracing infrastructure, create a
helper macro that does the above for you.

  __print_dynamic_array(array, el_size)

Which would expand to the same output.

Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
Signed-off-by: Avadhut Naik <avadhut.naik@amd.com>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Reviewed-by: Qiuxu Zhuo <qiuxu.zhuo@intel.com>
Link: https://lore.kernel.org/r/20241022194158.110073-3-avadhut.naik@amd.com
Stable-dep-of: ea8d7647f9 ("tracing: Verify event formats that have "%*p.."")
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-05-02 07:50:37 +02:00
..
init.h
stage1_struct_define.h tracing: Add __cpumask to denote a trace event field that is a cpumask_t 2022-11-23 19:08:30 -05:00
stage2_data_offsets.h tracing: Add __cpumask to denote a trace event field that is a cpumask_t 2022-11-23 19:08:30 -05:00
stage3_trace_output.h tracing: Add __print_dynamic_array() helper 2025-05-02 07:50:37 +02:00
stage4_event_fields.h tracing: Fix TASK_COMM_LEN in trace event format file 2023-02-12 10:23:39 -05:00
stage5_get_offsets.h tracing: Error if a trace event has an array for a __field() 2023-04-03 11:52:51 -04:00
stage6_event_callback.h perf/tracing: Use stage6 of tracing to not duplicate macros 2023-01-25 10:31:24 -05:00
stage7_class_define.h tracing: Add __print_dynamic_array() helper 2025-05-02 07:50:37 +02:00