summaryrefslogtreecommitdiffstats
path: root/block/blk-core.c
diff options
context:
space:
mode:
authorJens Axboe2017-03-02 21:26:04 +0100
committerJens Axboe2017-03-02 22:30:51 +0100
commit113285b473824922498d07d7f82459507b9792eb (patch)
treee4ffafcec58afc46781bfa91ecc2b232efa0ceee /block/blk-core.c
parentblock: don't call ioc_exit_icq() with the queue lock held for blk-mq (diff)
downloadkernel-qcow2-linux-113285b473824922498d07d7f82459507b9792eb.tar.gz
kernel-qcow2-linux-113285b473824922498d07d7f82459507b9792eb.tar.xz
kernel-qcow2-linux-113285b473824922498d07d7f82459507b9792eb.zip
blk-mq: ensure that bd->last is always set correctly
When drivers are called with a request in blk-mq, blk-mq flags the state such that the driver knows if this is the last request in this call chain or not. The driver can then use that information to defer kicking off IO until bd->last is true. However, with blk-mq and scheduling, we need to allocate a driver tag for a request before it can be issued. If we fail to allocate such a tag, we could end up in the situation where the last request issued did not have bd->last == true set. This can then cause a driver hang. This fixes a hang with virtio-blk, which uses bd->last as a hint on whether to kick the queue or not. Reported-by: Chris Mason <clm@fb.com> Tested-by: Chris Mason <clm@fb.com> Reviewed-by: Omar Sandoval <osandov@fb.com> Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'block/blk-core.c')
0 files changed, 0 insertions, 0 deletions