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/loongson: stop to set get_vblank_timestamp for 7A1000 CRTC Date: Mon, 16 Mar 2026 11:56:46 +1000 Message-ID: In-Reply-To: <20260314165421.1201790-1-zhengxingda@iscas.ac.cn> References: <20260314165421.1201790-1-zhengxingda@iscas.ac.cn> 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/loongson: stop to set get_vblank_timestamp for 7A1000 CRTC Author: Icenowy Zheng Patches: 1 Reviewed: 2026-03-16T11:56:46.669899 --- This is a single-patch series that removes the `.get_vblank_timestamp` callback from the `ls7a1000_crtc_funcs` table in the Loongson DRM driver. The stated rationale is that the 7A1000 display controller lacks hardware capability for vblank querying, and setting this callback misleads the kernel. However, the patch's rationale is questionable. The 7A1000 **does** have `get_scan_pos` hardware ops implemented (lines 289, 301 in `lsdc_crtc.c`), and the shared `lsdc_crtc_helper_funcs` (line 939) sets `.get_scanout_position = lsdc_crtc_get_scanout_position` for both 7A1000 and 7A2000 CRTCs. The `drm_crtc_vblank_helper_get_vblank_timestamp` function simply calls `get_scanout_position` from the helper funcs, so the 7A1000 does have the necessary plumbing in place. The patch may paper over a real bug rather than fix the root cause. The warning the author encounters is more likely caused by `drm_calc_timestamping_constants()` not being called before vblank timestamp queries are made, or by the mode's `crtc_clock` being zero when using firmware-injected EDID timings. Removing the timestamp callback entirely downgrades vblank precision for **all** 7A1000 users rather than fixing the actual issue. --- Generated by Claude Code Patch Reviewer