]> git.hungrycats.org Git - linux/commitdiff
pata_amd: fix an obvious bug in cable detection
authorTejun Heo <htejun@gmail.com>
Mon, 5 Feb 2007 08:01:28 +0000 (17:01 +0900)
committerGreg Kroah-Hartman <gregkh@suse.de>
Sat, 24 Feb 2007 00:24:26 +0000 (16:24 -0800)
80c test mask is at bits 18 and 19 of EIDE Controller Configuration
not 22 and 23.  Fix it.

Signed-off-by: Tejun Heo <htejun@gmail.com>
Acked-by: Alan Cox <alan@lxorguk.ukuu.org.uk>
drivers/ata/pata_amd.c

index 5c47a9e0e0ca0742d9d63fb72ad513395b0428c2..3a1f83c27e2542460c1b4d1130a41aaebbc8c230 100644 (file)
@@ -128,7 +128,7 @@ static void timing_setup(struct ata_port *ap, struct ata_device *adev, int offse
 
 static int amd_pre_reset(struct ata_port *ap)
 {
-       static const u32 bitmask[2] = {0x03, 0xC0};
+       static const u32 bitmask[2] = {0x03, 0x0C};
        static const struct pci_bits amd_enable_bits[] = {
                { 0x40, 1, 0x02, 0x02 },
                { 0x40, 1, 0x01, 0x01 }
@@ -247,7 +247,7 @@ static void amd133_set_dmamode(struct ata_port *ap, struct ata_device *adev)
  */
 
 static int nv_pre_reset(struct ata_port *ap) {
-       static const u8 bitmask[2] = {0x03, 0xC0};
+       static const u8 bitmask[2] = {0x03, 0x0C};
        static const struct pci_bits nv_enable_bits[] = {
                { 0x50, 1, 0x02, 0x02 },
                { 0x50, 1, 0x01, 0x01 }