feat(display): edid_lock policy axis — pin AMD connector EDID emulation while streaming #176

Merged
enricobuehler merged 2 commits from worktree-edid-lock-toggle into main 2026-08-12 13:12:17 +00:00
Owner

Productizes PR #54's adl-emul probe as the display-policy axis its description promised (this branch carries #54's commit — #54 can be closed when this merges).

What it does: a 13th EXPERIMENTAL DisplayPolicy axis, edid_lock (orthogonal like ddc_power_off/pnp_disable_monitors, default off). At the first Exclusive isolate — BEFORE the physicals deactivate, while an awake sink still answers its live-EDID read — the host pins each occupied AMD connector's EDID + ADL_EMUL_MODE_ALWAYS: the software equivalent of an HPD-holding dummy plug, attacking the standby-sink servicing class at its source (the KMD stops caring what the pins report). Unlocked at last-member teardown; crash-journaled (edid-lock-active.json + startup_recover) because pinned emulation outlives the process and can outlive a reboot. Inert without an AMD driver.

Architecture: the ADL FFI moved to pf_win_display::adl_emul — ONE surface shared by the probe tool and the host, so a reporter's display-disturb adl-emul run and the console toggle exercise byte-identical driver calls (the tool is now a thin bench-line printer over it, exit-code contract unchanged).

Console: the toggle renders ONLY when the GPU inventory lists an AMD adapter — the lever exists nowhere else, and a toggle that can never act is the "saved and then did nothing" trap the enforced-axes list exists to prevent. en+de help text; in-force badge; both fresh-policy builders carry the axis; axis-count guard test bumped 12→13; api/openapi.json regenerated.

Context (why still worth shipping after PR #173): the REALTIME-priority re-defaults in #173 eliminate the dominant metronomic stall class, but the standby-sink servicing class remains real for a subset (three RX 9070 XT field cases, one CLASS-1 adapter-freeze, Apollo's identical "Periodic Hiccups" folklore) — this axis is the A/B and mitigation for exactly that subset.

Validation (.173 native Windows + local): cargo check + clippy -D warnings (pf-win-display, pf-vdisplay, display-disturb), pf-vdisplay policy tests 34/34, mgmt openapi + display-settings guards green (the one other mgmt failure reproduces on unmodified main there — pre-existing box condition); full web console build (orval codegen from the new spec + tsc + i18n check 638 msgs en/de). Draft-#54's own validation ladder (adl rc evidence on a real 9070 XT) still applies before trusting the lever's effect.

Productizes PR #54's `adl-emul` probe as the display-policy axis its description promised (this branch carries #54's commit — #54 can be closed when this merges). **What it does:** a 13th EXPERIMENTAL `DisplayPolicy` axis, `edid_lock` (orthogonal like `ddc_power_off`/`pnp_disable_monitors`, default off). At the first Exclusive isolate — BEFORE the physicals deactivate, while an awake sink still answers its live-EDID read — the host pins each occupied AMD connector's EDID + `ADL_EMUL_MODE_ALWAYS`: the software equivalent of an HPD-holding dummy plug, attacking the standby-sink servicing class at its source (the KMD stops caring what the pins report). Unlocked at last-member teardown; crash-journaled (`edid-lock-active.json` + `startup_recover`) because pinned emulation outlives the process and can outlive a reboot. Inert without an AMD driver. **Architecture:** the ADL FFI moved to `pf_win_display::adl_emul` — ONE surface shared by the probe tool and the host, so a reporter's `display-disturb adl-emul` run and the console toggle exercise byte-identical driver calls (the tool is now a thin bench-line printer over it, exit-code contract unchanged). **Console:** the toggle renders ONLY when the GPU inventory lists an AMD adapter — the lever exists nowhere else, and a toggle that can never act is the "saved and then did nothing" trap the enforced-axes list exists to prevent. en+de help text; in-force badge; both fresh-policy builders carry the axis; axis-count guard test bumped 12→13; `api/openapi.json` regenerated. **Context (why still worth shipping after PR #173):** the REALTIME-priority re-defaults in #173 eliminate the dominant metronomic stall class, but the standby-sink servicing class remains real for a subset (three RX 9070 XT field cases, one CLASS-1 adapter-freeze, Apollo's identical "Periodic Hiccups" folklore) — this axis is the A/B and mitigation for exactly that subset. **Validation** (.173 native Windows + local): `cargo check` + clippy `-D warnings` (pf-win-display, pf-vdisplay, display-disturb), pf-vdisplay policy tests 34/34, mgmt openapi + display-settings guards green (the one other mgmt failure reproduces on unmodified main there — pre-existing box condition); full web console build (orval codegen from the new spec + tsc + i18n check 638 msgs en/de). Draft-#54's own validation ladder (adl rc evidence on a real 9070 XT) still applies before trusting the lever's effect.
enricobuehler added 2 commits 2026-08-12 13:10:22 +00:00
The standby-sink stall program's §3 dead-end list marked ADL EmulationMode
'likely Pro-gated' on field hearsay, with 'probe once, log rc' as the owed
falsification — never run. Three RX 9070 XT field cases later (ASUS
VG32VQ1B/DP, Odyssey G60SD/DP, LG UltraGear 32GS95UE/HDMI), this is that
probe, shippable to reporters: read-only caps/board-layout/connection-state
walk by default, --lock pins the live EDID + ADL_EMUL_MODE_ALWAYS on
occupied connectors (the software HPD-holding dummy), --unlock restores.
Every call prints the bench's epoch_ms correlation line with the decoded
ADL rc — ADL_ERR_NOT_SUPPORTED(-8) vs ADL_OK on consumer Adrenalin is the
Pro-gating answer, and a --lock run during a stream with the sink asleep
is the direct A/B for the metronomic stall class.

atiadlxx.dll is bound dynamically (absent = clean exit 2), structs mirror
adl_structures.h verbatim, and the probe touches only connectors the
board-layout walk enumerated. Gates: check/clippy -D warnings (msvc
cross-target) + fmt clean; native stub unaffected.
feat(display): edid_lock policy axis — pin AMD connector EDID emulation while streaming
windows / build (x86_64-pc-windows-msvc) (pull_request) Successful in 2m45s
apple / swift (pull_request) Successful in 1m45s
apple / screenshots (pull_request) Skipped
windows / build (aarch64-pc-windows-msvc) (pull_request) Successful in 1m14s
ci / web (pull_request) Successful in 1m27s
ci / bun-nix (pull_request) Successful in 34s
android / android (pull_request) Successful in 5m52s
ci / rust (pull_request) Failing after 7m55s
ci / docs-site (pull_request) Successful in 7m54s
ci / rust-arm64 (pull_request) Successful in 9m13s
nix / flake (pull_request) Successful in 14m26s
f4e39a442b
Productizes the adl-emul probe (the prior commit) as the display-policy axis its
PR promised: the ADL FFI moves to pf_win_display::adl_emul (one surface shared by
the probe tool and the host, so a reporter's probe and the console's toggle
exercise byte-identical driver calls), and an EXPERIMENTAL edid_lock axis joins
ddc_power_off/pnp_disable_monitors — orthogonal to presets, off by default.

At the first Exclusive isolate the host pins each occupied AMD connector's live
EDID + ADL_EMUL_MODE_ALWAYS (the software HPD dummy) BEFORE the physicals
deactivate; last-member teardown unlocks. Pinned emulation outlives the process,
so a crash journal (edid-lock-active.json) unlocks on the next host start,
mirroring the pnp_disable_monitors recovery. Inert without an AMD driver.

The console shows the toggle ONLY when the GPU inventory lists an AMD adapter —
the lever exists nowhere else, and a toggle that can never act is the 'saved and
then did nothing' trap the enforced-axes list exists to prevent.
enricobuehler merged commit 28b6633058 into main 2026-08-12 13:12:16 +00:00
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: unom/punktfunk#176