nvme-pci: disable APST on Samsung SSD 960 EVO + ASUS PRIME B350M-A
commit128dc55f891c79535dbf278e332f0f8fedfa7469
authorKai-Heng Feng <kai.heng.feng@canonical.com>
Thu, 9 Nov 2017 06:12:03 +0000 (9 01:12 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 3 Feb 2018 16:38:58 +0000 (3 17:38 +0100)
tree1f835d99f583fa5853277d02088d066a16485e34
parent7af5f9137c93bd69384a3d12d9f741b63f4d98c4
nvme-pci: disable APST on Samsung SSD 960 EVO + ASUS PRIME B350M-A

[ Upstream commit 8427bbc224863e14d905c87920d4005cb3e88ac3 ]

The NVMe device in question drops off the PCIe bus after system suspend.
I've tried several approaches to workaround this issue, but none of them
works:
- NVME_QUIRK_DELAY_BEFORE_CHK_RDY
- NVME_QUIRK_NO_DEEPEST_PS
- Disable APST before controller shutdown
- Delay between controller shutdown and system suspend
- Explicitly set power state to 0 before controller shutdown

Fortunately it's a desktop, so disable APST won't hurt the battery.

Also, change the quirk function name to reflect it's for vendor
combination quirks.

BugLink: https://bugs.launchpad.net/bugs/1705748
Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/nvme/host/pci.c