mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-06 02:50:49 +09:00
drm: amd: display: Fix memory leakage
[ Upstream commit 6b8701be1f ]
This commit fixes memory leakage in dc_construct_ctx() function.
Signed-off-by: Konstantin Meskhidze <konstantin.meskhidze@huawei.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
ce9e9d3dcb
commit
d473c55ce1
@@ -616,6 +616,7 @@ static bool dc_construct_ctx(struct dc *dc,
|
|||||||
|
|
||||||
dc_ctx->perf_trace = dc_perf_trace_create();
|
dc_ctx->perf_trace = dc_perf_trace_create();
|
||||||
if (!dc_ctx->perf_trace) {
|
if (!dc_ctx->perf_trace) {
|
||||||
|
kfree(dc_ctx);
|
||||||
ASSERT_CRITICAL(false);
|
ASSERT_CRITICAL(false);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user