From: FUJITA Tomonori Date: Fri, 9 Jul 2010 00:38:24 +0000 (+0900) Subject: block: set REQ_TYPE_FS on flush requests X-Git-Tag: v2.6.36-rc1~288^2~35 X-Git-Url: http://git.osdn.net/view?a=commitdiff_plain;h=28e18d0188b9e3ab82ebd09d9b1d1c7f8d1822aa;p=uclinux-h8%2Flinux.git block: set REQ_TYPE_FS on flush requests the block layer doesn't set rq->cmd_type on flush requests. By definition, it should be REQ_TYPE_FS (the lower layers build a command and interpret the result of it, that is, the block layer doesn't know the details). Signed-off-by: FUJITA Tomonori Signed-off-by: Jens Axboe --- diff --git a/block/blk-barrier.c b/block/blk-barrier.c index 557f69360b6a..d95a1440e29d 100644 --- a/block/blk-barrier.c +++ b/block/blk-barrier.c @@ -134,6 +134,7 @@ static void queue_flush(struct request_queue *q, unsigned which) } blk_rq_init(q, rq); + rq->cmd_type = REQ_TYPE_FS; rq->cmd_flags = REQ_HARDBARRIER | REQ_FLUSH; rq->rq_disk = q->bar_rq.rq_disk; rq->end_io = end_io;