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] [thread-next>] [day] [month] [year] [list]
Date:   Mon, 14 Feb 2022 16:07:51 +0000
From:   "Limonciello, Mario" <Mario.Limonciello@....com>
To:     Paul Menzel <pmenzel@...gen.mpg.de>,
        Hans de Goede <hdegoede@...hat.com>
CC:     "linux-ide@...r.kernel.org" <linux-ide@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        Damien Le Moal <damien.lemoal@...nsource.wdc.com>,
        "Shah, Nehal-bakulchandra" <Nehal-bakulchandra.Shah@....com>
Subject: RE: [PATCH 1/2] ahci: Add Green Sardine vendor ID as
 board_ahci_mobile

[Public]

+Hans

> (For the records, is part of Linux since 5.16-rc2 (commit 1527f69204fe).)
> 
> Am 12.11.21 um 21:15 schrieb Mario Limonciello:
> > AMD requires that the SATA controller be configured for devsleep in order
> > for S0i3 entry to work properly.
> >
> > commit b1a9585cc396 ("ata: ahci: Enable DEVSLP by default on x86 with
> > SLP_S0") sets up a kernel policy to enable devsleep on Intel mobile
> > platforms that are using s0ix.  Add the PCI ID for the SATA controller in
> > Green Sardine platforms to extend this policy by default for AMD based
> > systems using s0i3 as well.
> >
> > Cc: Nehal-bakulchandra Shah <Nehal-bakulchandra.Shah@....com>
> > BugLink:
> https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fbugz
> illa.kernel.org%2Fshow_bug.cgi%3Fid%3D214091&amp;data=04%7C01%7Cm
> ario.limonciello%40amd.com%7Ca32a202d437544cd2cbb08d9ef9112c0%7C3d
> d8961fe4884e608e11a82d994e183d%7C0%7C0%7C637804228648002522%7CU
> nknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI
> 6Ik1haWwiLCJXVCI6Mn0%3D%7C3000&amp;sdata=CbfImBnwc8uV1L5QRBuV
> PLkP72wpS9yif1UbUwykhNI%3D&amp;reserved=0
> > Signed-off-by: Mario Limonciello <mario.limonciello@....com>
> > ---
> >   drivers/ata/ahci.c | 1 +
> >   1 file changed, 1 insertion(+)
> >
> > diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c
> > index d60f34718b5d..1e1167e725a4 100644
> > --- a/drivers/ata/ahci.c
> > +++ b/drivers/ata/ahci.c
> > @@ -438,6 +438,7 @@ static const struct pci_device_id ahci_pci_tbl[] = {
> >   	/* AMD */
> >   	{ PCI_VDEVICE(AMD, 0x7800), board_ahci }, /* AMD Hudson-2 */
> >   	{ PCI_VDEVICE(AMD, 0x7900), board_ahci }, /* AMD CZ */
> > +	{ PCI_VDEVICE(AMD, 0x7901), board_ahci_mobile }, /* AMD Green
> Sardine */
> 
> Aren't 0x7900 and 0x7901 the same device only in different modes? I
> wonder, why different boards and different comments are used.

No they aren't the same device in different modes.

Reference:
https://www.amd.com/en/support/tech-docs/processor-programming-reference-ppr-for-amd-family-19h-model-51h-revision-a1
Page 33 has a table.

> 
> Additionally, the device 0x7901 is also present in desktop systems like
> Dell OptiPlex 5055 and MSI B350 MORTAR. Is `board_ahci_mobile` the right
> board then? Or should the flag `AHCI_HFLAG_IS_MOBILE` be renamed to
> avoid confusion?

Are you having a problem or just want clarity in the enum definition?

This was introduced by Hans in commit ebb82e3c79d2a to set LPM policy properly
for a number of mobile devices.

My opinion here is that the policy being for "mobile" devices only is short sighted as power
consumption policy on desktops is also relevant as OEMs ship desktops that need to meet
various power regulations for those too.

So I would be in the camp for renaming the flags.

> 
> >   	/* AMD is using RAID class only for ahci controllers */
> >   	{ PCI_VENDOR_ID_AMD, PCI_ANY_ID, PCI_ANY_ID, PCI_ANY_ID,
> >   	  PCI_CLASS_STORAGE_RAID << 8, 0xffffff, board_ahci },
> 
> 
> Kind regards,
> 
> Paul

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ