Repository navigation
drm/asahi: test G14 27.2 pool encoding across a failed publication - #3531
Conversation
Exercise the production CommandPool encode_with() and mark_published() bodies with host-backed GPU arrays. Fail the in-flight reservation after encoding, retry repeatedly, and verify that the last published command and other slots remain intact across both buffer parities. Also cover an encoder error and rotation after successful publication. Register both tests and negative controls that move rotation to encode time or remove publication rotation; both compile and fail on command preservation assertions. Signed-off-by: Ryan Murray <ryan@aurorasilicon.org>
There was a problem hiding this comment.
Verdict: MERGE at 6316e007
Blockers: none (wait for the queued host-tests, pr-text, and readiness CI checks to finish green and coordinate with GPU maintainers before merge)
Checked: no Apple material, no AI attribution, human DCO Signed-off-by, host-test-only change (+178/-0 across tools/asahi/g14-v27-2-pool-tests.py and tools/asahi/run-host-tests.py, zero kernel runtime changes — no hardware row required), exercises production CommandPool::encode_with() and CommandPool::mark_published() from drivers/gpu/drm/asahi/gpu/v27_2.rs across failed publication, repeated retries, encoder errors, and buffer rotation with two negative mutations (flip-on-encode, no-publish-flip) wired into ASAHI_TESTS, author verified 2/2 new tests + 24/24 G14 ABI tests + 4/4 host runner jobs + checkpatch --strict clean, PR body has Tested: and Risk: two-way, branch is MERGEABLE against main.
Evidence
tools/asahi/g14-v27-2-pool-tests.py: extractsCommandPool,encode_with(),mark_published(),pool_command(),spare_buffer(), andCommondirectly fromdrivers/gpu/drm/asahi/{gpu/v27_2.rs,g14_v27_2_abi.rs,g14_v27_2_render.rs}and verifies across allPOOL_SLOTSand both parities that:- Failed reservation after
encode_with()reuses the spare buffer on retries, leaves the previously published command and all other slots byte-identical, and does not flippool.published. - Encoder error (
Err(EINVAL)) similarly preserves the published command andpool.published. - Successful
mark_published()flipspool.published ^= 1 << slotand rotates the nextencode_with()onto the prior buffer.
- Failed reservation after
tools/asahi/run-host-tests.py: registersg14-v27-2-pool-tests.pywith bothflip-on-encodeandno-publish-flipKILLmutations.- CI at
6316e007:host-tests,pr-text, andreadinesscurrentlyQUEUED.
|
Merge readiness at
Areas: Updated by pr-readiness on pushes, edits, reviews and comments, and on a schedule. Rules: merge policy · labels. |
|
code-owner ping <@422957901716652033> / @DjDeveloperr: merge train at |
|
Merging under the 6-point rule (Ryan 09:29, permanent), at |
What: Adds the test Dj asked for on linux#3182: the G14 27.2 CommandPool encode_with() and mark_published() paths are exercised across a failed publication. After a failed in-flight reservation and repeated retries, the last published command and the other slots stay intact in both buffer parities. It also covers an encoder error and rotation after a successful publication. Test-only change.
Tested: Host tests: the new regressions pass 2/2 and the existing G14 ABI tests pass 24/24. Two negative controls (rotation moved to encode time, or publication rotation removed) compile and fail on the command-preservation assertions. The targeted host runner passes 4/4 jobs. Strict checkpatch is clean.
Risk: two-way · tools/asahi host tests only. No kernel code changes.
Not yet: nothing; no hardware row is needed for a host-only test.
Details
The test runs the production pool code with host-backed GPU arrays. This is Dj's area, so it waits for his look before merge.
Evidence
Source item: M2GPU-NEXT.md:591 (Dj review nit on #3182).