diff options
author | Sergei Shtylyov <sshtylyov@ru.mvista.com> | 2009-03-31 14:15:31 -0400 |
---|---|---|
committer | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2009-03-31 14:15:31 -0400 |
commit | 35218d1ca808ed19b8c6f079ce91872b3deb2219 (patch) | |
tree | 4cc1748e9046ef26701c88b3c6448734f1a7e874 /drivers/ide/scc_pata.c | |
parent | bac08cee93f9cb37b40ecfa8eaf1f6d8daf3909b (diff) |
ide: move data register access out of tf_{read|load}() methods (take 2)
Move IDE_FTFLAG_{IN|OUT}_DATA flag handling out of tf_{read|load}() methods
into the only two functions where these flags actually need to be handled:
do_rw_taskfile() and ide_complete_cmd()...
Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/scc_pata.c')
-rw-r--r-- | drivers/ide/scc_pata.c | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/drivers/ide/scc_pata.c b/drivers/ide/scc_pata.c index 9c47cbf8c506..97f8e0ef21b1 100644 --- a/drivers/ide/scc_pata.c +++ b/drivers/ide/scc_pata.c | |||
@@ -656,12 +656,6 @@ static void scc_tf_load(ide_drive_t *drive, struct ide_cmd *cmd) | |||
656 | if (cmd->ftf_flags & IDE_FTFLAG_FLAGGED) | 656 | if (cmd->ftf_flags & IDE_FTFLAG_FLAGGED) |
657 | HIHI = 0xFF; | 657 | HIHI = 0xFF; |
658 | 658 | ||
659 | if (cmd->ftf_flags & IDE_FTFLAG_OUT_DATA) { | ||
660 | u8 data[2] = { tf->data, tf->hob_data }; | ||
661 | |||
662 | scc_output_data(drive, NULL, data, 2); | ||
663 | } | ||
664 | |||
665 | if (cmd->tf_flags & IDE_TFLAG_OUT_HOB_FEATURE) | 659 | if (cmd->tf_flags & IDE_TFLAG_OUT_HOB_FEATURE) |
666 | scc_ide_outb(tf->hob_feature, io_ports->feature_addr); | 660 | scc_ide_outb(tf->hob_feature, io_ports->feature_addr); |
667 | if (cmd->tf_flags & IDE_TFLAG_OUT_HOB_NSECT) | 661 | if (cmd->tf_flags & IDE_TFLAG_OUT_HOB_NSECT) |
@@ -694,15 +688,6 @@ static void scc_tf_read(ide_drive_t *drive, struct ide_cmd *cmd) | |||
694 | struct ide_io_ports *io_ports = &drive->hwif->io_ports; | 688 | struct ide_io_ports *io_ports = &drive->hwif->io_ports; |
695 | struct ide_taskfile *tf = &cmd->tf; | 689 | struct ide_taskfile *tf = &cmd->tf; |
696 | 690 | ||
697 | if (cmd->ftf_flags & IDE_FTFLAG_IN_DATA) { | ||
698 | u8 data[2]; | ||
699 | |||
700 | scc_input_data(drive, cmd, data, 2); | ||
701 | |||
702 | tf->data = data[0]; | ||
703 | tf->hob_data = data[1]; | ||
704 | } | ||
705 | |||
706 | /* be sure we're looking at the low order bits */ | 691 | /* be sure we're looking at the low order bits */ |
707 | scc_ide_outb(ATA_DEVCTL_OBS, io_ports->ctl_addr); | 692 | scc_ide_outb(ATA_DEVCTL_OBS, io_ports->ctl_addr); |
708 | 693 | ||