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/gem: Fix inconsistent plane dimension calculation in drm_gem_fb_init_with_funcs() Date: Sun, 12 Apr 2026 10:54:06 +1000 Message-ID: In-Reply-To: <20260409164156.2235189-1-ashutoshdesai993@gmail.com> References: <20260409164156.2235189-1-ashutoshdesai993@gmail.com> 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/gem: Fix inconsistent plane dimension calculation in drm_gem_fb_init_with_funcs() Author: Ashutosh Desai Patches: 4 Reviewed: 2026-04-12T10:54:06.081036 --- This is a single-patch fix for a real inconsistency between `framebuffer_check()` in `drm_framebuffer.c` and `drm_gem_fb_init_with_funcs()` in `drm_gem_framebuffer_helper.c`. The analysis in the commit message is correct: the open-coded truncating division can produce `height=0` for chroma planes when the framebuffer height is not evenly divisible by `vsub` (and likewise for width/hsub). The `(height - 1)` expression at line 186 then wraps as an unsigned integer, corrupting the `min_size` check. The fix is straightforward, correct, and aligns the GEM size validation with the dimension calculation already used by `framebuffer_check()`. **The patch should be accepted**, but it has process issues that should be addressed before merging. **Verdict: Needs minor revision (process tags), code change itself is correct.** --- --- Generated by Claude Code Patch Reviewer