summaryrefslogtreecommitdiffstats
path: root/drivers/ide/opti621.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ide/opti621.c')
-rw-r--r--drivers/ide/opti621.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/ide/opti621.c b/drivers/ide/opti621.c
index 2052788fab7..1a53a4c375e 100644
--- a/drivers/ide/opti621.c
+++ b/drivers/ide/opti621.c
@@ -62,12 +62,12 @@ static u8 read_reg(int reg)
return ret;
}
-static void opti621_set_pio_mode(ide_drive_t *drive, const u8 pio)
+static void opti621_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive)
{
- ide_hwif_t *hwif = drive->hwif;
ide_drive_t *pair = ide_get_pair_dev(drive);
unsigned long flags;
- unsigned long mode = XFER_PIO_0 + pio, pair_mode;
+ unsigned long mode = drive->pio_mode, pair_mode;
+ const u8 pio = mode - XFER_PIO_0;
u8 tim, misc, addr_pio = pio, clk;
/* DRDY is default 2 (by OPTi Databook) */