aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/ide-taskfile.c
diff options
context:
space:
mode:
authorTejun Heo <htejun@gmail.com>2008-01-26 14:13:11 -0500
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2008-01-26 14:13:11 -0500
commit4d7a984bdcbdda69fc6b2a4a655415140270aa7b (patch)
tree92d331aa25949277fe76354dfdaf5a5d6e62aaf4 /drivers/ide/ide-taskfile.c
parent79f21b84d94c02b941818df282b61f2a5a028722 (diff)
ide: task_end_request() fix
task_end_request() modified to always call ide_end_drive_cmd() for taskfile requests. Previously, ide_end_drive_cmd() was called only when IDE_TFLAG_FLAGGED was set. Also, ide_dma_intr() is modified to use task_end_request(). Enables TASKFILE ioctls to get valid register outputs on successful completion. Bart: - ported it over recent IDE changes Signed-off-by: Tejun Heo <htejun@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/ide-taskfile.c')
-rw-r--r--drivers/ide/ide-taskfile.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/drivers/ide/ide-taskfile.c b/drivers/ide/ide-taskfile.c
index 3bbb438f4f92..17c2c0467297 100644
--- a/drivers/ide/ide-taskfile.c
+++ b/drivers/ide/ide-taskfile.c
@@ -408,16 +408,13 @@ static ide_startstop_t task_error(ide_drive_t *drive, struct request *rq,
408 return ide_error(drive, s, stat); 408 return ide_error(drive, s, stat);
409} 409}
410 410
411static void task_end_request(ide_drive_t *drive, struct request *rq, u8 stat) 411void task_end_request(ide_drive_t *drive, struct request *rq, u8 stat)
412{ 412{
413 if (rq->cmd_type == REQ_TYPE_ATA_TASKFILE) { 413 if (rq->cmd_type == REQ_TYPE_ATA_TASKFILE) {
414 ide_task_t *task = rq->special; 414 u8 err = drive->hwif->INB(IDE_ERROR_REG);
415 415
416 if (task->tf_flags & IDE_TFLAG_FLAGGED) { 416 ide_end_drive_cmd(drive, stat, err);
417 u8 err = drive->hwif->INB(IDE_ERROR_REG); 417 return;
418 ide_end_drive_cmd(drive, stat, err);
419 return;
420 }
421 } 418 }
422 419
423 if (rq->rq_disk) { 420 if (rq->rq_disk) {