drm/amdgpu/pm: Check input value for CUSTOM profile mode setting on legacy SOCs

[ Upstream commit df0a9bd92f ]

Check the input value for CUSTOM profile mode setting on legacy
SOCs. Otherwise we may use uninitalized value of input[]

Signed-off-by: Ma Jun <Jun.Ma2@amd.com>
Reviewed-by: Yang Wang <kevinyang.wang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
Ma Jun 2024-05-10 10:05:21 +08:00 • committed by Greg Kroah-Hartman
commit 58350786db
2 changed files with 7 additions and 3 deletions