aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/ide-eh.c
diff options
context:
space:
mode:
authorBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2009-03-27 07:46:31 -0400
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2009-03-27 07:46:31 -0400
commita09485df9cda49fbde2766c86eb18a9cae585162 (patch)
tree4dfc6219da40e86aa293621d43c5a71018c7992f /drivers/ide/ide-eh.c
parente120237c0e4d9a83c1380f5ff7b5f2ba31f1c820 (diff)
ide: move request type specific code from ide_end_drive_cmd() to callers (v3)
* Move request type specific code from ide_end_drive_cmd() to callers. * Remove stale ide_end_drive_cmd() documentation and drop no longer used 'stat' argument. Then rename the function to ide_complete_rq(). v2: * Fix handling of blk_pm_request() requests in task_no_data_intr(). v3: * Some ide_no_data_taskfile() users (HPA code and HDIO_DRIVE_* ioctls handlers) access original command later so we need to update it in ide_complete_task(). There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
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)
124 /* retry only "normal" I/O: */ 124 /* retry only "normal" I/O: */
125 if (!blk_fs_request(rq)) { 125 if (!blk_fs_request(rq)) {
126 rq->errors = 1; 126 rq->errors = 1;
127 ide_end_drive_cmd(drive, stat, err); 127 if (rq->cmd_type == REQ_TYPE_ATA_TASKFILE) {
128 ide_task_t *task = rq->special;
129
130 if (task)
131 ide_complete_task(drive, task, stat, err);
132 } else if (blk_pm_request(rq)) {
133 ide_complete_pm_rq(drive, rq);
134 return ide_stopped;
135 }
136 ide_complete_rq(drive, err);
128 return ide_stopped; 137 return ide_stopped;
129 } 138 }
130 139