drm/amd/display: Fix off-by-one error in DML
authorWesley Chalmers <Wesley.Chalmers@amd.com>
Wed, 28 Apr 2021 22:38:54 +0000 (18:38 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 19 Jul 2021 07:44:49 +0000 (09:44 +0200)
commitc71de31b2e0f4ef71cc69ba841aeac12519b3607
treeca5c5e6b00f46cfea217194b11111c462c0c10ff
parentafa06442d23d32e95e3336cf8ff366bdd8d590ee
drm/amd/display: Fix off-by-one error in DML

[ Upstream commit e4e3678260e9734f6f41b4325aac0b171833a618 ]

[WHY]
For DCN30 and later, there is no data in DML arrays indexed by state at
index num_states.

Signed-off-by: Wesley Chalmers <Wesley.Chalmers@amd.com>
Reviewed-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@amd.com>
Acked-by: Stylon Wang <stylon.wang@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/amd/display/dc/dml/dcn30/display_mode_vba_30.c