Re: ide-cd bug (MODE_SENSE/CDROM_SEND_PACKET)
From: Samuel Rydh
Date: Tue Mar 23 2004 - 06:48:50 EST
On Tue, Mar 23, 2004 at 11:48:47AM +0100, Jens Axboe wrote:
> Could you check if this works for you?
>
> ===== drivers/block/elevator.c 1.53 vs edited =====
> --- 1.53/drivers/block/elevator.c Mon Jan 19 07:38:36 2004
> +++ edited/drivers/block/elevator.c Tue Mar 23 11:47:53 2004
> @@ -210,10 +210,14 @@
> rq = NULL;
> break;
> } else if (ret == BLKPREP_KILL) {
> + int nr_bytes = rq->hard_nr_sectors << 9;
> +
> + if (!nr_bytes)
> + nr_bytes = rq->data_len;
> +
> blkdev_dequeue_request(rq);
> rq->flags |= REQ_QUIET;
> - while (end_that_request_first(rq, 0, rq->nr_sectors))
> - ;
> + end_that_request_chunk(rq, 0, nr_bytes);
> end_that_request_last(rq);
> } else {
> printk("%s: bad return=%d\n", __FUNCTION__, ret);
>
Yes, this fixes the problem.
/Samuel
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/