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/xe: Send 'none' recovery method for XE_WEDGED_MODE_UPON_ANY_HANG_NO_RESET
Date: Wed, 04 Mar 2026 07:31:28 +1000	[thread overview]
Message-ID: <review-patch3-20260303110556.3577612-4-raag.jadav@intel.com> (raw)
In-Reply-To: <20260303110556.3577612-4-raag.jadav@intel.com>

Patch Review

```c
+		if (xe->wedged.mode == XE_WEDGED_MODE_UPON_ANY_HANG_NO_RESET)
+			xe_device_set_wedged_method(xe, DRM_WEDGE_RECOVERY_NONE);
 		/* If no wedge recovery method is set, use default */
-		if (!xe->wedged.method)
+		else if (!xe->wedged.method)
 			xe_device_set_wedged_method(xe, DRM_WEDGE_RECOVERY_REBIND |
 						    DRM_WEDGE_RECOVERY_BUS_RESET);
```

**Issue 1: Unconditional override of pre-set method.** The new code unconditionally sets `DRM_WEDGE_RECOVERY_NONE` when the mode is `XE_WEDGED_MODE_UPON_ANY_HANG_NO_RESET`, regardless of whether a caller had already set `xe->wedged.method` via `xe_device_set_wedged_method()`. The old `if (!xe->wedged.method)` pattern respected pre-set methods. If `NONE` should always be used in this mode, this is fine but should be documented in the comment. If a caller could have legitimate reasons to set a different method even in NO_RESET mode, this would silently override it.

**Issue 2: Semantic mismatch with `WEDGED=none`.** As discussed in the overall review, `WEDGED=none` was designed for "device recovered, no action needed." Using it for "device permanently wedged, don't bother recovering" is a different semantic. In this mode, the device *does* need recovery (rebind) to become functional again - it's just that the intent is to leave it broken for debugging. A userspace daemon listening for wedged events and seeing `WEDGED=none` would reasonably conclude the device is fine, when it's actually non-functional.

**Suggestion:** Consider whether this debug mode should simply not send a uevent at all (since it's a debug-only configuration), or use a different signaling mechanism. Alternatively, if the uevent is needed for telemetry collection triggers, the documentation needs to be much clearer about the dual meaning.

---
Generated by Claude Code Patch Reviewer

  parent reply	other threads:[~2026-03-03 21:31 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-03 11:05 [PATCH v1 0/3] Update 'none' recovery method for DRM wedged event Raag Jadav
2026-03-03 11:05 ` [PATCH v1 1/3] drm/doc: Update documentation for 'none' recovery method Raag Jadav
2026-03-03 15:32   ` Rodrigo Vivi
2026-03-03 21:31   ` Claude review: " Claude Code Review Bot
2026-03-03 11:05 ` [PATCH v1 2/3] drm: Update log " Raag Jadav
2026-03-03 15:33   ` Rodrigo Vivi
2026-03-03 21:31   ` Claude review: " Claude Code Review Bot
2026-03-03 11:05 ` [PATCH v1 3/3] drm/xe: Send 'none' recovery method for XE_WEDGED_MODE_UPON_ANY_HANG_NO_RESET Raag Jadav
2026-03-03 15:34   ` Rodrigo Vivi
2026-03-03 21:31   ` Claude Code Review Bot [this message]
2026-03-03 21:31 ` Claude review: Update 'none' recovery method for DRM wedged event Claude Code Review Bot

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-patch3-20260303110556.3577612-4-raag.jadav@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