From 02f076aaa1478a91762de522ecb029efbc279690 Mon Sep 17 00:00:00 2001 From: Alan Cox Date: Tue, 26 Sep 2006 17:35:32 +0100 Subject: [PATCH 1/9] [PATCH] libata: refuse to register IRQless ports We don't currently support pure polled operation so when we meet a BIOS which forgot to assign an IRQ to a PCI device it all goes a little pear shaped. Trap this case properly. Signed-off-by: Alan Cox Signed-off-by: Jeff Garzik --- drivers/ata/libata-core.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c index 753b0152afd1..b4abd6850367 100644 --- a/drivers/ata/libata-core.c +++ b/drivers/ata/libata-core.c @@ -5453,6 +5453,11 @@ int ata_device_add(const struct ata_probe_ent *ent) int rc; DPRINTK("ENTER\n"); + + if (ent->irq == 0) { + dev_printk(KERN_ERR, dev, "is not available: No interrupt assigned.\n"); + return 0; + } /* alloc a container for our list of ATA ports (buses) */ host = kzalloc(sizeof(struct ata_host) + (ent->n_ports * sizeof(void *)), GFP_KERNEL); From 4735ebedf37731160e3d3efc9fc9d4939c66fefa Mon Sep 17 00:00:00 2001 From: Alan Cox Date: Tue, 26 Sep 2006 17:37:22 +0100 Subject: [PATCH 2/9] [PATCH] libata: tighten rules for legacy dependancies The legacy and QDI drivers are ISA/VLB bus [we don't have a VLB define but ISA will do nicely]. Signed-off-by: Alan Cox Signed-off-by: Jeff Garzik --- drivers/ata/Kconfig | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/ata/Kconfig b/drivers/ata/Kconfig index 99837d932f36..3f4aa0c99ee4 100644 --- a/drivers/ata/Kconfig +++ b/drivers/ata/Kconfig @@ -311,7 +311,7 @@ config PATA_JMICRON config PATA_LEGACY tristate "Legacy ISA PATA support (Experimental)" - depends on PCI && EXPERIMENTAL + depends on ISA && EXPERIMENTAL help This option enables support for ISA/VLB bus legacy PATA ports and allows them to be accessed via the new ATA layer. @@ -400,6 +400,7 @@ config PATA_PDC_OLD config PATA_QDI tristate "QDI VLB PATA support" + depends on ISA help Support for QDI 6500 and 6580 PATA controllers on VESA local bus. From c961922b73dab429a759f560952fd4c3f60bd6b3 Mon Sep 17 00:00:00 2001 From: Alan Cox Date: Tue, 26 Sep 2006 17:53:38 +0100 Subject: [PATCH 3/9] [PATCH] libata-eh: Remove layering violation and duplication when handling absent ports This removes the layering violation where drivers have to fiddle directly with EH flags. Instead we now recognize -ENOENT means "no port" and do the handling in the core code. This also removes an instance of a call to disable the port, and an identical printk from each driver doing this. Even better - future rule changes will be in one place only. Signed-off-by: Alan Cox Signed-off-by: Jeff Garzik --- drivers/ata/ata_piix.c | 8 +++----- drivers/ata/libata-eh.c | 6 +++++- drivers/ata/pata_amd.c | 25 ++++++++----------------- drivers/ata/pata_artop.c | 18 +++++++----------- drivers/ata/pata_atiixp.c | 10 ++++------ drivers/ata/pata_efar.c | 10 ++++------ drivers/ata/pata_jmicron.c | 2 +- drivers/ata/pata_mpiix.c | 11 ++++------- drivers/ata/pata_ns87410.c | 7 ++----- drivers/ata/pata_oldpiix.c | 9 +++------ drivers/ata/pata_opti.c | 10 ++++------ drivers/ata/pata_optidma.c | 10 ++++------ drivers/ata/pata_pdc2027x.c | 8 +++----- drivers/ata/pata_sis.c | 10 ++++------ drivers/ata/pata_sl82c105.c | 9 +++------ drivers/ata/pata_triflex.c | 13 +++++-------- drivers/ata/pata_via.c | 9 +++------ 17 files changed, 67 insertions(+), 108 deletions(-) diff --git a/drivers/ata/ata_piix.c b/drivers/ata/ata_piix.c index ffa111eea9da..5719704eb0ee 100644 --- a/drivers/ata/ata_piix.c +++ b/drivers/ata/ata_piix.c @@ -643,11 +643,9 @@ static int piix_pata_prereset(struct ata_port *ap) { struct pci_dev *pdev = to_pci_dev(ap->host->dev); - if (!pci_test_config_bits(pdev, &piix_enable_bits[ap->port_no])) { - ata_port_printk(ap, KERN_INFO, "port disabled. ignoring.\n"); - ap->eh_context.i.action &= ~ATA_EH_RESET_MASK; - return 0; - } + if (!pci_test_config_bits(pdev, &piix_enable_bits[ap->port_no])) + return -ENOENT; + ap->cbl = ATA_CBL_PATA40; return ata_std_prereset(ap); } diff --git a/drivers/ata/libata-eh.c b/drivers/ata/libata-eh.c index 3fa80f09f2ae..02b2b2787d9b 100644 --- a/drivers/ata/libata-eh.c +++ b/drivers/ata/libata-eh.c @@ -1515,7 +1515,11 @@ static int ata_eh_reset(struct ata_port *ap, int classify, if (prereset) { rc = prereset(ap); if (rc) { - ata_port_printk(ap, KERN_ERR, + if (rc == -ENOENT) { + ata_port_printk(ap, KERN_DEBUG, "port disabled. ignoring.\n"); + ap->eh_context.i.action &= ~ATA_EH_RESET_MASK; + } else + ata_port_printk(ap, KERN_ERR, "prereset failed (errno=%d)\n", rc); return rc; } diff --git a/drivers/ata/pata_amd.c b/drivers/ata/pata_amd.c index 3293cf9a7eb5..793a5e1cb4cb 100644 --- a/drivers/ata/pata_amd.c +++ b/drivers/ata/pata_amd.c @@ -25,7 +25,7 @@ #include #define DRV_NAME "pata_amd" -#define DRV_VERSION "0.2.3" +#define DRV_VERSION "0.2.4" /** * timing_setup - shared timing computation and load @@ -137,11 +137,8 @@ static int amd_pre_reset(struct ata_port *ap) struct pci_dev *pdev = to_pci_dev(ap->host->dev); u8 ata66; - if (!pci_test_config_bits(pdev, &amd_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, &amd_enable_bits[ap->port_no])) + return -ENOENT; pci_read_config_byte(pdev, 0x42, &ata66); if (ata66 & bitmask[ap->port_no]) @@ -167,11 +164,9 @@ static int amd_early_pre_reset(struct ata_port *ap) { 0x40, 1, 0x01, 0x01 } }; - if (!pci_test_config_bits(pdev, &amd_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, &amd_enable_bits[ap->port_no])) + return -ENOENT; + /* No host side cable detection */ ap->cbl = ATA_CBL_PATA80; return ata_std_prereset(ap); @@ -262,12 +257,8 @@ static int nv_pre_reset(struct ata_port *ap) { u8 ata66; u16 udma; - if (!pci_test_config_bits(pdev, &nv_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, &nv_enable_bits[ap->port_no])) + return -ENOENT; pci_read_config_byte(pdev, 0x52, &ata66); if (ata66 & bitmask[ap->port_no]) diff --git a/drivers/ata/pata_artop.c b/drivers/ata/pata_artop.c index d6ef3bf1bac7..0f3b49176dc1 100644 --- a/drivers/ata/pata_artop.c +++ b/drivers/ata/pata_artop.c @@ -28,7 +28,7 @@ #include #define DRV_NAME "pata_artop" -#define DRV_VERSION "0.4.1" +#define DRV_VERSION "0.4.2" /* * The ARTOP has 33 Mhz and "over clocked" timing tables. Until we @@ -47,11 +47,9 @@ static int artop6210_pre_reset(struct ata_port *ap) { 0x4AU, 1U, 0x04UL, 0x04UL }, /* port 1 */ }; - if (!pci_test_config_bits(pdev, &artop_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, &artop_enable_bits[ap->port_no])) + return -ENOENT; + ap->cbl = ATA_CBL_PATA40; return ata_std_prereset(ap); } @@ -90,11 +88,9 @@ static int artop6260_pre_reset(struct ata_port *ap) u8 tmp; /* Odd numbered device ids are the units with enable bits (the -R cards) */ - if (pdev->device % 1 && !pci_test_config_bits(pdev, &artop_enable_bits[ap->port_no])) { - ata_port_disable(ap); - printk(KERN_INFO "ata%u: port disabled. ignoring.\n", ap->id); - return 0; - } + if (pdev->device % 1 && !pci_test_config_bits(pdev, &artop_enable_bits[ap->port_no])) + return -ENOENT; + pci_read_config_byte(pdev, 0x49, &tmp); if (tmp & (1 >> ap->port_no)) ap->cbl = ATA_CBL_PATA40; diff --git a/drivers/ata/pata_atiixp.c b/drivers/ata/pata_atiixp.c index 3f78a1e54a75..060d019fd30b 100644 --- a/drivers/ata/pata_atiixp.c +++ b/drivers/ata/pata_atiixp.c @@ -22,7 +22,7 @@ #include #define DRV_NAME "pata_atiixp" -#define DRV_VERSION "0.4.2" +#define DRV_VERSION "0.4.3" enum { ATIIXP_IDE_PIO_TIMING = 0x40, @@ -41,11 +41,9 @@ static int atiixp_pre_reset(struct ata_port *ap) { 0x48, 1, 0x08, 0x00 } }; - if (!pci_test_config_bits(pdev, &atiixp_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, &atiixp_enable_bits[ap->port_no])) + return -ENOENT; + ap->cbl = ATA_CBL_PATA80; return ata_std_prereset(ap); } diff --git a/drivers/ata/pata_efar.c b/drivers/ata/pata_efar.c index c30bc181304f..92813827faa7 100644 --- a/drivers/ata/pata_efar.c +++ b/drivers/ata/pata_efar.c @@ -22,7 +22,7 @@ #include #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; diff --git a/drivers/ata/pata_jmicron.c b/drivers/ata/pata_jmicron.c index 6832a643a9eb..3bdb6f2fa5ba 100644 --- a/drivers/ata/pata_jmicron.c +++ b/drivers/ata/pata_jmicron.c @@ -51,7 +51,7 @@ static int jmicron_pre_reset(struct ata_port *ap) /* Check if our port is enabled */ pci_read_config_dword(pdev, 0x40, &control); if ((control & port_mask) == 0) - return 0; + return -ENOENT; /* There are two basic mappings. One has the two SATA ports merged as master/slave and the secondary as PATA, the other has only the diff --git a/drivers/ata/pata_mpiix.c b/drivers/ata/pata_mpiix.c index 1958c4ed09a8..3c65393c1f01 100644 --- a/drivers/ata/pata_mpiix.c +++ b/drivers/ata/pata_mpiix.c @@ -18,7 +18,7 @@ * The driver conciously keeps this logic internally to avoid pushing quirky * PATA history into the clean libata layer. * - * Thinkpad specific note: If you boot an MPIIX using thinkpad with a PCMCIA + * Thinkpad specific note: If you boot an MPIIX using a thinkpad with a PCMCIA * hard disk present this driver will not detect it. This is not a bug. In this * configuration the secondary port of the MPIIX is disabled and the addresses * are decoded by the PCMCIA bridge and therefore are for a generic IDE driver @@ -35,7 +35,7 @@ #include #define DRV_NAME "pata_mpiix" -#define DRV_VERSION "0.7.1" +#define DRV_VERSION "0.7.2" enum { IDETIM = 0x6C, /* IDE control register */ @@ -54,11 +54,8 @@ static int mpiix_pre_reset(struct ata_port *ap) { 0x6F, 1, 0x80, 0x80 } }; - if (!pci_test_config_bits(pdev, &mpiix_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, &mpiix_enable_bits[ap->port_no])) + return -ENOENT; ap->cbl = ATA_CBL_PATA40; return ata_std_prereset(ap); } diff --git a/drivers/ata/pata_ns87410.c b/drivers/ata/pata_ns87410.c index 93d6646d2954..f529fe4c29b7 100644 --- a/drivers/ata/pata_ns87410.c +++ b/drivers/ata/pata_ns87410.c @@ -45,11 +45,8 @@ static int ns87410_pre_reset(struct ata_port *ap) { 0x47, 1, 0x08, 0x08 } }; - if (!pci_test_config_bits(pdev, &ns87410_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, &ns87410_enable_bits[ap->port_no])) + return -ENOENT; ap->cbl = ATA_CBL_PATA40; return ata_std_prereset(ap); } diff --git a/drivers/ata/pata_oldpiix.c b/drivers/ata/pata_oldpiix.c index 04c618a2664b..31a285ca88dc 100644 --- a/drivers/ata/pata_oldpiix.c +++ b/drivers/ata/pata_oldpiix.c @@ -25,7 +25,7 @@ #include #define DRV_NAME "pata_oldpiix" -#define DRV_VERSION "0.5.1" +#define DRV_VERSION "0.5.2" /** * oldpiix_pre_reset - probe begin @@ -42,11 +42,8 @@ static int oldpiix_pre_reset(struct ata_port *ap) { 0x43U, 1U, 0x80UL, 0x80UL }, /* port 1 */ }; - if (!pci_test_config_bits(pdev, &oldpiix_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, &oldpiix_enable_bits[ap->port_no])) + return -ENOENT; ap->cbl = ATA_CBL_PATA40; return ata_std_prereset(ap); } diff --git a/drivers/ata/pata_opti.c b/drivers/ata/pata_opti.c index c3d01325e0e2..136d7a65feb3 100644 --- a/drivers/ata/pata_opti.c +++ b/drivers/ata/pata_opti.c @@ -34,7 +34,7 @@ #include #define DRV_NAME "pata_opti" -#define DRV_VERSION "0.2.4" +#define DRV_VERSION "0.2.5" enum { READ_REG = 0, /* index of Read cycle timing register */ @@ -59,11 +59,9 @@ static int opti_pre_reset(struct ata_port *ap) { 0x40, 1, 0x08, 0x00 } }; - if (!pci_test_config_bits(pdev, &opti_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, &opti_enable_bits[ap->port_no])) + return -ENOENT; + ap->cbl = ATA_CBL_PATA40; return ata_std_prereset(ap); } diff --git a/drivers/ata/pata_optidma.c b/drivers/ata/pata_optidma.c index 177a455f4251..18ec8e72bbb6 100644 --- a/drivers/ata/pata_optidma.c +++ b/drivers/ata/pata_optidma.c @@ -33,7 +33,7 @@ #include #define DRV_NAME "pata_optidma" -#define DRV_VERSION "0.2.1" +#define DRV_VERSION "0.2.2" enum { READ_REG = 0, /* index of Read cycle timing register */ @@ -59,11 +59,9 @@ static int optidma_pre_reset(struct ata_port *ap) 0x40, 1, 0x08, 0x00 }; - if (ap->port_no && !pci_test_config_bits(pdev, &optidma_enable_bits)) { - ata_port_disable(ap); - printk(KERN_INFO "ata%u: port disabled. ignoring.\n", ap->id); - return 0; - } + if (ap->port_no && !pci_test_config_bits(pdev, &optidma_enable_bits)) + return -ENOENT; + ap->cbl = ATA_CBL_PATA40; return ata_std_prereset(ap); } diff --git a/drivers/ata/pata_pdc2027x.c b/drivers/ata/pata_pdc2027x.c index 31ab9c886209..bd4ed6734edc 100644 --- a/drivers/ata/pata_pdc2027x.c +++ b/drivers/ata/pata_pdc2027x.c @@ -36,7 +36,7 @@ #include #define DRV_NAME "pata_pdc2027x" -#define DRV_VERSION "0.74-ac3" +#define DRV_VERSION "0.74-ac5" #undef PDC_DEBUG #ifdef PDC_DEBUG @@ -311,10 +311,8 @@ static inline int pdc2027x_port_enabled(struct ata_port *ap) static int pdc2027x_prereset(struct ata_port *ap) { /* Check whether port enabled */ - if (!pdc2027x_port_enabled(ap)) { - printk(KERN_INFO "ata%u: port disabled. ignoring.\n", ap->id); - return 0; - } + if (!pdc2027x_port_enabled(ap)) + return -ENOENT; pdc2027x_cbl_detect(ap); return ata_std_prereset(ap); } diff --git a/drivers/ata/pata_sis.c b/drivers/ata/pata_sis.c index 2e555168b431..fce74d9b2e67 100644 --- a/drivers/ata/pata_sis.c +++ b/drivers/ata/pata_sis.c @@ -34,7 +34,7 @@ #include #define DRV_NAME "pata_sis" -#define DRV_VERSION "0.4.3" +#define DRV_VERSION "0.4.4" struct sis_chipset { u16 device; /* PCI host ID */ @@ -74,11 +74,9 @@ static int sis_133_pre_reset(struct ata_port *ap) struct pci_dev *pdev = to_pci_dev(ap->host->dev); u16 tmp; - if (!pci_test_config_bits(pdev, &sis_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, &sis_enable_bits[ap->port_no])) + return -ENOENT; + /* The top bit of this register is the cable detect bit */ pci_read_config_word(pdev, 0x50 + 2 * ap->port_no, &tmp); if (tmp & 0x8000) diff --git a/drivers/ata/pata_sl82c105.c b/drivers/ata/pata_sl82c105.c index f8499786917a..b3bc607f0293 100644 --- a/drivers/ata/pata_sl82c105.c +++ b/drivers/ata/pata_sl82c105.c @@ -19,7 +19,7 @@ #include #define DRV_NAME "pata_sl82c105" -#define DRV_VERSION "0.2.2" +#define DRV_VERSION "0.2.3" enum { /* @@ -49,11 +49,8 @@ static int sl82c105_pre_reset(struct ata_port *ap) }; struct pci_dev *pdev = to_pci_dev(ap->host->dev); - if (ap->port_no && !pci_test_config_bits(pdev, &sl82c105_enable_bits[ap->port_no])) { - ata_port_disable(ap); - dev_printk(KERN_INFO, &pdev->dev, "port disabled. ignoring.\n"); - return 0; - } + if (ap->port_no && !pci_test_config_bits(pdev, &sl82c105_enable_bits[ap->port_no])) + return -ENOENT; ap->cbl = ATA_CBL_PATA40; return ata_std_prereset(ap); } diff --git a/drivers/ata/pata_triflex.c b/drivers/ata/pata_triflex.c index 36f788728f3f..95adf92901fc 100644 --- a/drivers/ata/pata_triflex.c +++ b/drivers/ata/pata_triflex.c @@ -46,13 +46,13 @@ #define DRV_VERSION "0.2.5" /** - * triflex_probe_init - probe begin + * triflex_prereset - probe begin * @ap: ATA port * * Set up cable type and use generic probe init */ -static int triflex_probe_init(struct ata_port *ap) +static int triflex_prereset(struct ata_port *ap) { static const struct pci_bits triflex_enable_bits[] = { { 0x80, 1, 0x01, 0x01 }, @@ -61,11 +61,8 @@ static int triflex_probe_init(struct ata_port *ap) struct pci_dev *pdev = to_pci_dev(ap->host->dev); - if (!pci_test_config_bits(pdev, &triflex_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, &triflex_enable_bits[ap->port_no])) + return -ENOENT; ap->cbl = ATA_CBL_PATA40; return ata_std_prereset(ap); } @@ -74,7 +71,7 @@ static int triflex_probe_init(struct ata_port *ap) static void triflex_error_handler(struct ata_port *ap) { - ata_bmdma_drive_eh(ap, triflex_probe_init, ata_std_softreset, NULL, ata_std_postreset); + ata_bmdma_drive_eh(ap, triflex_prereset, ata_std_softreset, NULL, ata_std_postreset); } /** diff --git a/drivers/ata/pata_via.c b/drivers/ata/pata_via.c index 1b2ff133b163..0e8b1303acd6 100644 --- a/drivers/ata/pata_via.c +++ b/drivers/ata/pata_via.c @@ -60,7 +60,7 @@ #include #define DRV_NAME "pata_via" -#define DRV_VERSION "0.1.13" +#define DRV_VERSION "0.1.14" /* * The following comes directly from Vojtech Pavlik's ide/pci/via82cxxx @@ -155,11 +155,8 @@ static int via_pre_reset(struct ata_port *ap) struct pci_dev *pdev = to_pci_dev(ap->host->dev); - if (!pci_test_config_bits(pdev, &via_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, &via_enable_bits[ap->port_no])) + return -ENOENT; } if ((config->flags & VIA_UDMA) >= VIA_UDMA_66) From daac0acd597618b99bba5f8fff31f21e4f283154 Mon Sep 17 00:00:00 2001 From: Alan Cox Date: Tue, 26 Sep 2006 17:55:37 +0100 Subject: [PATCH 4/9] [PATCH] libata-sff: use our IRQ defines Signed-off-by: Alan Cox Signed-off-by: Jeff Garzik --- drivers/ata/libata-sff.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/ata/libata-sff.c b/drivers/ata/libata-sff.c index 688bb55e197a..9222b6bb010a 100644 --- a/drivers/ata/libata-sff.c +++ b/drivers/ata/libata-sff.c @@ -881,7 +881,7 @@ static struct ata_probe_ent *ata_pci_init_legacy_port(struct pci_dev *pdev, probe_ent->private_data = port[0]->private_data; if (port_mask & ATA_PORT_PRIMARY) { - probe_ent->irq = 14; + probe_ent->irq = ATA_PRIMARY_IRQ; probe_ent->port[0].cmd_addr = ATA_PRIMARY_CMD; probe_ent->port[0].altstatus_addr = probe_ent->port[0].ctl_addr = ATA_PRIMARY_CTL; @@ -896,7 +896,7 @@ static struct ata_probe_ent *ata_pci_init_legacy_port(struct pci_dev *pdev, if (port_mask & ATA_PORT_SECONDARY) { if (probe_ent->irq) - probe_ent->irq2 = 15; + probe_ent->irq2 = ATA_SECONDARY_IRQ; else probe_ent->irq = 15; probe_ent->port[1].cmd_addr = ATA_SECONDARY_CMD; From 68d0d7abcc4cfcf0a1eeb49785cb32ec05473e42 Mon Sep 17 00:00:00 2001 From: Alan Cox Date: Tue, 26 Sep 2006 22:24:31 +0100 Subject: [PATCH 5/9] [PATCH] pata_serverworks: correct PCI ID in cable detection table Signed-off-by: Alan Cox Signed-off-by: Jeff Garzik --- drivers/ata/pata_serverworks.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/ata/pata_serverworks.c b/drivers/ata/pata_serverworks.c index af456113c55d..75cc5a22da0c 100644 --- a/drivers/ata/pata_serverworks.c +++ b/drivers/ata/pata_serverworks.c @@ -41,7 +41,7 @@ #include #define DRV_NAME "pata_serverworks" -#define DRV_VERSION "0.3.6" +#define DRV_VERSION "0.3.7" #define SVWKS_CSB5_REVISION_NEW 0x92 /* min PCI_REVISION_ID for UDMA5 (A2.0) */ #define SVWKS_CSB6_REVISION 0xa0 /* min PCI_REVISION_ID for UDMA4 (A1.0) */ @@ -128,7 +128,7 @@ static struct sv_cable_table cable_detect[] = { { PCI_DEVICE_ID_SERVERWORKS_CSB5IDE, PCI_VENDOR_ID_DELL, dell_cable }, { PCI_DEVICE_ID_SERVERWORKS_CSB6IDE, PCI_VENDOR_ID_DELL, dell_cable }, { PCI_DEVICE_ID_SERVERWORKS_CSB5IDE, PCI_VENDOR_ID_SUN, sun_cable }, - { PCI_DEVICE_ID_SERVERWORKS_OSB4, PCI_ANY_ID, osb4_cable }, + { PCI_DEVICE_ID_SERVERWORKS_OSB4IDE, PCI_ANY_ID, osb4_cable }, { PCI_DEVICE_ID_SERVERWORKS_CSB5IDE, PCI_ANY_ID, csb_cable }, { PCI_DEVICE_ID_SERVERWORKS_CSB6IDE, PCI_ANY_ID, csb_cable }, { PCI_DEVICE_ID_SERVERWORKS_CSB6IDE2, PCI_ANY_ID, csb_cable }, From efbf3f14204b77e6afc8c13571357173de9ab707 Mon Sep 17 00:00:00 2001 From: Jeff Garzik Date: Tue, 26 Sep 2006 17:10:53 -0400 Subject: [PATCH 6/9] [libata] pata_serverworks: fill in ->irq_clear hook Required by libata, as it is called unconditionally. Fixes an obvious oops. Signed-off-by: Jeff Garzik --- drivers/ata/pata_serverworks.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/ata/pata_serverworks.c b/drivers/ata/pata_serverworks.c index 75cc5a22da0c..d62051b8da05 100644 --- a/drivers/ata/pata_serverworks.c +++ b/drivers/ata/pata_serverworks.c @@ -356,6 +356,8 @@ static struct ata_port_operations serverworks_osb4_port_ops = { .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, + .irq_clear = ata_bmdma_irq_clear, + .port_start = ata_port_start, .port_stop = ata_port_stop, .host_stop = ata_host_stop @@ -389,6 +391,8 @@ static struct ata_port_operations serverworks_csb_port_ops = { .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, + .irq_clear = ata_bmdma_irq_clear, + .port_start = ata_port_start, .port_stop = ata_port_stop, .host_stop = ata_host_stop From fb4633019fd0a871cdf315e1f4082f4c6926af82 Mon Sep 17 00:00:00 2001 From: Jeff Garzik Date: Tue, 26 Sep 2006 17:16:32 -0400 Subject: [PATCH 7/9] [libata] One more s/15/ATA_SECONDARY_IRQ/ substitution Signed-off-by: Jeff Garzik --- drivers/ata/libata-sff.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/ata/libata-sff.c b/drivers/ata/libata-sff.c index 9222b6bb010a..08b3a407473e 100644 --- a/drivers/ata/libata-sff.c +++ b/drivers/ata/libata-sff.c @@ -898,7 +898,7 @@ static struct ata_probe_ent *ata_pci_init_legacy_port(struct pci_dev *pdev, if (probe_ent->irq) probe_ent->irq2 = ATA_SECONDARY_IRQ; else - probe_ent->irq = 15; + probe_ent->irq = ATA_SECONDARY_IRQ; probe_ent->port[1].cmd_addr = ATA_SECONDARY_CMD; probe_ent->port[1].altstatus_addr = probe_ent->port[1].ctl_addr = ATA_SECONDARY_CTL; From ae1f19aeb715098ac06323f279383f3843429d97 Mon Sep 17 00:00:00 2001 From: Jeff Garzik Date: Wed, 27 Sep 2006 03:42:37 -0400 Subject: [PATCH 8/9] [libata] sata_mv: fix oops by filling in missing hook Only two of three ata_port_operations structs had a ->data_xfer member, which led to, uh, a lack of data xfer. Signed-off-by: Jeff Garzik --- drivers/ata/sata_mv.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/ata/sata_mv.c b/drivers/ata/sata_mv.c index fdce6e07ecd2..c01496df4a99 100644 --- a/drivers/ata/sata_mv.c +++ b/drivers/ata/sata_mv.c @@ -463,6 +463,7 @@ static const struct ata_port_operations mv_iie_ops = { .qc_prep = mv_qc_prep_iie, .qc_issue = mv_qc_issue, + .data_xfer = ata_mmio_data_xfer, .eng_timeout = mv_eng_timeout, From bda3028813bd07f34f30288a492fbf6f7b8712dd Mon Sep 17 00:00:00 2001 From: Jeff Garzik Date: Wed, 27 Sep 2006 05:41:13 -0400 Subject: [PATCH 9/9] [libata] Don't use old-EH ->eng_timeout() hook when not needed The PATA driver set got converted to the new error handling setup, but the old hooks were accidentally left in place. Now, removed. Signed-off-by: Jeff Garzik --- drivers/ata/ata_generic.c | 2 +- drivers/ata/pata_ali.c | 8 ++++---- drivers/ata/pata_amd.c | 12 ++++++------ drivers/ata/pata_artop.c | 4 +--- drivers/ata/pata_atiixp.c | 2 +- drivers/ata/pata_cmd64x.c | 6 +++--- drivers/ata/pata_cs5520.c | 2 -- drivers/ata/pata_cs5530.c | 2 +- drivers/ata/pata_cs5535.c | 2 +- drivers/ata/pata_cypress.c | 2 +- drivers/ata/pata_efar.c | 2 -- drivers/ata/pata_hpt366.c | 2 +- drivers/ata/pata_hpt37x.c | 8 ++++---- drivers/ata/pata_hpt3x2n.c | 2 +- drivers/ata/pata_hpt3x3.c | 2 +- drivers/ata/pata_isapnp.c | 2 +- drivers/ata/pata_it821x.c | 4 ++-- drivers/ata/pata_jmicron.c | 3 +-- drivers/ata/pata_legacy.c | 14 +++++++------- drivers/ata/pata_netcell.c | 3 +-- drivers/ata/pata_ns87410.c | 2 +- drivers/ata/pata_opti.c | 2 +- drivers/ata/pata_optidma.c | 4 ++-- drivers/ata/pata_pcmcia.c | 2 +- drivers/ata/pata_qdi.c | 4 ++-- drivers/ata/pata_radisys.c | 2 -- drivers/ata/pata_rz1000.c | 2 +- drivers/ata/pata_sc1200.c | 2 +- drivers/ata/pata_serverworks.c | 4 ++-- drivers/ata/pata_sil680.c | 2 +- drivers/ata/pata_sis.c | 10 ---------- drivers/ata/pata_sl82c105.c | 2 +- drivers/ata/pata_triflex.c | 2 +- drivers/ata/pata_via.c | 4 ++-- 34 files changed, 54 insertions(+), 74 deletions(-) diff --git a/drivers/ata/ata_generic.c b/drivers/ata/ata_generic.c index 1d1c30a2fcd0..377425e71391 100644 --- a/drivers/ata/ata_generic.c +++ b/drivers/ata/ata_generic.c @@ -143,7 +143,7 @@ static struct ata_port_operations generic_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .irq_handler = ata_interrupt, .irq_clear = ata_bmdma_irq_clear, diff --git a/drivers/ata/pata_ali.c b/drivers/ata/pata_ali.c index 8448ee6e0eed..87af3b5861ab 100644 --- a/drivers/ata/pata_ali.c +++ b/drivers/ata/pata_ali.c @@ -369,7 +369,7 @@ static struct ata_port_operations ali_early_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -410,7 +410,7 @@ static struct ata_port_operations ali_20_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -448,7 +448,7 @@ static struct ata_port_operations ali_c2_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -485,7 +485,7 @@ static struct ata_port_operations ali_c5_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_amd.c b/drivers/ata/pata_amd.c index 793a5e1cb4cb..599ee266722c 100644 --- a/drivers/ata/pata_amd.c +++ b/drivers/ata/pata_amd.c @@ -359,7 +359,7 @@ static struct ata_port_operations amd33_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -393,7 +393,7 @@ static struct ata_port_operations amd66_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -427,7 +427,7 @@ static struct ata_port_operations amd100_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -461,7 +461,7 @@ static struct ata_port_operations amd133_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -495,7 +495,7 @@ static struct ata_port_operations nv100_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -529,7 +529,7 @@ static struct ata_port_operations nv133_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_artop.c b/drivers/ata/pata_artop.c index 0f3b49176dc1..c4ccb75a4f1d 100644 --- a/drivers/ata/pata_artop.c +++ b/drivers/ata/pata_artop.c @@ -340,7 +340,7 @@ static const struct ata_port_operations artop6210_ops = { .bmdma_status = ata_bmdma_status, .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -375,8 +375,6 @@ static const struct ata_port_operations artop6260_ops = { .qc_issue = ata_qc_issue_prot, .data_xfer = ata_pio_data_xfer, - .eng_timeout = ata_eng_timeout, - .irq_handler = ata_interrupt, .irq_clear = ata_bmdma_irq_clear, diff --git a/drivers/ata/pata_atiixp.c b/drivers/ata/pata_atiixp.c index 060d019fd30b..6c2269b6bd3c 100644 --- a/drivers/ata/pata_atiixp.c +++ b/drivers/ata/pata_atiixp.c @@ -242,7 +242,7 @@ static struct ata_port_operations atiixp_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_cmd64x.c b/drivers/ata/pata_cmd64x.c index abf1bb7bd322..e92b0ef43ec5 100644 --- a/drivers/ata/pata_cmd64x.c +++ b/drivers/ata/pata_cmd64x.c @@ -301,7 +301,7 @@ static struct ata_port_operations cmd64x_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -335,7 +335,7 @@ static struct ata_port_operations cmd646r1_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -369,7 +369,7 @@ static struct ata_port_operations cmd648_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_cs5520.c b/drivers/ata/pata_cs5520.c index 792ce4828510..a6c6cebd0dae 100644 --- a/drivers/ata/pata_cs5520.c +++ b/drivers/ata/pata_cs5520.c @@ -193,8 +193,6 @@ static struct ata_port_operations cs5520_port_ops = { .qc_issue = ata_qc_issue_prot, .data_xfer = ata_pio_data_xfer, - .eng_timeout = ata_eng_timeout, - .irq_handler = ata_interrupt, .irq_clear = ata_bmdma_irq_clear, diff --git a/drivers/ata/pata_cs5530.c b/drivers/ata/pata_cs5530.c index f3d8a3bc1e78..7bba4d954e9c 100644 --- a/drivers/ata/pata_cs5530.c +++ b/drivers/ata/pata_cs5530.c @@ -207,7 +207,7 @@ static struct ata_port_operations cs5530_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = cs5530_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_cs5535.c b/drivers/ata/pata_cs5535.c index 69d6b4258724..d64fcdceaf01 100644 --- a/drivers/ata/pata_cs5535.c +++ b/drivers/ata/pata_cs5535.c @@ -211,7 +211,7 @@ static struct ata_port_operations cs5535_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_cypress.c b/drivers/ata/pata_cypress.c index fd55474e0d15..dfa5ac539048 100644 --- a/drivers/ata/pata_cypress.c +++ b/drivers/ata/pata_cypress.c @@ -162,7 +162,7 @@ static struct ata_port_operations cy82c693_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_efar.c b/drivers/ata/pata_efar.c index 92813827faa7..95cd1ca181f5 100644 --- a/drivers/ata/pata_efar.c +++ b/drivers/ata/pata_efar.c @@ -261,8 +261,6 @@ static const struct ata_port_operations efar_ops = { .qc_issue = ata_qc_issue_prot, .data_xfer = ata_pio_data_xfer, - .eng_timeout = ata_eng_timeout, - .irq_handler = ata_interrupt, .irq_clear = ata_bmdma_irq_clear, diff --git a/drivers/ata/pata_hpt366.c b/drivers/ata/pata_hpt366.c index 94bb1dfc3f19..cf656ecbe507 100644 --- a/drivers/ata/pata_hpt366.c +++ b/drivers/ata/pata_hpt366.c @@ -360,7 +360,7 @@ static struct ata_port_operations hpt366_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_hpt37x.c b/drivers/ata/pata_hpt37x.c index 532a7928f803..10318c0012ef 100644 --- a/drivers/ata/pata_hpt37x.c +++ b/drivers/ata/pata_hpt37x.c @@ -793,7 +793,7 @@ static struct ata_port_operations hpt370_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -832,7 +832,7 @@ static struct ata_port_operations hpt370a_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -872,7 +872,7 @@ static struct ata_port_operations hpt372_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -912,7 +912,7 @@ static struct ata_port_operations hpt374_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_hpt3x2n.c b/drivers/ata/pata_hpt3x2n.c index 06c8db079b91..5c5d4f6ab901 100644 --- a/drivers/ata/pata_hpt3x2n.c +++ b/drivers/ata/pata_hpt3x2n.c @@ -372,7 +372,7 @@ static struct ata_port_operations hpt3x2n_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = hpt3x2n_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_hpt3x3.c b/drivers/ata/pata_hpt3x3.c index 152770133ab1..1f084ab1ccc6 100644 --- a/drivers/ata/pata_hpt3x3.c +++ b/drivers/ata/pata_hpt3x3.c @@ -145,7 +145,7 @@ static struct ata_port_operations hpt3x3_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_isapnp.c b/drivers/ata/pata_isapnp.c index 73948c8b7270..640b8b0954f5 100644 --- a/drivers/ata/pata_isapnp.c +++ b/drivers/ata/pata_isapnp.c @@ -52,7 +52,7 @@ static struct ata_port_operations isapnp_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_it821x.c b/drivers/ata/pata_it821x.c index af39097d8081..82a46ff40000 100644 --- a/drivers/ata/pata_it821x.c +++ b/drivers/ata/pata_it821x.c @@ -703,7 +703,7 @@ static struct ata_port_operations it821x_smart_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = it821x_smart_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -739,7 +739,7 @@ static struct ata_port_operations it821x_passthru_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = it821x_passthru_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_clear = ata_bmdma_irq_clear, diff --git a/drivers/ata/pata_jmicron.c b/drivers/ata/pata_jmicron.c index 3bdb6f2fa5ba..be3a866b111f 100644 --- a/drivers/ata/pata_jmicron.c +++ b/drivers/ata/pata_jmicron.c @@ -164,8 +164,7 @@ static const struct ata_port_operations jmicron_ops = { .qc_issue = ata_qc_issue_prot, .data_xfer = ata_pio_data_xfer, - /* Timeout handling. Special recovery hooks here */ - .eng_timeout = ata_eng_timeout, + /* IRQ-related hooks */ .irq_handler = ata_interrupt, .irq_clear = ata_bmdma_irq_clear, diff --git a/drivers/ata/pata_legacy.c b/drivers/ata/pata_legacy.c index ad37c220bb2c..10231ef731d1 100644 --- a/drivers/ata/pata_legacy.c +++ b/drivers/ata/pata_legacy.c @@ -161,7 +161,7 @@ static struct ata_port_operations simple_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer_noirq, .irq_handler = ata_interrupt, @@ -186,7 +186,7 @@ static struct ata_port_operations legacy_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer_noirq, .irq_handler = ata_interrupt, @@ -296,7 +296,7 @@ static struct ata_port_operations pdc20230_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = pdc_data_xfer_vlb, .irq_handler = ata_interrupt, @@ -348,7 +348,7 @@ static struct ata_port_operations ht6560a_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, /* Check vlb/noirq */ .irq_handler = ata_interrupt, @@ -411,7 +411,7 @@ static struct ata_port_operations ht6560b_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, /* FIXME: Check 32bit and noirq */ .irq_handler = ata_interrupt, @@ -529,7 +529,7 @@ static struct ata_port_operations opti82c611a_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -659,7 +659,7 @@ static struct ata_port_operations opti82c46x_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = opti82c46x_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_netcell.c b/drivers/ata/pata_netcell.c index 16cb254cb973..76eb9c90bee1 100644 --- a/drivers/ata/pata_netcell.c +++ b/drivers/ata/pata_netcell.c @@ -90,8 +90,7 @@ static const struct ata_port_operations netcell_ops = { .qc_issue = ata_qc_issue_prot, .data_xfer = ata_pio_data_xfer, - /* Timeout handling. Special recovery hooks here */ - .eng_timeout = ata_eng_timeout, + /* IRQ-related hooks */ .irq_handler = ata_interrupt, .irq_clear = ata_bmdma_irq_clear, diff --git a/drivers/ata/pata_ns87410.c b/drivers/ata/pata_ns87410.c index f529fe4c29b7..2005a95f48f6 100644 --- a/drivers/ata/pata_ns87410.c +++ b/drivers/ata/pata_ns87410.c @@ -176,7 +176,7 @@ static struct ata_port_operations ns87410_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ns87410_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_opti.c b/drivers/ata/pata_opti.c index 136d7a65feb3..57fe21f3a975 100644 --- a/drivers/ata/pata_opti.c +++ b/drivers/ata/pata_opti.c @@ -227,7 +227,7 @@ static struct ata_port_operations opti_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_optidma.c b/drivers/ata/pata_optidma.c index 18ec8e72bbb6..7296a20cd107 100644 --- a/drivers/ata/pata_optidma.c +++ b/drivers/ata/pata_optidma.c @@ -386,7 +386,7 @@ static struct ata_port_operations optidma_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -421,7 +421,7 @@ static struct ata_port_operations optiplus_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_pcmcia.c b/drivers/ata/pata_pcmcia.c index 62b25cda409b..cb501e145a42 100644 --- a/drivers/ata/pata_pcmcia.c +++ b/drivers/ata/pata_pcmcia.c @@ -87,7 +87,7 @@ static struct ata_port_operations pcmcia_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer_noirq, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_qdi.c b/drivers/ata/pata_qdi.c index 35cfdf0ac3f0..7977f471d5e9 100644 --- a/drivers/ata/pata_qdi.c +++ b/drivers/ata/pata_qdi.c @@ -184,7 +184,7 @@ static struct ata_port_operations qdi6500_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = qdi_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = qdi_data_xfer, .irq_handler = ata_interrupt, @@ -212,7 +212,7 @@ static struct ata_port_operations qdi6580_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = qdi_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = qdi_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_radisys.c b/drivers/ata/pata_radisys.c index 277f8411b521..c20bcf43ed6d 100644 --- a/drivers/ata/pata_radisys.c +++ b/drivers/ata/pata_radisys.c @@ -255,8 +255,6 @@ static const struct ata_port_operations radisys_pata_ops = { .qc_issue = radisys_qc_issue_prot, .data_xfer = ata_pio_data_xfer, - .eng_timeout = ata_eng_timeout, - .irq_handler = ata_interrupt, .irq_clear = ata_bmdma_irq_clear, diff --git a/drivers/ata/pata_rz1000.c b/drivers/ata/pata_rz1000.c index 3c6d84fd4312..eccc6fd45032 100644 --- a/drivers/ata/pata_rz1000.c +++ b/drivers/ata/pata_rz1000.c @@ -112,7 +112,7 @@ static struct ata_port_operations rz1000_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .freeze = ata_bmdma_freeze, diff --git a/drivers/ata/pata_sc1200.c b/drivers/ata/pata_sc1200.c index 4166c1a8a9e8..107e6cd3dc0d 100644 --- a/drivers/ata/pata_sc1200.c +++ b/drivers/ata/pata_sc1200.c @@ -217,7 +217,7 @@ static struct ata_port_operations sc1200_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = sc1200_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_serverworks.c b/drivers/ata/pata_serverworks.c index d62051b8da05..a5c8d7e121d1 100644 --- a/drivers/ata/pata_serverworks.c +++ b/drivers/ata/pata_serverworks.c @@ -352,7 +352,7 @@ static struct ata_port_operations serverworks_osb4_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -387,7 +387,7 @@ static struct ata_port_operations serverworks_csb_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_sil680.c b/drivers/ata/pata_sil680.c index 8f7db9638d0a..c8b2e26db70d 100644 --- a/drivers/ata/pata_sil680.c +++ b/drivers/ata/pata_sil680.c @@ -251,7 +251,7 @@ static struct ata_port_operations sil680_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_sis.c b/drivers/ata/pata_sis.c index fce74d9b2e67..17791e2785f9 100644 --- a/drivers/ata/pata_sis.c +++ b/drivers/ata/pata_sis.c @@ -573,8 +573,6 @@ static const struct ata_port_operations sis_133_ops = { .qc_issue = ata_qc_issue_prot, .data_xfer = ata_pio_data_xfer, - .eng_timeout = ata_eng_timeout, - .irq_handler = ata_interrupt, .irq_clear = ata_bmdma_irq_clear, @@ -608,8 +606,6 @@ static const struct ata_port_operations sis_133_early_ops = { .qc_issue = ata_qc_issue_prot, .data_xfer = ata_pio_data_xfer, - .eng_timeout = ata_eng_timeout, - .irq_handler = ata_interrupt, .irq_clear = ata_bmdma_irq_clear, @@ -644,8 +640,6 @@ static const struct ata_port_operations sis_100_ops = { .qc_issue = ata_qc_issue_prot, .data_xfer = ata_pio_data_xfer, - .eng_timeout = ata_eng_timeout, - .irq_handler = ata_interrupt, .irq_clear = ata_bmdma_irq_clear, @@ -679,8 +673,6 @@ static const struct ata_port_operations sis_66_ops = { .qc_issue = ata_qc_issue_prot, .data_xfer = ata_pio_data_xfer, - .eng_timeout = ata_eng_timeout, - .irq_handler = ata_interrupt, .irq_clear = ata_bmdma_irq_clear, @@ -714,8 +706,6 @@ static const struct ata_port_operations sis_old_ops = { .qc_issue = ata_qc_issue_prot, .data_xfer = ata_pio_data_xfer, - .eng_timeout = ata_eng_timeout, - .irq_handler = ata_interrupt, .irq_clear = ata_bmdma_irq_clear, diff --git a/drivers/ata/pata_sl82c105.c b/drivers/ata/pata_sl82c105.c index b3bc607f0293..5b762acc5687 100644 --- a/drivers/ata/pata_sl82c105.c +++ b/drivers/ata/pata_sl82c105.c @@ -261,7 +261,7 @@ static struct ata_port_operations sl82c105_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_triflex.c b/drivers/ata/pata_triflex.c index 95adf92901fc..a954ed93a40c 100644 --- a/drivers/ata/pata_triflex.c +++ b/drivers/ata/pata_triflex.c @@ -218,7 +218,7 @@ static struct ata_port_operations triflex_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, diff --git a/drivers/ata/pata_via.c b/drivers/ata/pata_via.c index 0e8b1303acd6..7b5dd2343b9a 100644 --- a/drivers/ata/pata_via.c +++ b/drivers/ata/pata_via.c @@ -322,7 +322,7 @@ static struct ata_port_operations via_port_ops = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer, .irq_handler = ata_interrupt, @@ -357,7 +357,7 @@ static struct ata_port_operations via_port_ops_noirq = { .qc_prep = ata_qc_prep, .qc_issue = ata_qc_issue_prot, - .eng_timeout = ata_eng_timeout, + .data_xfer = ata_pio_data_xfer_noirq, .irq_handler = ata_interrupt,