aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/alim15x3.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ide/alim15x3.c')
-rw-r--r--drivers/ide/alim15x3.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/ide/alim15x3.c b/drivers/ide/alim15x3.c
index 45d2356bb725..66f43083408b 100644
--- a/drivers/ide/alim15x3.c
+++ b/drivers/ide/alim15x3.c
@@ -68,7 +68,7 @@ static struct pci_dev *isa_dev;
68 68
69static void ali_set_pio_mode(ide_drive_t *drive, const u8 pio) 69static void ali_set_pio_mode(ide_drive_t *drive, const u8 pio)
70{ 70{
71 ide_hwif_t *hwif = HWIF(drive); 71 ide_hwif_t *hwif = drive->hwif;
72 struct pci_dev *dev = to_pci_dev(hwif->dev); 72 struct pci_dev *dev = to_pci_dev(hwif->dev);
73 struct ide_timing *t = ide_timing_find_mode(XFER_PIO_0 + pio); 73 struct ide_timing *t = ide_timing_find_mode(XFER_PIO_0 + pio);
74 int s_time = t->setup, a_time = t->active, c_time = t->cycle; 74 int s_time = t->setup, a_time = t->active, c_time = t->cycle;
@@ -150,7 +150,7 @@ static u8 ali_udma_filter(ide_drive_t *drive)
150 150
151static void ali_set_dma_mode(ide_drive_t *drive, const u8 speed) 151static void ali_set_dma_mode(ide_drive_t *drive, const u8 speed)
152{ 152{
153 ide_hwif_t *hwif = HWIF(drive); 153 ide_hwif_t *hwif = drive->hwif;
154 struct pci_dev *dev = to_pci_dev(hwif->dev); 154 struct pci_dev *dev = to_pci_dev(hwif->dev);
155 u8 speed1 = speed; 155 u8 speed1 = speed;
156 u8 unit = drive->dn & 1; 156 u8 unit = drive->dn & 1;
@@ -198,7 +198,7 @@ static void ali_set_dma_mode(ide_drive_t *drive, const u8 speed)
198static int ali15x3_dma_setup(ide_drive_t *drive) 198static int ali15x3_dma_setup(ide_drive_t *drive)
199{ 199{
200 if (m5229_revision < 0xC2 && drive->media != ide_disk) { 200 if (m5229_revision < 0xC2 && drive->media != ide_disk) {
201 if (rq_data_dir(drive->hwif->hwgroup->rq)) 201 if (rq_data_dir(drive->hwif->rq))
202 return 1; /* try PIO instead of DMA */ 202 return 1; /* try PIO instead of DMA */
203 } 203 }
204 return ide_dma_setup(drive); 204 return ide_dma_setup(drive);
@@ -490,8 +490,6 @@ static int __devinit init_dma_ali15x3(ide_hwif_t *hwif,
490 if (ide_allocate_dma_engine(hwif)) 490 if (ide_allocate_dma_engine(hwif))
491 return -1; 491 return -1;
492 492
493 hwif->dma_ops = &sff_dma_ops;
494
495 return 0; 493 return 0;
496} 494}
497 495
@@ -511,6 +509,7 @@ static const struct ide_dma_ops ali_dma_ops = {
511 .dma_test_irq = ide_dma_test_irq, 509 .dma_test_irq = ide_dma_test_irq,
512 .dma_lost_irq = ide_dma_lost_irq, 510 .dma_lost_irq = ide_dma_lost_irq,
513 .dma_timeout = ide_dma_timeout, 511 .dma_timeout = ide_dma_timeout,
512 .dma_sff_read_status = ide_dma_sff_read_status,
514}; 513};
515 514
516static const struct ide_port_info ali15x3_chipset __devinitdata = { 515static const struct ide_port_info ali15x3_chipset __devinitdata = {
@@ -519,6 +518,7 @@ static const struct ide_port_info ali15x3_chipset __devinitdata = {
519 .init_hwif = init_hwif_ali15x3, 518 .init_hwif = init_hwif_ali15x3,
520 .init_dma = init_dma_ali15x3, 519 .init_dma = init_dma_ali15x3,
521 .port_ops = &ali_port_ops, 520 .port_ops = &ali_port_ops,
521 .dma_ops = &sff_dma_ops,
522 .pio_mask = ATA_PIO5, 522 .pio_mask = ATA_PIO5,
523 .swdma_mask = ATA_SWDMA2, 523 .swdma_mask = ATA_SWDMA2,
524 .mwdma_mask = ATA_MWDMA2, 524 .mwdma_mask = ATA_MWDMA2,