]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
drm/admgpu: fix dereferencing null pointer context
authorJesse Zhang <jesse.zhang@amd.com>
Thu, 9 May 2024 02:57:04 +0000 (10:57 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 14 Aug 2024 13:34:13 +0000 (15:34 +0200)
commit4fd52f7c2c11d330571c6bde06e5ea508ec25c9d
tree9b456ee3889ab72f487ceaa34475f462d22f633c
parent13937a40aae4efe64592ba48c057ac3c72f7fe82
drm/admgpu: fix dereferencing null pointer context

[ Upstream commit 030ffd4d43b433bc6671d9ec34fc12c59220b95d ]

When user space sets an invalid ta type, the pointer context will be empty.
So it need to check the pointer context before using it

Signed-off-by: Jesse Zhang <Jesse.Zhang@amd.com>
Suggested-by: Tim Huang <Tim.Huang@amd.com>
Reviewed-by: Tim Huang <Tim.Huang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/amd/amdgpu/amdgpu_psp_ta.c