[PATCH v3] ufs: core: add hba parameter to trace events
Peter Wang (王信友)
peter.wang at mediatek.com
Sun Feb 16 21:32:55 PST 2025
On Sun, 2025-02-16 at 15:15 +0100, Bean Huo wrote:
>
> External email : Please do not click links or open attachments until
> you have verified the sender or the content.
>
>
> On Fri, 2025-02-14 at 16:29 +0800, peter.wang at mediatek.com wrote:
> > From: Peter Wang <peter.wang at mediatek.com>
> >
> > Included the ufs_hba structure as a parameter in various trace
> > events
> > to provide more context and improve debugging capabilities.
>
>
> From the patch commit message, it is no clear how you can use this
> change to get more infor and debug, since the content of the ftrace
> output is the same after this change. Because the device name
> (dev_name) is still being printed, but now it is derived dynamically
> from hba->dev instead of being stored as a string in the trace event.
>
> I assume you mean to let bpf get more information from hba:
>
>
> strust ufs hba *hba = ctx->hba;
>
> If my assumption is correct, this purpose and intent should be
> prominently highlighted in patch commit message.
>
>
> Kind regards,
> Bean
Hi Bean,
The use of HBA varies depending on the debugging needs.
When the tracepoint_probe_register is used to register a
debug callback function, we can utilize the parameters of
the HBA structure more efficiently to obtain the debug
information we need.
As for what specific debug information is required,
that depends on the individual needs. It depends on
how the debugger wants to use it, so the method of use
is not specifically mentioned in the commit message.
However, in summary, it is a patch that enhances
debugging efficiency.
Thanks.
Peter
More information about the Linux-mediatek
mailing list