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: drm/ast: Add timeouts to AHB/SCU polling loops to prevent soft lockups
Date: Sat, 16 May 2026 12:09:52 +1000	[thread overview]
Message-ID: <review-overall-20260513113949.356537-1-w15303746062@163.com> (raw)
In-Reply-To: <20260513113949.356537-1-w15303746062@163.com>

Overall Series Review

Subject: drm/ast: Add timeouts to AHB/SCU polling loops to prevent soft lockups
Author: <w15303746062@163.com>
Patches: 1
Reviewed: 2026-05-16T12:09:52.113846

---

**NAK — Patch is against a stale tree and the underlying code has been refactored away.**

This single patch targets two files (`ast_post.c` and `ast_2500.c`) to add timeouts to polling loops in `__ast_mindwm`, `__ast_moutdwm`, and `ast_2500_patch_ahb`. However, the code has been substantially refactored in the current drm-next tree:

1. **`__ast_mindwm` and `__ast_moutdwm` no longer contain polling loops.** They were moved from `ast_post.c` to `ast_drv.c` and rewritten to use `__ast_selseg` / `__ast_rdseg32` / `__ast_wrseg32` helpers. The old segment-selection polling loop (`do { data = __ast_read32(...) & 0xffff0000; } while (data != ...)`) now lives in `__ast_selseg()` at `ast_drv.c:63-67`.

2. **`ast_2500_patch_ahb` was also refactored** — it now uses symbolic register names (`AST_REG_SCU000`, `AST_REG_SCU000_PROTECTION_KEY`, etc.) instead of raw hex addresses (`0x1e6e2000`, `0x1688A8A8`). The patch's context lines reference the old raw-hex code and won't apply.

3. **There is also `ast_moutdwm_poll`** at `ast_drv.c:105-115` which has yet another unbounded polling loop using `cpu_relax()` — the patch doesn't address this one.

The underlying concern (unbounded polling loops that can cause soft lockups) remains valid, but a new patch would need to target the current code structure, addressing loops in:
- `__ast_selseg()` (`ast_drv.c:63-67`)
- `ast_moutdwm_poll()` (`ast_drv.c:112-114`)
- `ast_2500_patch_ahb()` (`ast_2500.c:136-139`)

---

---
Generated by Claude Code Patch Reviewer

      reply	other threads:[~2026-05-16  2:09 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-13  7:36 BUG: drm/ast: soft lockup due to missing timeout in hardware polling (ast_2500_patch_ahb) w15303746062
2026-05-13  7:50 ` Thomas Zimmermann
2026-05-13 11:39   ` [PATCH] drm/ast: Add timeouts to AHB/SCU polling loops to prevent soft lockups w15303746062
2026-05-16  2:09     ` 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-20260513113949.356537-1-w15303746062@163.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