Claude review: drm: rcar-du: Fix crash when no CMM is available

Claude Code Review Bot
2026-04-12T02:28:44Z

Overall Series Review

Subject: drm: rcar-du: Fix crash when no CMM is available
Author: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Patches: 2
Reviewed: 2026-04-12T12:28:44.829717

---

This is a single-patch fix for a NULL pointer dereference crash in the R-Car DU driver. The bug is straightforward: commit 3bce3fdd1ff2 refactored CMM handling to use a `struct rcar_du_cmm *cmm` pointer (which contains a `dev` field), but the null-checks were written as `rcrtc->cmm->dev` instead of `rcrtc->cmm`. When no CMM is present, `rcrtc->cmm` is NULL (it's only assigned at `rcar_du_crtc.c:1304` when `rcdu->cmms[swindex].dev` is non-NULL), so dereferencing it to access `->dev` crashes.

The fix is correct, minimal, and well-targeted. The Fixes tag, Reported-by, and Tested-by are all present. This is a clean bug fix suitable for merging.

---
Generated by Claude Code Patch Reviewer