diff options
| author | Ming Lei <[email protected]> | 2022-07-30 09:27:47 +0000 |
|---|---|---|
| committer | Jens Axboe <[email protected]> | 2022-08-03 03:13:40 +0000 |
| commit | a8ce5f52efce3b89ca82ce8798d0d061117465d2 (patch) | |
| tree | 22e1ad079275eaa57510e5253528625b9446d1ea /fs/ext4/fast_commit.c | |
| parent | block: fix leaking page ref on truncated direct io (diff) | |
| download | kernel-a8ce5f52efce3b89ca82ce8798d0d061117465d2.tar.gz kernel-a8ce5f52efce3b89ca82ce8798d0d061117465d2.zip | |
ublk_drv: cancel device even though disk isn't up
Each ublk queue is started before adding disk, we have to cancel queues in
ublk_stop_dev() so that ubq daemon can be exited, otherwise DEL_DEV command
may hang forever.
Also avoid to cancel queues two times by checking if queue is ready,
otherwise use-after-free on io_uring may be triggered because ublk_stop_dev
is called by ublk_remove() too.
Fixes: 71f28f3136af ("ublk_drv: add io_uring based userspace block driver")
Reviewed-by: Christoph Hellwig <[email protected]>
Signed-off-by: Ming Lei <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Jens Axboe <[email protected]>
Diffstat (limited to 'fs/ext4/fast_commit.c')
0 files changed, 0 insertions, 0 deletions
