ide: remove IDE_*_REG macros
[deliverable/linux.git] / drivers / ide / ide-taskfile.c
index 4c86a8d84b4ccd02d8567b6b00f51429e5f9c82a..155cc904f4eb056948745060c3e704d6a7698d29 100644 (file)
@@ -59,32 +59,34 @@ void ide_tf_load(ide_drive_t *drive, ide_task_t *task)
                SELECT_MASK(drive, 0);
 
        if (task->tf_flags & IDE_TFLAG_OUT_DATA)
-               hwif->OUTW((tf->hob_data << 8) | tf->data, IDE_DATA_REG);
+               hwif->OUTW((tf->hob_data << 8) | tf->data,
+                          hwif->io_ports[IDE_DATA_OFFSET]);
 
        if (task->tf_flags & IDE_TFLAG_OUT_HOB_FEATURE)
-               hwif->OUTB(tf->hob_feature, IDE_FEATURE_REG);
+               hwif->OUTB(tf->hob_feature, hwif->io_ports[IDE_FEATURE_OFFSET]);
        if (task->tf_flags & IDE_TFLAG_OUT_HOB_NSECT)
-               hwif->OUTB(tf->hob_nsect, IDE_NSECTOR_REG);
+               hwif->OUTB(tf->hob_nsect, hwif->io_ports[IDE_NSECTOR_OFFSET]);
        if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAL)
-               hwif->OUTB(tf->hob_lbal, IDE_SECTOR_REG);
+               hwif->OUTB(tf->hob_lbal, hwif->io_ports[IDE_SECTOR_OFFSET]);
        if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAM)
-               hwif->OUTB(tf->hob_lbam, IDE_LCYL_REG);
+               hwif->OUTB(tf->hob_lbam, hwif->io_ports[IDE_LCYL_OFFSET]);
        if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAH)
-               hwif->OUTB(tf->hob_lbah, IDE_HCYL_REG);
+               hwif->OUTB(tf->hob_lbah, hwif->io_ports[IDE_HCYL_OFFSET]);
 
        if (task->tf_flags & IDE_TFLAG_OUT_FEATURE)
-               hwif->OUTB(tf->feature, IDE_FEATURE_REG);
+               hwif->OUTB(tf->feature, hwif->io_ports[IDE_FEATURE_OFFSET]);
        if (task->tf_flags & IDE_TFLAG_OUT_NSECT)
-               hwif->OUTB(tf->nsect, IDE_NSECTOR_REG);
+               hwif->OUTB(tf->nsect, hwif->io_ports[IDE_NSECTOR_OFFSET]);
        if (task->tf_flags & IDE_TFLAG_OUT_LBAL)
-               hwif->OUTB(tf->lbal, IDE_SECTOR_REG);
+               hwif->OUTB(tf->lbal, hwif->io_ports[IDE_SECTOR_OFFSET]);
        if (task->tf_flags & IDE_TFLAG_OUT_LBAM)
-               hwif->OUTB(tf->lbam, IDE_LCYL_REG);
+               hwif->OUTB(tf->lbam, hwif->io_ports[IDE_LCYL_OFFSET]);
        if (task->tf_flags & IDE_TFLAG_OUT_LBAH)
-               hwif->OUTB(tf->lbah, IDE_HCYL_REG);
+               hwif->OUTB(tf->lbah, hwif->io_ports[IDE_HCYL_OFFSET]);
 
        if (task->tf_flags & IDE_TFLAG_OUT_DEVICE)
-               hwif->OUTB((tf->device & HIHI) | drive->select.all, IDE_SELECT_REG);
+               hwif->OUTB((tf->device & HIHI) | drive->select.all,
+                          hwif->io_ports[IDE_SELECT_OFFSET]);
 }
 
 int taskfile_lib_get_identify (ide_drive_t *drive, u8 *buf)
@@ -152,7 +154,8 @@ ide_startstop_t do_rw_taskfile (ide_drive_t *drive, ide_task_t *task)
        switch (task->data_phase) {
        case TASKFILE_MULTI_OUT:
        case TASKFILE_OUT:
-               hwif->OUTBSYNC(drive, tf->command, IDE_COMMAND_REG);
+               hwif->OUTBSYNC(drive, tf->command,
+                              hwif->io_ports[IDE_COMMAND_OFFSET]);
                ndelay(400);    /* FIXME */
                return pre_task_out_intr(drive, task->rq);
        case TASKFILE_MULTI_IN:
This page took 0.029438 seconds and 5 git commands to generate.