libata-sff: ap->[last_]ctl are SFF specific
[safe/jmp/linux-2.6] / drivers / ata / sata_promise.c
index 07d8d00..e80628a 100644 (file)
@@ -33,6 +33,7 @@
 
 #include <linux/kernel.h>
 #include <linux/module.h>
+#include <linux/gfp.h>
 #include <linux/pci.h>
 #include <linux/init.h>
 #include <linux/blkdev.h>
@@ -332,7 +333,8 @@ static int pdc_common_port_start(struct ata_port *ap)
        struct pdc_port_priv *pp;
        int rc;
 
-       rc = ata_port_start(ap);
+       /* we use the same prd table as bmdma, allocate it */
+       rc = ata_bmdma_port_start(ap);
        if (rc)
                return rc;
 
@@ -862,7 +864,7 @@ static void pdc_error_intr(struct ata_port *ap, struct ata_queued_cmd *qc,
        if (port_status & PDC_DRIVE_ERR)
                ac_err_mask |= AC_ERR_DEV;
        if (port_status & (PDC_OVERRUN_ERR | PDC_UNDERRUN_ERR))
-               ac_err_mask |= AC_ERR_HSM;
+               ac_err_mask |= AC_ERR_OTHER;
        if (port_status & (PDC2_ATA_HBA_ERR | PDC2_ATA_DMA_CNT_ERR))
                ac_err_mask |= AC_ERR_ATA_BUS;
        if (port_status & (PDC_PH_ERR | PDC_SH_ERR | PDC_DH_ERR | PDC2_HTO_ERR
@@ -983,8 +985,7 @@ static irqreturn_t pdc_interrupt(int irq, void *dev_instance)
                /* check for a plug or unplug event */
                ata_no = pdc_port_no_to_ata_no(i, is_sataii_tx4);
                tmp = hotplug_status & (0x11 << ata_no);
-               if (tmp && ap &&
-                   !(ap->flags & ATA_FLAG_DISABLED)) {
+               if (tmp) {
                        struct ata_eh_info *ehi = &ap->link.eh_info;
                        ata_ehi_clear_desc(ehi);
                        ata_ehi_hotplugged(ehi);
@@ -996,8 +997,7 @@ static irqreturn_t pdc_interrupt(int irq, void *dev_instance)
 
                /* check for a packet interrupt */
                tmp = mask & (1 << (i + 1));
-               if (tmp && ap &&
-                   !(ap->flags & ATA_FLAG_DISABLED)) {
+               if (tmp) {
                        struct ata_queued_cmd *qc;
 
                        qc = ata_qc_from_tag(ap, ap->link.active_tag);