NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: kern/38081: ahcisata does not attach for Intel 82801GB/GR



[ ... ] The attached patch [ ... ]

And of course, the atttachment :-)
Index: ahcisata_pci.c
===================================================================
RCS file: /cvsroot/src/sys/dev/pci/ahcisata_pci.c,v
retrieving revision 1.5
diff -d -p -u -r1.5 ahcisata_pci.c
--- ahcisata_pci.c      19 Feb 2008 10:38:28 -0000      1.5
+++ ahcisata_pci.c      22 Feb 2008 12:41:05 -0000
@@ -83,7 +83,10 @@ ahci_pci_match(struct device *parent, st
                    PCI_MAPREG_TYPE_MEM | PCI_MAPREG_MEM_TYPE_32BIT, 0,
                    &regt, &regh, NULL, &size) != 0)
                        return 0;
-               if (bus_space_read_4(regt, regh, AHCI_GHC) & AHCI_GHC_AE)
+               if (PCI_SUBCLASS(pa->pa_class) == PCI_SUBCLASS_MASS_STORAGE_SATA
+                   && PCI_INTERFACE(pa->pa_class) == PCI_INTERFACE_SATA_AHCI)
+                       ret = 3;
+               else if (bus_space_read_4(regt, regh, AHCI_GHC) & AHCI_GHC_AE)
                        ret = 3;
                bus_space_unmap(regt, regh, size);
                return ret;


Home | Main Index | Thread Index | Old Index