From mboxrd@z Thu Jan 1 00:00:00 1970 From: Claude Code Review Bot To: dri-devel-reviews@example.com Subject: Claude review: tracepoint: Add trace_call__##name() API Date: Wed, 25 Mar 2026 07:48:30 +1000 Message-ID: In-Reply-To: <20260323160052.17528-2-vineeth@bitbyteword.org> References: <20260323160052.17528-1-vineeth@bitbyteword.org> <20260323160052.17528-2-vineeth@bitbyteword.org> X-Mailer: Claude Code Patch Reviewer Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Patch Review **LOCKDEP assertion missing from `trace_call__##name()`** In `__DECLARE_TRACE`, the existing `trace_##name()` includes a LOCKDEP RCU-= watching assertion: ```c if (IS_ENABLED(CONFIG_LOCKDEP) && (cond)) { WARN_ONCE(!rcu_is_watching(), "RCU not watching for tracepoint"); } ``` The new `trace_call__##name()` in this patch omits it entirely: ```c static inline void trace_call__##name(proto) { __do_trace_##name(args); } ``` The cover letter claims "preserving all other correctness properties of the= normal path (RCU-watching assertion...)" but the implementation does not a= ctually do this. While one could argue the assertion already fired from the= preceding `trace_foo_enabled()` call (which does *not* check RCU watching = =E2=80=94 it only checks the static branch key), the LOCKDEP check in `trac= e_##name()` runs unconditionally regardless of the static branch, specifica= lly to catch RCU misuse even in testing where the tracepoint may not be ena= bled. Dropping it from `trace_call__##name()` changes debug-build behavior. The same concern applies to `__DECLARE_TRACE_SYSCALL`, though there `might_= fault()` *is* preserved, which is good. Consider adding the LOCKDEP check to both `trace_call__` variants, or expli= citly documenting in the commit message that it is intentionally omitted an= d why. **Commit message inconsistency**: The commit message says: ``` trace_invoke_foo(args); /* calls __do_trace_foo() directly */ ``` This still uses the old `trace_invoke_` naming from v1, but the actual API = is `trace_call__`. This should be updated to match. **Code looks correct otherwise**: The three insertion points (regular, sysc= all, stub) are the right places, and the stub correctly compiles to an empt= y function. --- Generated by Claude Code Patch Reviewer