Commit 0deb91318b15f0d12839b23433e2720722504d25

Authored by Jon Nettleton
Committed by Tom Rini
1 parent 0adc38be3d

nvme: Detect devices that are class Storage Express

This adds support to detect the catchall PCI class for NVMe devices.
It allows the drivers to work with most NVMe devices that don't need
specific detection due to quirks etc.

Tested against a Samsung 960 EVO drive.

Signed-off-by: Jon Nettleton <jon@solid-run.com>
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Tom Rini <trini@konsulko.com>

Showing 2 changed files with 2 additions and 1 deletions Side-by-side Diff

... ... @@ -832,7 +832,7 @@
832 832 };
833 833  
834 834 struct pci_device_id nvme_supported[] = {
835   - { PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x0953) },
  835 + { PCI_DEVICE_CLASS(PCI_CLASS_STORAGE_EXPRESS, ~0) },
836 836 {}
837 837 };
838 838  
... ... @@ -21,6 +21,7 @@
21 21 #define PCI_CLASS_STORAGE_SATA 0x0106
22 22 #define PCI_CLASS_STORAGE_SATA_AHCI 0x010601
23 23 #define PCI_CLASS_STORAGE_SAS 0x0107
  24 +#define PCI_CLASS_STORAGE_EXPRESS 0x010802
24 25 #define PCI_CLASS_STORAGE_OTHER 0x0180
25 26  
26 27 #define PCI_BASE_CLASS_NETWORK 0x02