summaryrefslogtreecommitdiff
path: root/drivers/ide/ide-eh.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ide/ide-eh.c')
-rw-r--r--drivers/ide/ide-eh.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/drivers/ide/ide-eh.c b/drivers/ide/ide-eh.c
index 1231b5e486f2..e2c04886616f 100644
--- a/drivers/ide/ide-eh.c
+++ b/drivers/ide/ide-eh.c
@@ -124,7 +124,16 @@ ide_startstop_t ide_error(ide_drive_t *drive, const char *msg, u8 stat)
/* retry only "normal" I/O: */
if (!blk_fs_request(rq)) {
rq->errors = 1;
- ide_end_drive_cmd(drive, stat, err);
+ if (rq->cmd_type == REQ_TYPE_ATA_TASKFILE) {
+ ide_task_t *task = rq->special;
+
+ if (task)
+ ide_complete_task(drive, task, stat, err);
+ } else if (blk_pm_request(rq)) {
+ ide_complete_pm_rq(drive, rq);
+ return ide_stopped;
+ }
+ ide_complete_rq(drive, err);
return ide_stopped;
}