]> err.no Git - linux-2.6/commitdiff
libata pata_amd: ACPI checks for 80wire cable
authorAlan Cox <alan@lxorguk.ukuu.org.uk>
Thu, 26 Jul 2007 17:37:28 +0000 (18:37 +0100)
committerJeff Garzik <jeff@garzik.org>
Fri, 12 Oct 2007 18:55:34 +0000 (14:55 -0400)
We can make use of this on the pata_amd driver as many Nvidia devices
don't have reliable cable detect.

Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
drivers/ata/pata_amd.c

index 46f829c838b3b78901572f9a2ecae1ec996ad66d..c95922f8cc5ec702b1b899ddc585fa78af39e63d 100644 (file)
@@ -270,6 +270,9 @@ static int nv_cable_detect(struct ata_port *ap)
        pci_read_config_word(pdev, 0x62 - 2 * ap->port_no, &udma);
        if ((udma & 0xC4) == 0xC4 || (udma & 0xC400) == 0xC400)
                cbl = ATA_CBL_PATA80;
+       /* And a triple check across suspend/resume with ACPI around */
+       if (ata_acpi_cbl_80wire(ap))
+               cbl = ATA_CBL_PATA80;
        return cbl;
 }