]> www.infradead.org Git - users/jedix/linux-maple.git/commit
drm/amd/pm: fix the Out-of-bounds read warning
authorJesse Zhang <jesse.zhang@amd.com>
Tue, 30 Apr 2024 02:29:08 +0000 (10:29 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 30 Apr 2024 14:04:09 +0000 (10:04 -0400)
commit12c6967428a099bbba9dfd247bb4322a984fcc0b
tree25c22a4f5799abcb5a6eb89a4a3feb0b5d28dc74
parent6e46b89f40e39e2054f2e179e8e8c3132e7a9d57
drm/amd/pm: fix the Out-of-bounds read warning

using index i - 1U may beyond element index
for mc_data[] when i = 0.

Signed-off-by: Jesse Zhang <Jesse.Zhang@amd.com>
Reviewed-by: Tim Huang <Tim.Huang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/pm/powerplay/hwmgr/ppatomctrl.c