aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorKassey Li <quic_yingangl@quicinc.com>2024-03-08 10:18:18 +0800
committerTejun Heo <tj@kernel.org>2024-03-25 09:28:52 -1000
commitd6a7bbdde67227127e5e33fb9500bcc4abc40fb3 (patch)
tree22d332e31a242f1903f4df03c9e9c71b2bd84159
parentworkqueue: Cleanup subsys attribute registration (diff)
downloadwireguard-linux-d6a7bbdde67227127e5e33fb9500bcc4abc40fb3.tar.xz
wireguard-linux-d6a7bbdde67227127e5e33fb9500bcc4abc40fb3.zip
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: Kassey Li <quic_yingangl@quicinc.com> Reviewed-by: Steven Rostedt (Google) <rostedt@goodmis.org> Signed-off-by: Tejun Heo <tj@kernel.org>
-rw-r--r--include/trace/events/workqueue.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/include/trace/events/workqueue.h b/include/trace/events/workqueue.h
index 262d52021c23..6ef5b7254070 100644
--- a/include/trace/events/workqueue.h
+++ b/include/trace/events/workqueue.h
@@ -64,13 +64,15 @@ TRACE_EVENT(workqueue_activate_work,
TP_STRUCT__entry(
__field( void *, work )
+ __field( void *, function)
),
TP_fast_assign(
__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)
);
/**