From f72f671ceab1b30fd6a945fab22b49521e1d6c32 Mon Sep 17 00:00:00 2001 From: Martin Pieuchot Date: Thu, 10 Nov 2016 11:56:42 +0000 Subject: Match Apple NVMe controller by product ID, yes apple is different. Reported and tested by gonzalo@ on a Macbookair7,1. --- sys/dev/pci/nvme_pci.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sys/dev/pci/nvme_pci.c b/sys/dev/pci/nvme_pci.c index e40a09268d7..7778cd6f235 100644 --- a/sys/dev/pci/nvme_pci.c +++ b/sys/dev/pci/nvme_pci.c @@ -1,4 +1,4 @@ -/* $OpenBSD: nvme_pci.c,v 1.4 2016/10/25 06:20:41 dlg Exp $ */ +/* $OpenBSD: nvme_pci.c,v 1.5 2016/11/10 11:56:41 mpi Exp $ */ /* * Copyright (c) 2014 David Gwynne @@ -70,6 +70,10 @@ nvme_pci_match(struct device *parent, void *match, void *aux) PCI_INTERFACE(pa->pa_class) == NVME_PCI_INTERFACE) return (1); + if (PCI_VENDOR(pa->pa_id) == PCI_VENDOR_APPLE && + PCI_PRODUCT(pa->pa_id) == PCI_PRODUCT_APPLE_NVME) + return (1); + return (0); } -- cgit v1.2.3