Skip to content
Commit cf8ecc5a authored by Arianna Avanzini's avatar Arianna Avanzini Committed by Jens Axboe
Browse files

null_blk: guarantee device restart in all irq modes



In single-queue (block layer) mode,the function null_rq_prep_fn stops
the device if alloc_cmd fails. Then, once stopped, the device must be
restarted on the next command completion, so that the request(s) for
which alloc_cmd failed can be requeued. Otherwise the device hangs.

Unfortunately, device restart is currently performed only for delayed
completions, i.e., in irqmode==2. This fact causes hangs, for the
above reasons, with the other irqmodes in combination with single-queue
block layer.

This commits addresses this issue by making sure that, if stopped, the
device is properly restarted for all irqmodes on completions.

Signed-off-by: default avatarPaolo Valente <paolo.valente@unimore.it>
Signed-off-by: default avatarArianna AVanzini <avanzini@google.com>
Signed-off-by: default avatarJens Axboe <axboe@fb.com>
parent 3c395a96
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment