[PATCH] libata-eh: Remove layering violation and duplication when handling absent...
[linux-2.6-block.git] / drivers / ata / pata_efar.c
index c30bc181304f4ac2f5b5366d90a22704a5110ecb..92813827faa724d750d4328f2d5892d345fb4a9f 100644 (file)
@@ -22,7 +22,7 @@
 #include <linux/ata.h>
 
 #define DRV_NAME       "pata_efar"
-#define DRV_VERSION    "0.4.1"
+#define DRV_VERSION    "0.4.2"
 
 /**
  *     efar_pre_reset  -       check for 40/80 pin
@@ -42,11 +42,9 @@ static int efar_pre_reset(struct ata_port *ap)
        struct pci_dev *pdev = to_pci_dev(ap->host->dev);
        u8 tmp;
 
-       if (!pci_test_config_bits(pdev, &efar_enable_bits[ap->port_no])) {
-               ata_port_disable(ap);
-               printk(KERN_INFO "ata%u: port disabled. ignoring.\n", ap->id);
-               return 0;
-       }
+       if (!pci_test_config_bits(pdev, &efar_enable_bits[ap->port_no]))
+               return -ENOENT;
+
        pci_read_config_byte(pdev, 0x47, &tmp);
        if (tmp & (2 >> ap->port_no))
                ap->cbl = ATA_CBL_PATA40;