summaryrefslogtreecommitdiffstats
path: root/block/ll_rw_blk.c
diff options
context:
space:
mode:
authorTejun Heo <htejun@gmail.com>2006-02-08 01:01:31 -0800
committerLinus Torvalds <torvalds@g5.osdl.org>2006-02-08 07:52:58 -0800
commit30e9656cc340035e102fea46e1908689494b042d (patch)
tree5fc623ccad5a1f5b09ebc4b7e8d7c6bec8e485ac /block/ll_rw_blk.c
parente5ea0a9fca5612808839dd4bcc41c46fc02451f9 (diff)
downloadtalos-obmc-linux-30e9656cc340035e102fea46e1908689494b042d.tar.gz
talos-obmc-linux-30e9656cc340035e102fea46e1908689494b042d.zip
[PATCH] block: implement elv_insert and use it (fix ordcolor flipping bug)
q->ordcolor must only be flipped on initial queueing of a hardbarrier request. Constructing ordered sequence and requeueing used to pass through __elv_add_request() which flips q->ordcolor when it sees a barrier request. This patch separates out elv_insert() from __elv_add_request() and uses elv_insert() when constructing ordered sequence and requeueing. elv_insert() inserts the given request at the specified position and does nothing else. Signed-off-by: Tejun Heo <htejun@gmail.com> Acked-by: Jens Axboe <axboe@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'block/ll_rw_blk.c')
-rw-r--r--block/ll_rw_blk.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/block/ll_rw_blk.c b/block/ll_rw_blk.c
index ee5ed98db4cd..03d9c82b0fe7 100644
--- a/block/ll_rw_blk.c
+++ b/block/ll_rw_blk.c
@@ -454,7 +454,7 @@ static void queue_flush(request_queue_t *q, unsigned which)
rq->end_io = end_io;
q->prepare_flush_fn(q, rq);
- __elv_add_request(q, rq, ELEVATOR_INSERT_FRONT, 0);
+ elv_insert(q, rq, ELEVATOR_INSERT_FRONT);
}
static inline struct request *start_ordered(request_queue_t *q,
@@ -490,7 +490,7 @@ static inline struct request *start_ordered(request_queue_t *q,
else
q->ordseq |= QUEUE_ORDSEQ_POSTFLUSH;
- __elv_add_request(q, rq, ELEVATOR_INSERT_FRONT, 0);
+ elv_insert(q, rq, ELEVATOR_INSERT_FRONT);
if (q->ordered & QUEUE_ORDERED_PREFLUSH) {
queue_flush(q, QUEUE_ORDERED_PREFLUSH);
OpenPOWER on IntegriCloud