]> git.ipfire.org Git - thirdparty/linux.git/commit
drm/amdgpu/mmhub3.0: add bounds checking for cid
authorAlex Deucher <alexander.deucher@amd.com>
Wed, 4 Mar 2026 22:25:30 +0000 (17:25 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 17 Mar 2026 16:19:04 +0000 (12:19 -0400)
commitcdb82ecbeccb55fae75a3c956b605f7801a30db1
treee4e2efe5e14e5b38a0bb011b36ee66b7043f4b6c
parente5e6d67b1ce9764e67aef2d0eef9911af53ad99a
drm/amdgpu/mmhub3.0: add bounds checking for cid

The value should never exceed the array size as those
are the only values the hardware is expected to return,
but add checks anyway.

Reviewed-by: Benjamin Cheng <benjamin.cheng@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
(cherry picked from commit f14f27bbe2a3ed7af32d5f6eaf3f417139f45253)
Cc: stable@vger.kernel.org
drivers/gpu/drm/amd/amdgpu/mmhub_v3_0.c