public inbox for drm-ai-reviews@public-inbox.freedesktop.org
 help / color / mirror / Atom feed
From: Claude Code Review Bot <claude-review@example.com>
To: dri-devel-reviews@example.com
Subject: Claude review: Re: [PATCH] drm/i915: Don't set min_cdclk in the initial crtc_state
Date: Mon, 25 May 2026 19:40:27 +1000	[thread overview]
Message-ID: <review-overall-ag91h3UbwPQ7cmXg@intel.com> (raw)
In-Reply-To: <ag91h3UbwPQ7cmXg@intel.com>

Overall Series Review

Subject: Re: [PATCH] drm/i915: Don't set min_cdclk in the initial crtc_state
Author: Ville =?iso-8859-1?Q?Syrj=E4l=E4?= <ville.syrjala@linux.intel.com>
Patches: 3
Reviewed: 2026-05-25T19:40:27.434712

---

This is a single-patch fix for a real display corruption bug on Gemini Lake (specifically an IdeaPad Duet 3). The analysis in the commit message is correct and the fix is sound.

**The core problem**: `intel_modeset_readout_hw_state()` computes and stores `crtc_state->min_cdclk` during initial hardware readout, and `intel_cdclk_update_hw_state()` then copies that value into `cdclk_state->min_cdclk[pipe]`. When the first atomic commit happens, `intel_atomic_check()` recomputes `new_crtc_state->min_cdclk` to the same value. The comparison logic in `intel_cdclk_update_crtc_min_cdclk()` (at `intel_cdclk.c:2941`) then sees `new_min_cdclk == old_min_cdclk` and returns 0 immediately — no CDCLK recalculation is triggered. If the BIOS/firmware left CDCLK at a frequency lower than `min_cdclk` requires, the display stays garbled.

**The fix**: By not setting `min_cdclk` during readout, both `old_crtc_state->min_cdclk` and `cdclk_state->min_cdclk[pipe]` start at 0. The first atomic check then sees a genuine change (0 → computed value), triggers CDCLK recalculation, and the clock gets bumped to the required frequency.

**Verdict**: The patch is correct and well-motivated. Minor observations below but nothing blocking.

---
Generated by Claude Code Patch Reviewer

      parent reply	other threads:[~2026-05-25  9:40 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-21 18:07 [PATCH] drm/i915: Don't set min_cdclk in the initial crtc_state Marius Hoch
2026-05-21 21:13 ` Ville Syrjälä
2026-05-22 13:33   ` Marius Hoch
2026-05-25  9:40   ` Claude review: " Claude Code Review Bot
2026-05-25  9:40   ` Claude Code Review Bot [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=review-overall-ag91h3UbwPQ7cmXg@intel.com \
    --to=claude-review@example.com \
    --cc=dri-devel-reviews@example.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox