ide: simplify 'struct ide_taskfile'

Make 'struct ide_taskfile' cover only 8 register values and thus put two such
fields ('tf' and 'hob') into 'struct ide_cmd', dropping unnecessary 'tf_array'
field from it.

This required changing the prototype of ide_get_lba_addr() and ide_tf_dump().

Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
[bart: fix setting of ATA_LBA bit for LBA48 commands in __ide_do_rw_disk()]
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
This commit is contained in:
Sergei Shtylyov
2009-04-08 14:13:02 +02:00
committato da Bartlomiej Zolnierkiewicz
parent 60f85019c6
commit 745483f10c
10 ha cambiato i file con 89 aggiunte e 107 eliminazioni

Vedi File

@@ -86,18 +86,19 @@ static void superio_tf_read(ide_drive_t *drive, struct ide_cmd *cmd)
if (cmd->tf_flags & IDE_TFLAG_LBA48) {
outb(ATA_HOB | ATA_DEVCTL_OBS, io_ports->ctl_addr);
tf = &cmd->hob;
valid = cmd->valid.in.hob;
if (valid & IDE_VALID_ERROR)
tf->hob_error = inb(io_ports->feature_addr);
tf->error = inb(io_ports->feature_addr);
if (valid & IDE_VALID_NSECT)
tf->hob_nsect = inb(io_ports->nsect_addr);
tf->nsect = inb(io_ports->nsect_addr);
if (valid & IDE_VALID_LBAL)
tf->hob_lbal = inb(io_ports->lbal_addr);
tf->lbal = inb(io_ports->lbal_addr);
if (valid & IDE_VALID_LBAM)
tf->hob_lbam = inb(io_ports->lbam_addr);
tf->lbam = inb(io_ports->lbam_addr);
if (valid & IDE_VALID_LBAH)
tf->hob_lbah = inb(io_ports->lbah_addr);
tf->lbah = inb(io_ports->lbah_addr);
}
}