aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2009-06-23 07:26:06 -0400
committerDavid S. Miller <davem@davemloft.net>2009-06-26 02:57:14 -0400
commit789547508f22e482825f52f813b59680408ec2c7 (patch)
treeb06d9f048a04125528fb7d89048a16d016c8d1ea /drivers
parentd7e2f36d9a92284754ed5254562766cb3d61c7ca (diff)
ide: fix ide_kill_rq() for special ide-{floppy,tape} driver requests
Such requests should be failed with -EIO (like all other requests in this function) instead of being completed successfully. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/ide/ide-io.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/ide/ide-io.c b/drivers/ide/ide-io.c
index 93b7886a2d6e..95db5f03f6a2 100644
--- a/drivers/ide/ide-io.c
+++ b/drivers/ide/ide-io.c
@@ -152,7 +152,7 @@ void ide_kill_rq(ide_drive_t *drive, struct request *rq)
152 152
153 if ((media == ide_floppy || media == ide_tape) && drv_req) { 153 if ((media == ide_floppy || media == ide_tape) && drv_req) {
154 rq->errors = 0; 154 rq->errors = 0;
155 ide_complete_rq(drive, 0, blk_rq_bytes(rq)); 155 ide_complete_rq(drive, -EIO, blk_rq_bytes(rq));
156 } else { 156 } else {
157 if (media == ide_tape) 157 if (media == ide_tape)
158 rq->errors = IDE_DRV_ERROR_GENERAL; 158 rq->errors = IDE_DRV_ERROR_GENERAL;