]> git.dujemihanovic.xyz Git - linux.git/commit
drm/amd/display: Fix array-index-out-of-bounds in dcn35_clkmgr
authorRoman Li <roman.li@amd.com>
Tue, 30 Jan 2024 23:07:24 +0000 (18:07 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 15 Feb 2024 19:18:43 +0000 (14:18 -0500)
commit46806e59a87790760870d216f54951a5b4d545bc
treefc53f6f617f3403468feac2563d23fa0027ce234
parentdeb110292180cd501f6fde2a0178d65fcbcabb0c
drm/amd/display: Fix array-index-out-of-bounds in dcn35_clkmgr

[Why]
There is a potential memory access violation while
iterating through array of dcn35 clks.

[How]
Limit iteration per array size.

Cc: Mario Limonciello <mario.limonciello@amd.com>
Cc: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Acked-by: Aurabindo Pillai <aurabindo.pillai@amd.com>
Signed-off-by: Roman Li <roman.li@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/clk_mgr/dcn35/dcn35_clk_mgr.c