lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20221130025046.2667372-1-konstantin.meskhidze@huawei.com>
Date:   Wed, 30 Nov 2022 10:50:46 +0800
From:   Konstantin Meskhidze <konstantin.meskhidze@...wei.com>
To:     <harry.wentland@....com>
CC:     <sunpeng.li@....com>, <Rodrigo.Siqueira@....com>,
        <alexander.deucher@....com>, <christian.koenig@....com>,
        <Xinhui.Pan@....com>, <airlied@...il.com>, <daniel@...ll.ch>,
        <Jun.Lei@....com>, <Alvin.Lee2@....com>,
        <meenakshikumar.somasundaram@....com>, <martin.leung@....com>,
        <Dillon.Varone@....com>, <wenjing.liu@....com>,
        <alex.hung@....com>, <amd-gfx@...ts.freedesktop.org>,
        <dri-devel@...ts.freedesktop.org>, <linux-kernel@...r.kernel.org>,
        <yusongping@...wei.com>, <hukeping@...wei.com>,
        <artem.kuzin@...wei.com>
Subject: [PATCH] drm: amd: display: Fix memory leakage

This commit fixes memory leakage in dc_construct_ctx() function.

Signed-off-by: Konstantin Meskhidze <konstantin.meskhidze@...wei.com>
---
 drivers/gpu/drm/amd/display/dc/core/dc.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/gpu/drm/amd/display/dc/core/dc.c b/drivers/gpu/drm/amd/display/dc/core/dc.c
index 997ab031f816..359e28d3567e 100644
--- a/drivers/gpu/drm/amd/display/dc/core/dc.c
+++ b/drivers/gpu/drm/amd/display/dc/core/dc.c
@@ -878,6 +878,7 @@ static bool dc_construct_ctx(struct dc *dc,
 
 	dc_ctx->perf_trace = dc_perf_trace_create();
 	if (!dc_ctx->perf_trace) {
+		kfree(dc_ctx);
 		ASSERT_CRITICAL(false);
 		return false;
 	}
-- 
2.25.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ