lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID:
 <DM6PR04MB6575DFBBB1B020FDA23FAC78FCB22@DM6PR04MB6575.namprd04.prod.outlook.com>
Date: Thu, 1 Aug 2024 07:01:07 +0000
From: Avri Altman <Avri.Altman@....com>
To: Bart Van Assche <bvanassche@....org>, "Martin K . Petersen"
	<martin.petersen@...cle.com>
CC: "linux-scsi@...r.kernel.org" <linux-scsi@...r.kernel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: RE: [PATCH 2/2] scsi: ufs: Add HCI capabilities sysfs group

> On 7/31/24 5:20 AM, Avri Altman wrote:
> > +static ssize_t capabilities_show(struct device *dev,
> > +             struct device_attribute *attr, char *buf) {
> > +     struct ufs_hba *hba = dev_get_drvdata(dev);
> > +
> > +     return sysfs_emit(buf, "0x%x\n", hba->capabilities); }
> 
> For every new sysfs entry that is added, documentation must be added in
> Documentation/ABI/testing/sysfs-driver-ufs.
Done.

> 
> > +static ssize_t ext_capabilities_show(struct device *dev,
> > +             struct device_attribute *attr, char *buf) {
> > +     int ret;
> > +     u32 val;
> > +     struct ufs_hba *hba = dev_get_drvdata(dev);
> > +
> > +     if (hba->ufs_version < ufshci_version(4, 0))
> > +             return -EOPNOTSUPP;
> > +
> > +     ret = ufshcd_read_hci_reg(hba, &val,
> REG_EXT_CONTROLLER_CAPABILITIES);
> > +     if (ret)
> > +             return ret;
> > +
> > +     return sysfs_emit(buf, "0x%x\n", val); }
> 
> Host controller register reads must be protected by
> ufshcd_rpm_get_sync(hba) / ufshcd_rpm_put_sync(hba).
Done.
I guess that those need to be added to auto_hibern8_show as well.

Thanks,
Avri

> 
> Thanks,
> 
> Bart.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ