Re: [PATCH v1] ufs: core: add hba parameter to trace events

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 2025-02-12 at 10:56 -0800, Bart Van Assche wrote:
> 
> External email : Please do not click links or open attachments until
> you have verified the sender or the content.
> 
> 
> On 2/12/25 2:14 AM, peter.wang@xxxxxxxxxxxx wrote:
> > diff --git a/drivers/ufs/core/ufs_trace.h
> > b/drivers/ufs/core/ufs_trace.h
> > index 84deca2b841d..e175020a2fcc 100644
> > --- a/drivers/ufs/core/ufs_trace.h
> > +++ b/drivers/ufs/core/ufs_trace.h
> > @@ -83,17 +83,19 @@ UFS_CMD_TRACE_TSF_TYPES
> > 
> >   TRACE_EVENT(ufshcd_clk_gating,
> > 
> > -     TP_PROTO(const char *dev_name, int state),
> > +     TP_PROTO(const char *dev_name, struct ufs_hba *hba, int
> > state),
> > 
> > -     TP_ARGS(dev_name, state),
> > +     TP_ARGS(dev_name, hba, state),
> > 
> >       TP_STRUCT__entry(
> >               __string(dev_name, dev_name)
> > +             __field(struct ufs_hba *, hba)
> >               __field(int, state)
> >       ),
> > 
> >       TP_fast_assign(
> >               __assign_str(dev_name);
> > +             __entry->hba = hba;
> >               __entry->state = state;
> >       ),
> 
> Why to include the HBA pointer in tracing events if this pointer is
> not
> used in any TP_printk() call?
> 
> dev_name == dev_name(hba->dev) so the dev_name argument should be
> left
> out from all tracing events that now have a HBA pointer as argument.
> 
> Thanks,
> 
> Bart.

Hi Bart,

The system may have multiple HBA hosts, adding HBA helps trace 
which host the event belongs to. 
The dev_name will be removed in the next version, 

Thanks
Peter








[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]

  Powered by Linux