drm/amd/display: Fix Coverity INTEGER_OVERFLOW within decide_fallback_link_setting_ma...
authorjsg <jsg@openbsd.org>
Mon, 9 Sep 2024 09:00:17 +0000 (09:00 +0000)
committerjsg <jsg@openbsd.org>
Mon, 9 Sep 2024 09:00:17 +0000 (09:00 +0000)
From Hersen Wu
94b0689984dd6a9e9f2303a1510333d18204ba88 in linux-6.6.y/6.6.50
83c0c8361347cf43937348e8ca0a487679c003ae in mainline linux

sys/dev/pci/drm/amd/display/dc/link/protocols/link_dp_capability.c

index 5101c90..be8da8b 100644 (file)
@@ -528,7 +528,7 @@ static bool decide_fallback_link_setting_max_bw_policy(
                struct dc_link_settings *cur,
                enum link_training_result training_result)
 {
-       uint8_t cur_idx = 0, next_idx;
+       uint32_t cur_idx = 0, next_idx;
        bool found = false;
 
        if (training_result == LINK_TRAINING_ABORT)