live: heartbeat sync 2026-10-21T17:49:41-07:00 (Refs #11)
This commit is contained in:
1 parent
c0d840a8bb
commit
017404aa51
30 files changed
+568
-109
No files matched your search
@@ -1,21 +1,21 @@
|
||||
---
|
||||
name: niri-monitor-flap-refresh-triage
|
||||
description: "Diagnose niri/amdgpu monitor failures on blankpad — panel dropping, wrong refresh rate, black/flickering output — and fix the refresh without reloading the compositor or logging Frank out."
|
||||
description: "Diagnose niri/amdgpu monitor failures on blankpad — panel dropping, wrong refresh rate, black/flickering output, letterboxed 1080p on an ultrawide — and fix the refresh without reloading the compositor or logging Frank out."
|
||||
---
|
||||
|
||||
# niri monitor triage: flaps, phantom modes, 60 Hz fallback
|
||||
# niri monitor triage: flaps, phantom modes, 60 Hz fallback, stale kernel mode list
|
||||
|
||||
Frank's reaction to a broken display is immediate and loud; the fix must never log him out.
|
||||
Box: `blankpad` (Cezanne APU, `card1`, s2idle only), compositor `niri --session` as a user unit.
|
||||
|
||||
## Step 1 — separate three different diseases (do this before touching anything)
|
||||
## Step 1 — separate the four diseases (do this before touching anything)
|
||||
|
||||
```bash
|
||||
niri msg outputs # name, mode, position, full mode list per output
|
||||
for c in /sys/class/drm/card*-*/status; do echo "$(basename $(dirname $c)) $(cat $c)"; done
|
||||
systemctl --user show niri.service -p ExecMainStartTimestamp -p NRestarts # did niri restart?
|
||||
journalctl --user -b --no-pager | grep -iE 'disconnecting connector|new connector|Page flip commit failed|DMCUB|falling back to preferred'
|
||||
journalctl -k -b --no-pager | grep -iE 'amdgpu|PM: suspend exit|\*ERROR\*'
|
||||
journalctl --user -b --no-pager | grep -iE 'disconnecting connector|new connector|Page flip commit failed|DMCUB|falling back to preferred|could not be found'
|
||||
journalctl -k -b --no-pager | grep -iE 'amdgpu|PM: suspend exit|\*ERROR\*|enabling link|DP_LANE_COUNT_SET|DP_LINK_BW_SET'
|
||||
```
|
||||
|
||||
Reading it:
|
||||
@@ -25,16 +25,25 @@ Reading it:
|
||||
- `configured mode M could not be found, falling back to preferred` → **config asks for a mode the panel does not offer**; the panel silently runs at EDID-preferred (usually 60 Hz). This is the one you can fix instantly.
|
||||
- Config mtimes older than the symptom + no `niri` restart ⇒ the config did not cause it. Say so explicitly; agents get blamed for display problems they didn't cause.
|
||||
|
||||
## Step 2 — the phantom-mode trap (niri fails soft, so it looks like hardware)
|
||||
## Step 2 — phantom-mode trap AND stale-mode-list trap (niri fails soft, so both look like hardware)
|
||||
|
||||
`output { mode "…" }` with a refresh the EDID never advertised does **not** error. niri logs a WARN and drops to `preferred` on every connect → janky 60 Hz ultrawide, blamed on the monitor.
|
||||
|
||||
Compare the requested mode against the panel's real list:
|
||||
Two different lies, told by two different layers. `output { mode "…" }` with an unavailable refresh does **not** error: niri logs a WARN and drops to `preferred` on every connect → janky 60 Hz ultrawide, blamed on the monitor. Check the requested mode against the panel's real list:
|
||||
|
||||
```bash
|
||||
niri msg outputs | sed -n '/<monitor name>/,/^$/p' | grep -E '^\s+[0-9]+'
|
||||
```
|
||||
|
||||
If the kernel list lacks modes the EDID advertises (e.g. 3440x1440 absent, largest mode 1080p), discriminate parser gap vs stale cache — **compare the kernel's EDID blob with sysfs and decode it**:
|
||||
|
||||
```bash
|
||||
command -v edid-decode # parse the live EDID: edid-decode /sys/class/drm/card1-DP-1/edid
|
||||
modetest -M amdgpu -c 2>/dev/null | awk '/connected[[:space:]]+DP-1/,0' \
|
||||
| sed -n '/value:/,/DPMS/p' # the 384-byte blob DRM actually holds
|
||||
```
|
||||
|
||||
- Blob good (all extension blocks present, native DTD visible via `edid-decode`) **and** mode list bad → **stale mode list cached from a corrupted AUX/DDC read during a flapped hotplug**. DRM rebuilds modes only on a clean re-connect, and every subsequent flap re-caches garbage. Software cannot force the rebuild — the fix is a monitor **power cycle** (unplug power ~30 s; needs Frank's hands), then re-apply the mode. Do NOT conclude "kernel can't parse this EDID" and do not edit config for it.
|
||||
- Blob itself degraded → AUX hardware read failure, same physical remedy, worse prognosis (cable/port).
|
||||
|
||||
## Step 3 — apply the mode WITHOUT a config reload (the no-logout path)
|
||||
|
||||
```bash
|
||||
@@ -43,7 +52,11 @@ niri msg outputs | grep -A1 '<monitor>' # confirm the new mode
|
||||
pgrep -c niri # compositor still alive, same PID
|
||||
```
|
||||
|
||||
`niri msg output …` is documented as temporary ("not saved into the config file") — it changes one output and cannot log the session out. Avoid `niri action reload-config` when Frank is working: it reloads his whole config.
|
||||
`niri msg output …` is documented as temporary ("not saved into the config file") — it changes one output and cannot log the session out. **`rc=0` proves nothing**: for a mode outside the kernel's published list niri exits 0 and silently no-ops — always re-read `niri msg outputs` to confirm. Avoid `niri action reload-config` when Frank is working: it reloads his whole config.
|
||||
|
||||
## Step 3.5 — flap census beyond the display: who else dies at the same second
|
||||
|
||||
Correlate DP flap timestamps against `journalctl -k | grep -E 'usb .*: (new |disconnect)|Synchronize Cache'`. A USB hub chain re-enumerating in lockstep with a DP flap means shared power/ground on the monitor or dock — and it identifies what else brown-outs (keyboard, webcam, USB SSD). `KT USB Audio` (idVendor 12d1 KTMicro) in the tree = the monitor's built-in DAC, i.e. the monitor's USB upstream port is in that hub chain. Kernel `enabling link 2 failed: 15` across *multiple boots* + `core_link_write_dpcd (DP_LANE_COUNT_SET/DP_LINK_BW_SET) failed` = physical layer (cable/dock/monitor PSU), not compositor, not config: prescribe cable swap / other input after a clean-boot power cycle, and say plainly which of the four diseases you did NOT fix.
|
||||
|
||||
## Step 4 — persist, and check you edited the file that is actually live
|
||||
|
||||
@@ -61,4 +74,4 @@ Desk config law (its own header): panels keyed by **EDID identity**, not connect
|
||||
|
||||
## Escalate honestly
|
||||
|
||||
Reboot clears DMCUB/EINVAL state → schedule it, don't take it. Persistent drops after a reboot → cable / dock / monitor DP-version setting, i.e. hardware, not config. Report which of the three diseases you found and which you did **not** fix.
|
||||
Reboot clears DMCUB/EINVAL state → schedule it, don't take it. Persistent drops after a reboot → cable / dock / monitor DP-version setting, i.e. hardware, not config. Report which of the four diseases you found and which you did **not** fix.
|
||||
Reference in new issue
Block a user