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-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <d62e10cd-6e27-4498-b90f-3ec891686070@amd.com>
Date: Wed, 26 Jun 2024 13:57:07 -0400
From: Aurabindo Pillai <aurabindo.pillai@....com>
To: Ma Ke <make24@...as.ac.cn>, harry.wentland@....com, sunpeng.li@....com,
 Rodrigo.Siqueira@....com, alexander.deucher@....com,
 christian.koenig@....com, Xinhui.Pan@....com, airlied@...il.com,
 daniel@...ll.ch, jun.lei@....com, wayne.lin@....com, dillon.varone@....com,
 nicholas.kazlauskas@....com, Qingqing.Zhuo@....com, stylon.wang@....com
Cc: amd-gfx@...ts.freedesktop.org, dri-devel@...ts.freedesktop.org,
 linux-kernel@...r.kernel.org
Subject: Re: [PATCH] drm/amd/display: Add null check before access structs

Thanks for the fix, I'll apply this.

On 6/26/24 9:06 AM, Ma Ke wrote:
> In enable_phantom_plane, we should better check null pointer before
> accessing various structs.
> 
> Fixes: 09a4ec5da92c ("drm/amd/display: Refactor dc_state interface")
> Signed-off-by: Ma Ke <make24@...as.ac.cn>
> ---
>   drivers/gpu/drm/amd/display/dc/dml2/dml2_mall_phantom.c | 2 ++
>   1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/gpu/drm/amd/display/dc/dml2/dml2_mall_phantom.c b/drivers/gpu/drm/amd/display/dc/dml2/dml2_mall_phantom.c
> index 282d70e2b18a..3d29169dd6bb 100644
> --- a/drivers/gpu/drm/amd/display/dc/dml2/dml2_mall_phantom.c
> +++ b/drivers/gpu/drm/amd/display/dc/dml2/dml2_mall_phantom.c
> @@ -750,6 +750,8 @@ static void enable_phantom_plane(struct dml2_context *ctx,
>   					ctx->config.svp_pstate.callbacks.dc,
>   					state,
>   					curr_pipe->plane_state);
> +			if (!phantom_plane)
> +				return;
>   		}
>   
>   		memcpy(&phantom_plane->address, &curr_pipe->plane_state->address, sizeof(phantom_plane->address));

-- 
--

Thanks & Regards,
Aurabindo Pillai

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ