drm/amd/display: Check index for aux_rd_interval before using
authorAlex Hung <alex.hung@amd.com>
Fri, 19 Apr 2024 00:22:43 +0000 (18:22 -0600)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 2 May 2024 20:18:16 +0000 (16:18 -0400)
commit9ba2ea6337b4f159aecb177555a6a81da92d302e
tree0e56f5b5b5ad9b13cb924257800eb86bfb571f2e
parent3941a3aa4b653b69876d894d08f3fff1cc965267
drm/amd/display: Check index for aux_rd_interval before using

aux_rd_interval has size of 7 and should be checked.

This fixes 3 OVERRUN and 1 INTEGER_OVERFLOW issues reported by Coverity.

Reviewed-by: Rodrigo Siqueira <rodrigo.siqueira@amd.com>
Acked-by: Tom Chung <chiahsuan.chung@amd.com>
Signed-off-by: Alex Hung <alex.hung@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/link/protocols/link_dp_training.c