diff options
author | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2008-01-25 16:17:07 -0500 |
---|---|---|
committer | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2008-01-25 16:17:07 -0500 |
commit | 74095a91ed02f6727b62d4416be00a041f2d7436 (patch) | |
tree | 033cc52877103739c5b55a2cfdd3bfaf6996d5d3 /drivers/ide/ide-disk.c | |
parent | 9a3c49be5c5f7388eefb712be9a383904140532e (diff) |
ide: use do_rw_taskfile() in flagged_taskfile()
Based on the earlier work by Tejun Heo.
* Move setting IDE_TFLAG_LBA48 taskfile flag from do_rw_taskfile()
function to the callers.
* Add IDE_TFLAG_FLAGGED taskfile flag for flagged taskfiles coming
from ide_taskfile_ioctl(). Check it instead of ->tf_out_flags.all.
* Add IDE_TFLAG_OUT_DATA taskfile flag to indicate the need to load
IDE data register in ide_tf_load().
* Add IDE_TFLAG_OUT_* taskfile flags to indicate the need to load
particular IDE taskfile registers in ide_tf_load().
* Update do_rw_taskfile() and ide_tf_load() users to set respective
IDE_TFLAG_OUT_* taksfile flags.
* Add task_dma_ok() helper.
* Use IDE_TFLAG_FLAGGED taskfile flag to select HIHI mask in ide_tf_load().
* Use do_rw_taskfile() in flagged_taskfile().
* Remove no longer needed 'tf_out_flags' field from ide_task_t.
There should be no functionality changes caused by this patch.
Cc: Tejun Heo <htejun@gmail.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/ide-disk.c')
-rw-r--r-- | drivers/ide/ide-disk.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/ide/ide-disk.c b/drivers/ide/ide-disk.c index b534fe97d476..6182c23d2020 100644 --- a/drivers/ide/ide-disk.c +++ b/drivers/ide/ide-disk.c | |||
@@ -159,6 +159,7 @@ static ide_startstop_t __ide_do_rw_disk(ide_drive_t *drive, struct request *rq, | |||
159 | 159 | ||
160 | memset(&task, 0, sizeof(task)); | 160 | memset(&task, 0, sizeof(task)); |
161 | task.tf_flags = IDE_TFLAG_NO_SELECT_MASK; /* FIXME? */ | 161 | task.tf_flags = IDE_TFLAG_NO_SELECT_MASK; /* FIXME? */ |
162 | task.tf_flags |= IDE_TFLAG_OUT_TF; | ||
162 | 163 | ||
163 | if (drive->select.b.lba) { | 164 | if (drive->select.b.lba) { |
164 | if (lba48) { | 165 | if (lba48) { |
@@ -182,7 +183,7 @@ static ide_startstop_t __ide_do_rw_disk(ide_drive_t *drive, struct request *rq, | |||
182 | tf->hob_lbah, tf->hob_lbam, tf->hob_lbal, | 183 | tf->hob_lbah, tf->hob_lbam, tf->hob_lbal, |
183 | tf->lbah, tf->lbam, tf->lbal); | 184 | tf->lbah, tf->lbam, tf->lbal); |
184 | #endif | 185 | #endif |
185 | task.tf_flags |= IDE_TFLAG_LBA48; | 186 | task.tf_flags |= (IDE_TFLAG_LBA48 | IDE_TFLAG_OUT_HOB); |
186 | } else { | 187 | } else { |
187 | tf->nsect = nsectors.b.low; | 188 | tf->nsect = nsectors.b.low; |
188 | tf->lbal = block; | 189 | tf->lbal = block; |