Commit 84415f93 authored by Ming Lei's avatar Ming Lei Committed by Greg Kroah-Hartman
Browse files

ublk: fail to recover device if queue setup is interrupted



[ Upstream commit 0c0cbd4e ]

In ublk_ctrl_end_recovery(), if wait_for_completion_interruptible() is
interrupted by signal, queues aren't setup successfully yet, so we
have to fail UBLK_CMD_END_USER_RECOVERY, otherwise kernel oops can be
triggered.

Fixes: c732a852 ("ublk_drv: add START_USER_RECOVERY and END_USER_RECOVERY support")
Reported-by: default avatarStefano Garzarella <sgarzare@redhat.com>
Signed-off-by: default avatarMing Lei <ming.lei@redhat.com>
Reviewed-by: default avatarStefano Garzarella <sgarzare@redhat.com>
Link: https://lore.kernel.org/r/20230726144502.566785-3-ming.lei@redhat.com


Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 0d5916c4
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment