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/sched: fix NULL deref when logging missing entity runqueue Date: Thu, 04 Jun 2026 11:58:59 +1000 Message-ID: In-Reply-To: <20260603025636.1301481-1-candice.li@amd.com> References: <20260603025636.1301481-1-candice.li@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: drm/sched: fix NULL deref when logging missing entity runqueue Author: Candice Li Patches: 5 Reviewed: 2026-06-04T11:58:59.136755 --- This is a single-patch fix for a real NULL pointer dereference in `drm_sche= d_job_init()`. The analysis is correct: `job->sched` is not initialized unt= il `drm_sched_job_arm()` (line 653), and furthermore `drm_sched_job_init()`= itself `memset(job, 0, ...)` at line 611 =E2=80=94 but that memset happens= *after* the `entity->rq` check, so at the point of the `dev_err()` call, `= job->sched` is whatever garbage the caller passed in (uninitialized memory)= . Dereferencing `job->sched->dev` is a guaranteed NULL or wild-pointer dere= ference. The fix is correct in substance. One minor style concern below. **Verdict: The fix is correct and should be applied, with a minor nit on th= e log format.** --- Generated by Claude Code Patch Reviewer