From: Can Guo <can.guo@oss.qualcomm.com>
To: Bart Van Assche <bvanassche@acm.org>, martin.petersen@oracle.com
Cc: linux-scsi@vger.kernel.org, Alim Akhtar <alim.akhtar@samsung.com>,
Avri Altman <avri.altman@wdc.com>,
"James E.J. Bottomley" <James.Bottomley@HansenPartnership.com>,
Huan Tang <tanghuan@vivo.com>,
Peter Wang <peter.wang@mediatek.com>,
"Bao D. Nguyen" <quic_nguyenb@quicinc.com>,
Liu Song <liu.song13@zte.com.cn>,
Ram Kumar Dwivedi <ram.dwivedi@oss.qualcomm.com>,
Daniel Lee <chullee@google.com>, Bean Huo <huobean@gmail.com>,
Adrian Hunter <adrian.hunter@intel.com>,
open list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v2 1/2] scsi: ufs: core: Add support to notify userspace of UniPro QoS events
Date: Sun, 1 Mar 2026 17:09:53 +0800 [thread overview]
Message-ID: <9b30afb1-c38a-44a6-8a17-3073b5d408ce@oss.qualcomm.com> (raw)
In-Reply-To: <72cd1fba-0f7d-41d3-b933-88eb8fe861fe@acm.org>
Hi Bart,
On 2/26/2026 2:48 AM, Bart Van Assche wrote:
>
> On 2/24/26 6:29 PM, Can Guo wrote:
>> +What: /sys/bus/platform/drivers/ufshcd/*/dme_qos_notification
>> +What: /sys/bus/platform/devices/*.ufs/dme_qos_notification
>> +Date: February 2026
>> +Contact: Can Guo <can.guo@oss.qualcomm.com>
>> +Description:
>> + This attribute shows and clears the DME Quality of Service
>> + notification from UFSHCI UECDME.
>> +
>> + The attribute is read/write.
>
> The above text is incomplete. It should explain that
> dme_qos_notification is a bitfield, what the meaning of the bits in this
> bitfield are, when this bitfield is updated, that the only value that
> can be written into this bitfield is 0 and also what the effect of
> writing 0 into this bitfield is.
Done.
>
>> diff --git a/drivers/ufs/core/ufshcd-priv.h
>> b/drivers/ufs/core/ufshcd-priv.h
>> index 7d6d19361af9..14e8cb145f43 100644
>> --- a/drivers/ufs/core/ufshcd-priv.h
>> +++ b/drivers/ufs/core/ufshcd-priv.h
>> @@ -446,4 +446,10 @@ static inline void ufs_rpmb_remove(struct
>> ufs_hba *hba)
>> }
>> #endif
>> +static inline void sysfs_notify_dirent_safe(struct kernfs_node *sd)
>> +{
>> + if (sd)
>> + sysfs_notify_dirent(sd);
>> +}
>
> This function is very short and is not used outside
> drivers/ufs/core/ufshcd.c. Is it really needed to introduce this
> function? If this function is preserved, please consider moving it into
> drivers/ufs/core/ufshcd.c.
Done.
>
> > @@ -11044,6 +11051,8 @@ int ufshcd_init(struct ufs_hba *hba, void
> __iomem *mmio_base, unsigned int irq)
> > goto out_disable;
> >
> > ufs_sysfs_add_nodes(hba->dev);
> > + hba->dme_qos_sysfs_handle = sysfs_get_dirent(hba->dev->kobj.sd,
> > + "dme_qos_notification");
> > async_schedule(ufshcd_async_scan, hba);
> >
> > device_enable_async_suspend(dev);
>
> Where is the sysfs_put() call that corresponds to the above
> sysfs_get_dirent() call?
Good catch, I missed it.. Will add it in next version.
>
>> + * @dme_qos_notification: UFS host controller DME QoS notification
>
> Please explain also here that this is a bitfield and where the meaning
> of the bits in this bitfield are defined.
Done.
>
> Thanks,
>
> Bart.
next prev parent reply other threads:[~2026-03-01 9:10 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20260225022942.345564-1-can.guo@oss.qualcomm.com>
2026-02-25 2:29 ` Can Guo
2026-02-25 18:48 ` Bart Van Assche
2026-03-01 9:09 ` Can Guo [this message]
2026-02-25 2:29 ` [PATCH v2 2/2] scsi: ufs: core: Add a sysfs entry for ufshcd_state Can Guo
2026-02-25 18:59 ` Bart Van Assche
2026-03-01 12:40 ` Can Guo
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=9b30afb1-c38a-44a6-8a17-3073b5d408ce@oss.qualcomm.com \
--to=can.guo@oss.qualcomm.com \
--cc=James.Bottomley@HansenPartnership.com \
--cc=adrian.hunter@intel.com \
--cc=alim.akhtar@samsung.com \
--cc=avri.altman@wdc.com \
--cc=bvanassche@acm.org \
--cc=chullee@google.com \
--cc=huobean@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=liu.song13@zte.com.cn \
--cc=martin.petersen@oracle.com \
--cc=peter.wang@mediatek.com \
--cc=quic_nguyenb@quicinc.com \
--cc=ram.dwivedi@oss.qualcomm.com \
--cc=tanghuan@vivo.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
all inboxes | Powered by JetHome®