[libata] MWDMA0 is unsupported on PIIX-like PATA controllers
[safe/jmp/linux-2.6] / drivers / ata / sata_vsc.c
index c57cdff..8b2a278 100644 (file)
@@ -308,6 +308,9 @@ static struct scsi_host_template vsc_sata_sht = {
 
 static struct ata_port_operations vsc_sata_ops = {
        .inherits               = &ata_bmdma_port_ops,
+       /* The IRQ handling is not quite standard SFF behaviour so we
+          cannot use the default lost interrupt handler */
+       .lost_interrupt         = ATA_OP_NULL,
        .sff_tf_load            = vsc_sata_tf_load,
        .sff_tf_read            = vsc_sata_tf_read,
        .freeze                 = vsc_freeze,
@@ -345,8 +348,8 @@ static int __devinit vsc_sata_init_one(struct pci_dev *pdev,
        static const struct ata_port_info pi = {
                .flags          = ATA_FLAG_SATA | ATA_FLAG_NO_LEGACY |
                                  ATA_FLAG_MMIO,
-               .pio_mask       = 0x1f,
-               .mwdma_mask     = 0x07,
+               .pio_mask       = ATA_PIO4,
+               .mwdma_mask     = ATA_MWDMA2,
                .udma_mask      = ATA_UDMA6,
                .port_ops       = &vsc_sata_ops,
        };
@@ -396,10 +399,10 @@ static int __devinit vsc_sata_init_one(struct pci_dev *pdev,
        /*
         * Use 32 bit DMA mask, because 64 bit address support is poor.
         */
-       rc = pci_set_dma_mask(pdev, DMA_32BIT_MASK);
+       rc = pci_set_dma_mask(pdev, DMA_BIT_MASK(32));
        if (rc)
                return rc;
-       rc = pci_set_consistent_dma_mask(pdev, DMA_32BIT_MASK);
+       rc = pci_set_consistent_dma_mask(pdev, DMA_BIT_MASK(32));
        if (rc)
                return rc;