]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/ide/pci/amd74xx.c
ide: remove PIO "downgrade" quirk
[linux-2.6-omap-h63xx.git] / drivers / ide / pci / amd74xx.c
index 8c52bc9eaa5910575d70c123e86ffd3edd1ecc55..ff684d3123784853e16332226c5ea1e9975d44a9 100644 (file)
 
 #include <linux/module.h>
 #include <linux/kernel.h>
-#include <linux/ioport.h>
-#include <linux/blkdev.h>
 #include <linux/pci.h>
 #include <linux/init.h>
 #include <linux/ide.h>
-#include <asm/io.h>
 
 #include "ide-timing.h"
 
@@ -199,6 +196,14 @@ static unsigned int __devinit init_chipset_amd74xx(struct pci_dev *dev,
        return dev->irq;
 }
 
+static u8 __devinit amd_cable_detect(ide_hwif_t *hwif)
+{
+       if ((amd_80w >> hwif->channel) & 1)
+               return ATA_CBL_PATA80;
+       else
+               return ATA_CBL_PATA40;
+}
+
 static void __devinit init_hwif_amd74xx(ide_hwif_t *hwif)
 {
        struct pci_dev *dev = to_pci_dev(hwif->dev);
@@ -209,25 +214,15 @@ static void __devinit init_hwif_amd74xx(ide_hwif_t *hwif)
        hwif->set_pio_mode = &amd_set_pio_mode;
        hwif->set_dma_mode = &amd_set_drive;
 
-       if (!hwif->dma_base)
-               return;
-
-       if (hwif->cbl != ATA_CBL_PATA40_SHORT) {
-               if ((amd_80w >> hwif->channel) & 1)
-                       hwif->cbl = ATA_CBL_PATA80;
-               else
-                       hwif->cbl = ATA_CBL_PATA40;
-       }
+       hwif->cable_detect = amd_cable_detect;
 }
 
 #define IDE_HFLAGS_AMD \
        (IDE_HFLAG_PIO_NO_BLACKLIST | \
-        IDE_HFLAG_PIO_NO_DOWNGRADE | \
         IDE_HFLAG_ABUSE_SET_DMA_MODE | \
         IDE_HFLAG_POST_SET_MODE | \
         IDE_HFLAG_IO_32BIT | \
-        IDE_HFLAG_UNMASK_IRQS | \
-        IDE_HFLAG_BOOTABLE)
+        IDE_HFLAG_UNMASK_IRQS)
 
 #define DECLARE_AMD_DEV(name_str, swdma, udma)                         \
        {                                                               \