From mboxrd@z Thu Jan 1 00:00:00 1970 From: Claude Code Review Bot To: dri-devel-reviews@example.com Subject: Claude review: accel/amdxdna: Remove drv_cmd tracing from job free callback Date: Thu, 04 Jun 2026 16:19:38 +1000 Message-ID: In-Reply-To: <20260529152837.1973405-1-lizhi.hou@amd.com> References: <20260529152837.1973405-1-lizhi.hou@amd.com> X-Mailer: Claude Code Patch Reviewer Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Overall Series Review Subject: accel/amdxdna: Remove drv_cmd tracing from job free callback Author: Lizhi Hou Patches: 5 Reviewed: 2026-06-04T16:19:38.908940 --- This is a single-patch fix for a real use-after-free bug in `accel/amdxdna`= . The analysis is correct: `job->drv_cmd` points to a caller-owned stack-lo= cal `struct amdxdna_drv_cmd` (e.g., the `cmd` variable in `aie2_hwctx_cfg_d= ebug_bo()` at line 907 and `aie2_hwctx_sync_debug_bo()` at line 979). After= `amdxdna_cmd_submit()` returns and the calling function finishes, that sta= ck frame is gone =E2=80=94 but the job may still be alive in the scheduler = and `aie2_sched_job_free()` can run later via the `.free_job` callback, at = which point `job->drv_cmd` is a dangling pointer. The fix is correct and minimal. The patch is straightforward and appropriat= e for a `Fixes:` tag. **Verdict: Looks good.** One minor observation below. --- Generated by Claude Code Patch Reviewer