block: don't defer flushes on blk-mq + scheduling for-4.11/review
authorJens Axboe <axboe@fb.com>
Fri, 17 Feb 2017 18:40:44 +0000 (11:40 -0700)
committerJens Axboe <axboe@fb.com>
Fri, 17 Feb 2017 18:40:44 +0000 (11:40 -0700)
commitd07891dfdf318dab9a98a0c3a286962ea13e5d0a
tree45dda86a66ba0f24af1a7a1778cb70fc65ff4666
parente3aa75370104e105c6db6fa748b0f581ef03a083
block: don't defer flushes on blk-mq + scheduling

For blk-mq with scheduling, we can potentially end up with ALL
driver tags assigned and sitting on the flush queues. If we
defer because of an inlfight data request, then we can deadlock
if that data request doesn't already have a tag assigned.

This fixes a deadlock with running the xfs/297 xfstest, where
thousands of syncs can cause the drive queue to stall.

Signed-off-by: Jens Axboe <axboe@fb.com>
block/blk-flush.c