Commit d6a7bbdd authored by Kassey Li's avatar Kassey Li Committed by Tejun Heo

workqueue: add function in event of workqueue_activate_work

The trace event "workqueue_activate_work" only print work struct.
However, function is the region of interest in a full sequence of work.
Current workqueue_activate_work trace event output:

    workqueue_activate_work: work struct ffffff88b4a0f450

With this change, workqueue_activate_work will print the function name,
align with workqueue_queue_work/execute_start/execute_end event.

    workqueue_activate_work: work struct ffffff80413a78b8 function=vmstat_update
Signed-off-by: default avatarKassey Li <quic_yingangl@quicinc.com>
Reviewed-by: default avatarSteven Rostedt (Google) <rostedt@goodmis.org>
Signed-off-by: default avatarTejun Heo <tj@kernel.org>
parent 79202591
...@@ -64,13 +64,15 @@ TRACE_EVENT(workqueue_activate_work, ...@@ -64,13 +64,15 @@ TRACE_EVENT(workqueue_activate_work,
TP_STRUCT__entry( TP_STRUCT__entry(
__field( void *, work ) __field( void *, work )
__field( void *, function)
), ),
TP_fast_assign( TP_fast_assign(
__entry->work = work; __entry->work = work;
__entry->function = work->func;
), ),
TP_printk("work struct %p", __entry->work) TP_printk("work struct %p function=%ps ", __entry->work, __entry->function)
); );
/** /**
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment