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/nouveau/disp/r535: Add scanline position support + head state support Date: Tue, 05 May 2026 12:01:34 +1000 Message-ID: In-Reply-To: <20260429030348.3930866-1-lyude@redhat.com> References: <20260429030348.3930866-1-lyude@redhat.com> <20260429030348.3930866-1-lyude@redhat.com> X-Mailer: Claude Code Patch Reviewer Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Patch Review **Correctness: Good** The register offsets used in `gv100_head_rgpos` (0x616330, 0x616334) and `g= v100_head_state` (0x682064, 0x682068, 0x68206c, 0x682070, 0x68200c, 0x68200= 4) are display head registers that have been stable across GV100 and later = generations. The r535 GSP-RM path covers Turing (TU102) and later GPUs, all= of which are post-GV100, so these register offsets are appropriate. The ex= isting `gv100_head` function table (`gv100.c:300`) uses the exact same `.st= ate` and `.rgpos` functions, confirming compatibility. **The fix itself:** 1. `gv100.c` =E2=80=94 Removing `static` from `gv100_head_rgpos` and `gv100= _head_state` is the minimal change needed to export them. Good. 2. `head.h` =E2=80=94 The new declarations: ```c void gv100_head_state(struct nvkm_head *head, struct nvkm_head_state *st= ate); void gv100_head_rgpos(struct nvkm_head *head, u16 *hline, u16 *vline); ``` These are placed correctly alongside the other `gv100_head_*` declaratio= ns and match the function signatures in `nvkm_head_func`. 3. `r535/disp.c` =E2=80=94 The empty stub removal and wiring: ```c r535_head =3D { .state =3D gv100_head_state, .rgpos =3D gv100_head_rgpos, .vblank_get =3D r535_head_vblank_get, .vblank_put =3D r535_head_vblank_put, }; ``` Clean removal of the no-op `r535_head_state` and addition of `.rgpos`. T= he function table now mirrors `gv100_head` (minus `.rgclk` which isn't need= ed in the GSP path since GSP handles clock setup). **Minor nits (non-blocking):** - The header declarations use named parameters (`struct nvkm_head *head`, `= u16 *hline`) while the existing declarations in the same header use unnamed= parameters (`struct nvkm_head *`, `u16 *`). Compare with `nv50_head_rgpos`= at `head.h:48`. This is purely cosmetic and doesn't affect correctness, bu= t matching the existing style would be slightly cleaner. **Stable tag:** The `Cc: # v6.7+` is appropriate s= ince the Fixes tag points to the r535 initial support commit which landed i= n v6.7. **Reviewed-by worthy:** Yes. The patch is correct, minimal, and well-motiva= ted. --- Generated by Claude Code Patch Reviewer