Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Listing and using custom Linux kernel tracepoints

I followed the tutorial at https://www.kernel.org/doc/Documentation/trace/tracepoints.txt to create a custom tracepoint in the kernel core (i.e. not in a loadable module).

But, I don't see the tracepoint listed in the outputs of perf list or tplist (from bcc tools).

And so, I don't know how to use the tracepoint.

Question: How do I make the tracepoint appear in perf list/tplist output?

Thanks.

like image 953
fpkvdw Avatar asked Aug 07 '26 11:08

fpkvdw


1 Answers

I resolved the issue by using the TRACE_EVENT() macro (see details in this LWN article) instead of DECLARE_TRACE(). I can now see the tracepoint in perf list and tplist outputs.

Thanks to @Qeole for the insight that led to the resolution.

like image 200
fpkvdw Avatar answered Aug 09 '26 13:08

fpkvdw



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!