From: Dave Jiang <dave.jiang@intel.com>
To: Marek Bykowski <marek.bykowski@gmail.com>
Cc: Alison Schofield <alison.schofield@intel.com>, linux-cxl@vger.kernel.org
Subject: Re: trace events
Date: Fri, 18 Nov 2022 16:22:26 -0700 [thread overview]
Message-ID: <eb11a59e-d5ac-8ba7-06ec-ff895caffffd@intel.com> (raw)
In-Reply-To: <20221118223913.075752fd@ubuntu.armcompdev.pub.tds.tieto.com>
On 11/18/2022 3:39 PM, Marek Bykowski wrote:
> On Fri, 18 Nov 2022 08:18:43 -0700
> Dave Jiang <dave.jiang@intel.com> wrote:
>
>
>>
>> Hi Marek. Have you looked into enabling ftrace? Maybe that would be
>> the right starting point for what you are looking for?
>>
>> https://lwn.net/Articles/365835/
>>
>
> That was my initial idea but if there are no trace events defined for
> the CXL what am I to enable? At least I cannot find any events for CXL,
> there is no file include/trace/events/cxl.h in kernel/git/cxl/cxl.git.
> Also
>
> find /sys/kernel/debug/tracing/events/ -name "*cxl*"
>
> on linux-cxl returns nothing.
>
> Alison mentioned she is working on some but these are yet in review.
>
> As putting the trace events throughput the CXL driver/s takes time I
> took a shortcut and added trace_printk scattered around for now. With
> libtraceevent, trace-cmd and kernelshark and it is looking fantastic,
> except it is not the CXL events as per-se.
>
> root@localhost:~# trace-cmd show |tail -n 2
> systemd-udevd-520 [004] ..... 21.236650: devm_cxl_enumerate_decoders: \
> success adding decoder to port endpoint5
> systemd-udevd-520 [004] ..... 21.240517: devm_cxl_enumerate_ports.cold: \
> find_cxl_port() returned port port2
For kernel we are enabling trace events for CXL. But those events are
stemmed from hardware events. Ira is enabling CXL events defined by the
CXL spec and emitted by the devices. Alison is enabling CXL events for
poison data. And I'm enabling CXL events for PCIe AER errors.
But I think you want different type of events right? i.e. the flow of
the driver? I believe ftrace can enable function names for ftrace. Is
that what you are looking for?
https://opensource.com/article/21/7/linux-kernel-ftrace
https://jvns.ca/blog/2017/03/19/getting-started-with-ftrace/
https://lwn.net/Articles/370423/
next prev parent reply other threads:[~2022-11-18 23:38 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-14 20:27 trace events Marek Bykowski
2022-11-18 0:50 ` Alison Schofield
2022-11-18 13:53 ` Marek Bykowski
2022-11-18 15:18 ` Dave Jiang
2022-11-18 22:39 ` Marek Bykowski
2022-11-18 23:22 ` Dave Jiang [this message]
2022-11-21 14:25 ` Marek Bykowski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=eb11a59e-d5ac-8ba7-06ec-ff895caffffd@intel.com \
--to=dave.jiang@intel.com \
--cc=alison.schofield@intel.com \
--cc=linux-cxl@vger.kernel.org \
--cc=marek.bykowski@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox