Repository navigation
drm/asahi: carry G15 submission fixes and T6030 PMP votes with host coverage - #253
Conversation
Include zero in the firmware stamp cycle. Keep absent dependencies and completed progress separate from wrapped zero stamps. Generated-by: LLM Signed-off-by: Eryk Wieliczko <eryk@wieliczko.ninja> (cherry picked from commit d82144a) Signed-off-by: Chris Kearney <303316+chriskearney@users.noreply.github.com>
Idle VMs must not reserve hardware ASIDs. Bind without waiting at publication, release at successful retirement, and retain failed published jobs. Logical VM creation is limited by memory rather than slot count. Generated-by: LLM Signed-off-by: Eryk Wieliczko <eryk@wieliczko.ninja> (cherry picked from commit 8525dd8) Signed-off-by: Chris Kearney <303316+chriskearney@users.noreply.github.com>
Each range check and stream read relocked the VM and all external BOs. Share one exec lock across validation, preserving permission checks and cache maintenance, and propagate acquisition errors. In profiled 10-second vkQuake runs, kernel CPU time falls from 3.30 to 1.01 seconds. The bounded validation walk holds VM and external BO reservations together, so other users of shared buffers can wait. Generated-by: LLM Signed-off-by: Eryk Wieliczko <eryk@wieliczko.ninja> (cherry picked from commit 610cc54) Signed-off-by: Chris Kearney <303316+chriskearney@users.noreply.github.com>
The RTKit AGX vote does not set the PTD power request. PMP receives GPU performance-state updates but ignores its bandwidth demand without that request, leaving memory at its idle floor. Report AGX power after firmware and backend initialization. An earlier report is acknowledged but does not enable bandwidth scaling. Reassert it so a failed early power-off cannot leave a stale report across startup. Use the report driver's lock and checked soc-device table, and clear the report before releasing the vote. Other SoCs keep their existing path. With Mesa unchanged, the packaged kernel takes vkQuake from 104.5 to 372.5 FPS at 1920x1080 and compute-copy bandwidth from 32.7 to 136.3 GB/s. Tested on an M3 Pro J514S. Generated-by: LLM Signed-off-by: Eryk Wieliczko <eryk@wieliczko.ninja> (cherry picked from commit 8824dd6) Signed-off-by: Chris Kearney <303316+chriskearney@users.noreply.github.com>
Carry the host models forward with the publication-time binding API: provide Job::slot and a separate VM identity for PB growth, and pin the hw.rs golden after proving the only change removes MAX_VMS and its comment. Exercise production bind, release, completion and prefix-admission bodies with explicit modeled slot allocation. Cover retry on slot exhaustion, binding reuse, successful release, failed-job reference lifetime and an append failure after publication, with five additional runtime mutants. Model the T6030 PMP readiness service in the retention harness. Cover readiness failure with and without orphan allocation, successful startup, and exclusion on other platforms, with two additional runtime mutants. Retain the existing failure and removed-fix controls. Clarify last-reference versus fail-stop retention in the ownership comments and format the carried compute match arm. These edits change no production admission, firmware identity, power policy or submission behavior. Generated-by: LLM Signed-off-by: Chris Kearney <303316+chriskearney@users.noreply.github.com>
The complete tools job found two more host fixtures that predate the T6030 PMP export changes. display26 lacks OF compatibility lookups and GFX-report service definitions; the supplier harness lacks the new report-check and report-update boundaries. Keep display26 on its modeled J613 platform and fail explicitly if it reaches a T6030 report. Model the supplier harness report service under the existing lock, exercise a forwarded report-check error, and require that power-on does not start bandwidth tracking before backend READY. Add a runtime mutant that drops the report-check error. Retain the existing configuration, supplier, readiness and serialization mutants. The production report transaction remains covered separately by the G15 PMP-vote selftest. No production code changes are made here. Generated-by: LLM Signed-off-by: Chris Kearney <303316+chriskearney@users.noreply.github.com>
maralcbr
left a comment
There was a problem hiding this comment.
Approving at 5af49598. Thanks @chriskearney for carrying this, and @erykwieliczko for the original work.
- The four carried commits have the same stable patch IDs as
d82144ad,8525dd8e,610cc54aand8824dd6a, and keep Eryk's authorship. The production delta from the follow-ups is one rustfmt arm inengine.rsand the ownership comments injob.rs,uat.rsandvm.rs, which fixes the doc nit from my #233 review (failed jobs keep their slot until the last reference drops, and until reboot only after a fail-stop). - The fixture repairs still extract the production bodies, and the new mutants target real safeguards. The input-error mutants cover binding/completion/prefix admission, retention catches an ignored PMP readiness error and PMP on another platform, and the supplier fixture catches a discarded report error. The zero-words hash change is only the
MAX_VMSremoval. - The PMP vote stays T6030-only:
pmp-export.c:74-81gates on the machine, supplier, command and AGX ID, andpmp-report.c:1303-1332checks them again. Reporting runs only after the backend starts, and a failed power-off tries to restore the report and keeps the original error.
Fine as follow-ups, not blockers:
- At the stamp wrap,
encode.rs:490still sends a literalWAIT = 0forStampbarriers. Naeem's J516C run covered a compute-only wrap. TA→FS, FS→compute and mixed wraps with dependent output are still unchecked. - A job resuming on a different ASID is still untested. The rebind path updates the context and invalidates the changed ASID (
mmu.rs:2807-2836), so this is coverage only. - This lifts the 63-live-VM cap, which is the intended admission change. Queue limits (
MAX_QUEUES= 58) still apply, and robust isolation stays single-slot.
This carry binary hasn't been booted. The hardware evidence is still the #233/#238 runs. Once this lands, #233 and #238 can be closed as superseded.
|
@malik-na — source pointers and the proposed M3 Max investigation from the TXT, in an attachment-free form for your agent. This is a follow-up hypothesis to the merged T6030 work, with no new Max performance result claimed. For Naeem's agent: investigating a possible M3 Max GPU power/bandwidth bottleneck The concrete lead Eryk's M3 Pro fix found that powering the GPU through RTKit was not enough to enable PMP's GPU bandwidth controllers. T6030 also needs the PTD/PMP report asserted after the GPU backend starts. This is a useful hypothesis to investigate on T6031/M3 Max; it is not evidence that the Max has the same fault or will gain the same amount. The change is merged through #253 and is included in integration merge 30a6518: Read these exact source paths at 30a6518:
Proposed investigation Start with a reproducible native-driver baseline: exact kernel/Mesa/Stage2 versions, mapped native libraries, fixed resolution/settings and repeat timings. Compare on the same display/presentation path. Record output correctness and GPU faults alongside speed. Then distinguish GPU clock, memory bandwidth, CPU submission and presentation limits using existing supported telemetry/profiling. A Max with more GPU cores can still be held back by memory bandwidth or a CPU-side queue. First establish which resource is limiting the workload. Inspect the existing T6031 power-domain/PMP/report setup and compare its intended bandwidth-vote lifetime with the T6030 sequence. If evidence shows a missing report or vote, implement the SoC-specific equivalent with validated T6031 suppliers, table entries and ordering. Keep the existing firmware/admission checks and error handling. A blind expansion of the T6030 compatibility guard is not a valid port. If clocks and bandwidth are already correct, investigate shader/compiler scheduling, synchronization and CPU submission overhead. Shared G15 stamp, slot-lifetime and locking changes are already carried in #253; measure the remaining bottleneck rather than duplicating those fixes. Validate a proposed change with the same repeated workload, native GL/VK output checks, error/fault logs and power-transition behavior. Separate a measured bandwidth improvement from a general GPU speedup. Mixed-workload stamp wrap and different-ASID resume remain separate nonblocking coverage follow-ups from the carry review. What the existing evidence does and does not show Our original combined M3 Pro kernel/Mesa test improved the recorded Quake case from 186.5 to 658.7 FPS. Both components changed together; this does not isolate PMP's contribution or predict a Max result. The benchmark method and results are public here: Mesa#17's restored conditional rendering, unified layouts, memory-budget reporting and 16 descriptor sets are G15S/M3 Pro-specific. They are feature exposure, not a generic Max performance switch. M3 Air (T8122/G15G) also requires its own diagnosis and verified power-controller interface. A useful result would identify the limiting resource, the exact T6031 mechanism involved, before/after measurements with driver attribution, correctness/regression evidence, and any remaining uncertainties. No new Max or M3 Air performance measurements are claimed by this brief. |
This carries Eryk Wieliczko’s G15 submission and T6030 PMP work from #233 and #238 onto
integration/aurora, repairing the host fixtures that blocked the original stack’s CI. The original four commits retain Eryk’s authorship, sign-offs andcherry-pick -xprovenance; their stable patch IDs match the originals. The original PRs and branches remain untouched.Original commits:
d82144ad56a8: wrap G15 stamps through zero.8525dd8e380a: acquire VM slots at publication and retain failed published bindings.610cc54ad498: lock G15 mappings once per submit.8824dd6a7aaa: report T6030 GPU power to PMP after backend initialization.Behavior carried from #233: VM creation no longer reserves a hardware slot for the lifetime of each VM, removing the 63-live-VM cap. With
robust_isolation=1, VMs can share the one execution slot with the existing ASID invalidation on switches. Queue and other resource limits still apply.The follow-up repairs six host fixtures: PB growth models the current job slot/VM identity API; the zero-word golden changes only for removal of
MAX_VMSand its comment; input-error tests exercise production binding/completion/prefix bodies; retention tests model the new PMP readiness service. Five new binding mutants and two new PMP mutants must compile and fail their intended runtime assertions. The J613 display/PMP fixture now supplies the OF lookups and rejects unexpected T6030 report calls. The PMP supplier fixture models the new GFX-report service under the existing lock, verifies error forwarding, and adds a mutant that discards its error. Its 33 runtime mutants compile and are killed; both controls pass across all three configuration combinations. Existing controls remain. Production follow-up edits only clarify ownership comments and format one match arm.Validation at
5af49598aac5ac3d6925b69a900d5417f7e84bd9:git diff --checkpasses. The two additional C suites also pass locally, making eleven relevant local suites.5af49598passes: CI self-test, plan, all six commit checks, device trees, compile, both complete host-test groups, full kernel package (including the Rust driver), KUnit, emulated boot/module loading and result. Attestation is normally skipped on pull requests.Hardware evidence remains the original stack’s evidence, documented in the #238 review. This rebased carry binary has not been booted. Host models do not qualify GPU scheduling, firmware timing or hardware ASID allocation.
Scope: shared G15 submission fixes apply to supported G15 paths. The PMP power/bandwidth fix is explicitly T6030 (M3 Pro); this is not an Air/Max performance claim or new board/firmware admission. Mesa #17 remains a separate PR: its extended Vulkan feature profile is G15S-specific, and its review evidence is recorded there. No firmware identities, display defaults or package pins are widened here. The separate J516C cold-boot review on #246 retains its own prerequisites.