From mboxrd@z Thu Jan 1 00:00:00 1970 From: Claude Code Review Bot To: dri-devel-reviews@example.com Subject: Claude review: drm/radeon/rs780: prevent division by zero in refresh rate calculation Date: Tue, 05 May 2026 10:36:35 +1000 Message-ID: In-Reply-To: <20260430104626.16230-1-evg28bur@yandex.ru> References: <20260430104626.16230-1-evg28bur@yandex.ru> X-Mailer: Claude Code Patch Reviewer Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit MIME-Version: 1.0 Overall Series Review Subject: drm/radeon/rs780: prevent division by zero in refresh rate calculation Author: Evgenii Burenchev Patches: 1 Reviewed: 2026-05-05T10:36:35.430377 --- This is a single-patch fix for a potential division-by-zero in the radeon RS780 DPM (dynamic power management) code. The problem is real: `drm_mode_vrefresh()` can return 0 in several edge cases (overflow in `check_mul_overflow`, or `clock == 0` with non-zero htotal/vtotal, or very small clock values that round to 0 in `DIV_ROUND_CLOSEST_ULL`), and `rs780_program_at()` divides by `pi->refresh_rate` in five places. The fix is straightforward and low-risk. However, there are some issues with the patch. **Verdict: Needs minor revision.** --- Generated by Claude Code Patch Reviewer