mirror of
https://github.com/hardkernel/linux.git
synced 2026-03-25 03:50:24 +09:00
ceph: fix double unlock in handle_cap_export()
[ Upstream commit 4d8e28ff31 ]
If the ceph_mdsc_open_export_target_session() return fails, it will
do a "goto retry", but the session mutex has already been unlocked.
Re-lock the mutex in that case to ensure that we don't unlock it
twice.
Signed-off-by: Wu Bo <wubo40@huawei.com>
Reviewed-by: "Yan, Zheng" <zyan@redhat.com>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
df0df8ee2a
commit
b68d27c5ff
@@ -3693,6 +3693,7 @@ retry:
|
||||
WARN_ON(1);
|
||||
tsession = NULL;
|
||||
target = -1;
|
||||
mutex_lock(&session->s_mutex);
|
||||
}
|
||||
goto retry;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user