aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/hpt366.c
diff options
context:
space:
mode:
authorBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2010-01-19 04:45:29 -0500
committerDavid S. Miller <davem@davemloft.net>2010-01-19 04:45:29 -0500
commit8776168ca2151850164af1de5565d01f7b8b2c53 (patch)
tree28a44a3a649e1ab98f89674a06cc4c135a16d243 /drivers/ide/hpt366.c
parente085b3cae85af47eb0a3eda3186bd898310fb322 (diff)
ide: change ->set_dma_mode method parameters
Change ->set_dma_mode method parameters to match ->set_dmamode method used in struct ata_port_operations. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/hpt366.c')
-rw-r--r--drivers/ide/hpt366.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/ide/hpt366.c b/drivers/ide/hpt366.c
index f1dec519a9e6..b885c1d548f5 100644
--- a/drivers/ide/hpt366.c
+++ b/drivers/ide/hpt366.c
@@ -627,14 +627,14 @@ static u32 get_speed_setting(u8 speed, struct hpt_info *info)
627 return info->timings->clock_table[info->clock][i]; 627 return info->timings->clock_table[info->clock][i];
628} 628}
629 629
630static void hpt3xx_set_mode(ide_drive_t *drive, const u8 speed) 630static void hpt3xx_set_mode(ide_hwif_t *hwif, ide_drive_t *drive)
631{ 631{
632 ide_hwif_t *hwif = drive->hwif;
633 struct pci_dev *dev = to_pci_dev(hwif->dev); 632 struct pci_dev *dev = to_pci_dev(hwif->dev);
634 struct hpt_info *info = hpt3xx_get_info(hwif->dev); 633 struct hpt_info *info = hpt3xx_get_info(hwif->dev);
635 struct hpt_timings *t = info->timings; 634 struct hpt_timings *t = info->timings;
636 u8 itr_addr = 0x40 + (drive->dn * 4); 635 u8 itr_addr = 0x40 + (drive->dn * 4);
637 u32 old_itr = 0; 636 u32 old_itr = 0;
637 const u8 speed = drive->dma_mode;
638 u32 new_itr = get_speed_setting(speed, info); 638 u32 new_itr = get_speed_setting(speed, info);
639 u32 itr_mask = speed < XFER_MW_DMA_0 ? t->pio_mask : 639 u32 itr_mask = speed < XFER_MW_DMA_0 ? t->pio_mask :
640 (speed < XFER_UDMA_0 ? t->dma_mask : 640 (speed < XFER_UDMA_0 ? t->dma_mask :
@@ -653,7 +653,8 @@ static void hpt3xx_set_mode(ide_drive_t *drive, const u8 speed)
653 653
654static void hpt3xx_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive) 654static void hpt3xx_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive)
655{ 655{
656 hpt3xx_set_mode(drive, drive->pio_mode); 656 drive->dma_mode = drive->pio_mode;
657 hpt3xx_set_mode(hwif, drive);
657} 658}
658 659
659static void hpt3xx_maskproc(ide_drive_t *drive, int mask) 660static void hpt3xx_maskproc(ide_drive_t *drive, int mask)