linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [patch 2/6] ide: fix ide_kill_rq() for special ide-{floppy,tape} driver requests
@ 2009-06-23 21:26 Bartlomiej Zolnierkiewicz
  2009-06-23 23:16 ` David Miller
  2009-06-24  6:49 ` David Miller
  0 siblings, 2 replies; 9+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2009-06-23 21:26 UTC (permalink / raw)
  To: David Miller; +Cc: linux-ide, linux-kernel

From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Subject: [PATCH] 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>
---
Untested, you may try pinging Borislav and/or Tejun about possible
testing if you would like to verify the patch before applying.

 drivers/ide/ide-io.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Index: b/drivers/ide/ide-io.c
===================================================================
--- a/drivers/ide/ide-io.c
+++ b/drivers/ide/ide-io.c
@@ -152,7 +152,7 @@ void ide_kill_rq(ide_drive_t *drive, str
 
 	if ((media == ide_floppy || media == ide_tape) && drv_req) {
 		rq->errors = 0;
-		ide_complete_rq(drive, 0, blk_rq_bytes(rq));
+		ide_complete_rq(drive, -EIO, blk_rq_bytes(rq));
 	} else {
 		if (media == ide_tape)
 			rq->errors = IDE_DRV_ERROR_GENERAL;

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2009-06-25 10:09 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-06-23 21:26 [patch 2/6] ide: fix ide_kill_rq() for special ide-{floppy,tape} driver requests Bartlomiej Zolnierkiewicz
2009-06-23 23:16 ` David Miller
2009-06-24  0:49   ` Bartlomiej Zolnierkiewicz
2009-06-24  7:08   ` Borislav Petkov
2009-06-24  6:49 ` David Miller
2009-06-24 10:09   ` Bartlomiej Zolnierkiewicz
2009-06-24 10:39     ` David Miller
2009-06-24 17:44       ` Borislav Petkov
2009-06-25 10:09         ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).