Commit 2c0b596f authored by Gabriel Krisman Bertazi's avatar Gabriel Krisman Bertazi Committed by Yang Yingliang
Browse files

blk-cgroup: Fix memleak on error path



stable inclusion
from linux-4.19.156
commit 6dba51828dfd31e326e6642727ede24c054a86fe

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

[ Upstream commit 52abfcbd ]

If new_blkg allocation raced with blk_policy change and
blkg_lookup_check fails, new_blkg is leaked.

Acked-by: default avatarTejun Heo <tj@kernel.org>
Signed-off-by: default avatarGabriel Krisman Bertazi <krisman@collabora.com>
Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
Signed-off-by: default avatarYang Yingliang <yangyingliang@huawei.com>
Signed-off-by: default avatarCheng Jian <cj.chengjian@huawei.com>
parent a3ea1ea6
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment