diff options
author | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2009-03-27 07:46:34 -0400 |
---|---|---|
committer | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2009-03-27 07:46:34 -0400 |
commit | c152cc1a90f9680cefa74d9ff9ce36038081ba72 (patch) | |
tree | 7932faaf671d8ac20d61a2df2cfe43c7919b0d4f /drivers/ide/ide-io.c | |
parent | 5e2040fd0a97888952b37243b5868872bbe0f6ac (diff) |
ide: use ->end_request only for private device driver requests
* Move IDE{FLOPPY,TAPE}_ERROR_* defines to <linux/ide.h> and rename them
to IDE_DRV_ERROR_*.
* Handle ->end_request special cases for floppy/tape media in ide_kill_rq().
* Call ->end_request only for private device driver requests.
There should be no functional changes caused by this patch.
Acked-by: Borislav Petkov <petkovbb@gmail.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/ide-io.c')
-rw-r--r-- | drivers/ide/ide-io.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/ide/ide-io.c b/drivers/ide/ide-io.c index 38076169b893..da2f97dfa8f8 100644 --- a/drivers/ide/ide-io.c +++ b/drivers/ide/ide-io.c | |||
@@ -178,7 +178,12 @@ EXPORT_SYMBOL(ide_complete_rq); | |||
178 | 178 | ||
179 | void ide_kill_rq(ide_drive_t *drive, struct request *rq) | 179 | void ide_kill_rq(ide_drive_t *drive, struct request *rq) |
180 | { | 180 | { |
181 | if (rq->rq_disk) { | 181 | drive->failed_pc = NULL; |
182 | |||
183 | if (drive->media == ide_tape) | ||
184 | rq->errors = IDE_DRV_ERROR_GENERAL; | ||
185 | |||
186 | if (blk_special_request(rq) && rq->rq_disk) { | ||
182 | struct ide_driver *drv; | 187 | struct ide_driver *drv; |
183 | 188 | ||
184 | drv = *(struct ide_driver **)rq->rq_disk->private_data; | 189 | drv = *(struct ide_driver **)rq->rq_disk->private_data; |