Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

lightnvm: cleanup queue before target removal

This prevents outstanding IOs to be sent for completion to target after
the target has been removed. The flow is now: stop new IOs > cleanup
queue > remove target.

Signed-off-by: Javier Gonzalez <javier@cnexlabs.com>
Signed-off-by: Matias Bjørling <m@bjorling.me>
Signed-off-by: Jens Axboe <axboe@fb.com>

authored by

Javier González and committed by
Jens Axboe
d09f9581 dad1b009

+2 -2
+2 -2
drivers/lightnvm/core.c
··· 460 460 lockdep_assert_held(&nvm_lock); 461 461 462 462 del_gendisk(tdisk); 463 + blk_cleanup_queue(q); 464 + 463 465 if (tt->exit) 464 466 tt->exit(tdisk->private_data); 465 - 466 - blk_cleanup_queue(q); 467 467 468 468 put_disk(tdisk); 469 469