[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20090216001336.27491.67295.sendpatchset@localhost.localdomain>
Date: Mon, 16 Feb 2009 01:13:36 +0100
From: Bartlomiej Zolnierkiewicz <bzolnier@...il.com>
To: linux-ide@...r.kernel.org
Cc: Borislav Petkov <petkovbb@...il.com>,
Bartlomiej Zolnierkiewicz <bzolnier@...il.com>,
linux-kernel@...r.kernel.org
Subject: [PATCH 04/20] ide-cd: use ide_end_rq() also for failed non-fs requests
From: Bartlomiej Zolnierkiewicz <bzolnier@...il.com>
Subject: [PATCH] ide-cd: use ide_end_rq() also for failed non-fs requests
Use ide_end_rq() also for failed non-fs requests on completion
of REQUEST SENSE requests + use blk_rq_bytes() while at it.
Cc: Borislav Petkov <petkovbb@...il.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@...il.com>
---
drivers/ide/ide-cd.c | 16 ++++------------
1 file changed, 4 insertions(+), 12 deletions(-)
Index: b/drivers/ide/ide-cd.c
===================================================================
--- a/drivers/ide/ide-cd.c
+++ b/drivers/ide/ide-cd.c
@@ -260,18 +260,10 @@ static void cdrom_end_request(ide_drive_
failed->sense_len = rq->sense_len;
}
cdrom_analyze_sense_data(drive, failed, sense);
- /*
- * now end the failed request
- */
- if (blk_fs_request(failed)) {
- if (ide_end_rq(drive, failed, -EIO,
- failed->hard_nr_sectors << 9))
- BUG();
- } else {
- if (blk_end_request(failed, -EIO,
- failed->data_len))
- BUG();
- }
+
+ if (ide_end_rq(drive, failed, -EIO,
+ blk_rq_bytes(failed)))
+ BUG();
} else
cdrom_analyze_sense_data(drive, NULL, sense);
}
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists