X-Git-Url: https://git.karo-electronics.de/?a=blobdiff_plain;f=block%2Fblk-flush.c;h=b27d0208611b4d904e7fda9e4e66bd9a4c7411b4;hb=HEAD;hp=54b123d6563e6e57aecff9e92af2614fb8c3682e;hpb=4660ba63f1c4e07c20a435e084f12ba48a82bd2b;p=mv-sheeva.git diff --git a/block/blk-flush.c b/block/blk-flush.c index 54b123d6563..b27d0208611 100644 --- a/block/blk-flush.c +++ b/block/blk-flush.c @@ -66,10 +66,12 @@ static void blk_flush_complete_seq_end_io(struct request_queue *q, /* * Moving a request silently to empty queue_head may stall the - * queue. Kick the queue in those cases. + * queue. Kick the queue in those cases. This function is called + * from request completion path and calling directly into + * request_fn may confuse the driver. Always use kblockd. */ if (was_empty && next_rq) - __blk_run_queue(q); + __blk_run_queue(q, true); } static void pre_flush_end_io(struct request *rq, int error) @@ -130,7 +132,7 @@ static struct request *queue_next_fseq(struct request_queue *q) BUG(); } - elv_insert(q, rq, ELEVATOR_INSERT_FRONT); + elv_insert(q, rq, ELEVATOR_INSERT_REQUEUE); return rq; }