Commit 170b8e8b authored by Luo Meng's avatar Luo Meng Committed by zhaoxiaoqiang11
Browse files

dm cache: Fix UAF in destroy()

stable inclusion
from stable-v5.10.163
commit 2b17026685a270b2beaf1cdd9857fcedd3505c7e
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I7PJ9N

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=2b17026685a270b2beaf1cdd9857fcedd3505c7e



----------------------------------------------------

commit 6a459d8e upstream.

Dm_cache also has the same UAF problem when dm_resume()
and dm_destroy() are concurrent.

Therefore, cancelling timer again in destroy().

Cc: stable@vger.kernel.org
Fixes: c6b4fcba ("dm: add cache target")
Signed-off-by: default avatarLuo Meng <luomeng12@huawei.com>
Signed-off-by: default avatarMike Snitzer <snitzer@kernel.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: default avatarzhaoxiaoqiang11 <zhaoxiaoqiang11@jd.com>
parent 9deaf90c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment