Repository navigation
Conversation
d8686de to
66896ea
Compare
|
Per |
e539e32 to
6b4f1ee
Compare
|
Rebased onto the latest integration/aurora and removed the observed voltage endpoints from the commit message. Repeated J713 voltage values in the tests now use synthetic bins; existing base fixtures are unchanged. The rewritten commits remain unsigned. CI is running on the new head. |
bcd5763 to
bb1286d
Compare
RyanTheTide
left a comment
There was a problem hiding this comment.
-
Rebase onto the current integration/aurora. It conflicts in:
- drivers/gpu/drm/asahi/hw/t6041.rs, with 579bcc3 ("drm/asahi: run the 25G83 build on the 40-core M4 Max"). That commit splits the file into a shared
BASEand two firmware builds, and each of theirFirmwareBuilds needsboot_fields: &[]. - drivers/soc/apple/pmp-display.c and include/linux/soc/apple/pmp-display.h, with 6fde3b9 ("soc: apple: pmp-display: let the J713 DCP release its DISP vote").
- drivers/gpu/drm/asahi/hw/t6041.rs, with 579bcc3 ("drm/asahi: run the 25G83 build on the 40-core M4 Max"). That commit splits the file into a shared
-
The kunit failure on this head is not caused by this diff. It is
error[E0615]at drivers/gpu/drm/asahi/g17/buffer.rs:482 (ids.usedwhereQosIds::usedis a method), which comes from the old base. Re-run CI after the rebase. -
The description says the rewritten series has not been booted. Please add the J773g result for the rebased head that your test plan lists: PMP readiness, the AGX vote, firmware READY and a compute job.
bb1286d to
370ad38
Compare
|
Rebased onto integration/aurora 63be486; the head is now 370ad38.
|
|
J773g result for the rebased head What was booted. Boot
The DVFS rows and voltages match what our older J773g tree reports on the same unit. Why the handoff was limited to the Airs. The cause is our DTB. It is not this PR, and #1171 (31c3ec3, already in the base) behaves as designed. The DTB we boot was built before #1171. It wires Not covered yet: that rerun; exact |
370ad38 to
1c60450
Compare
|
Rebased onto current integration/aurora (3a7a3f9); no functional change. The only conflict was in |
1c60450 to
35565c1
Compare
|
Hardware test, Mac mini M4 (J773g), 2026-11-14: PASS for this PR's first five commits, Kernel:
The top commit |
35565c1 to
be82a6f
Compare
|
Restacked #1191 on #1718 at The branch now contains exactly the five retained #1191 commits directly on #1718 head The existing human-signed commits are patch-identical to the five retained commits from the previous branch:
#1718 is open at One boot of the exact composite Ethernet was absent because the exact DTB disables its PCI child and this tree does not include #1898. DRM reported This is one boot only. It does not cover suspend, other firmware versions, 27.x firmware, thermal behavior under load, long runs, or other boards. |
|
The production boot stub pins at macOS 27.2 (26B123), so please retarget this to 27.2. 25G83 is the 26.6.2 stub's GPU image; please take the J773g PMP and G16 path from the 27.2 stub. |
|
Hardware test, second Mac mini M4 (J773g, 24 GB), 2026-11-19: PASS for the five #1191 commits ( Setup: macOS 26.6.2 stub and aura 1.0.0b13 + boot-HDMI Stage 2. The DTB is 9125b31 + #1898 (Ethernet). Kernel is the linux-aurora 7.3.0-40 pin (9125b31) + #1898 + this stack + #2232, built natively with the distribution config. Release
Without #2232, #1718's digest does not match this machine (see #1718). Separate issue on this machine: #1865's fixed J773g CPU masks (P 0,3-5) reject its numbering (P 0,7-9). apple-pmp-thermal fails with -22, so the GPU cooling device stays at state 8 and G16 stays at S1. A fix that takes the clusters from the CPU nodes will follow in its own PR. 🤖 Generated with Claude Code |
|
On the J773g this series selects the eleven-row table (top S10 = 1578 MHz), but the G16 governor, the cooling ceiling and the pstate register check still stop at S9. As a result:
The fix is #2239: one commit on top of this branch's head (be82a6f). It takes the top state from the board table's row count for all three, so the ten-row J713/J604 behaviour is unchanged. You're welcome to fold it into this PR instead, if you prefer that. 🤖 Generated with Claude Code |
iBoot writes into the 25G83 GPU TEXT it loads, and part of what it writes depends on the machine. Compared with build b000 (G16G B0) of armfw_g16g.im4p in 25G83, a Mac mini (J773g, 24 GB) loads a TEXT that differs in: - the header word at 0x224, which changes from boot to boot, and the DATA address at 0x23c; - the value of each of the 39 boot parameter records the header at 0x22c places from 0x5c8df to 0x5cb10 (a tag, a 32-bit length and the value): carveout addresses just below the top of DRAM, which follow the memory size, a per-boot slide and the entropy; - the entry count and body of the two 0x350-byte tunable tables at 0x5cb10 and 0x5ce60, which the shipped image leaves empty. The T8132 entries hash a loaded image with only the entropy or one record zeroed, so each fits the machines it was measured on, and G16 refuses this Mac mini's image with EINVAL. Add an entry that zeroes all of those ranges. Its digest is that of the shipped build b000 TEXT with the same ranges zeroed, and two boots of the Mac mini give the same digest, so it pins the 25G83 B0 code as Apple ships it rather than one machine's memory map, slide or tunables. Every other byte, including the record tags and lengths and the table headers, is compared as loaded. The existing entries are unchanged. A test checks the ranges' layout and that the digest selects the entry. Signed-off-by: Diljit Singh <hey@djdev.me>
The existing telemetry predicate already selects firmware-qualified T8132, including J773g, for endpoint 7. Name that condition for reuse by the PMP and GPU paths; this is a refactoring, not a change in admission. The misleading J713-only comments are corrected. A prior J773g bring-up stack required endpoint 7 to complete PMP probe; the current base already enables it on qualified T8132 machines. Assisted-by: LLM checkpatch Signed-off-by: Sean Dolbec <sdolbec1@gmail.com>
Use the shared retained T8132 predicate for the report readiness path. The prior test already selected the T8132 report for a compatible T8132 supplier on the qualified firmware path. The new predicate additionally requires the machine compatible apple,t8132; it does not newly enable J773g. Update the host fixtures to provide the same helper. A prior J773g bring-up stack sent and received an AGX request with its PMP report present. This refactoring has not been isolated on hardware. Assisted-by: LLM checkpatch Signed-off-by: Sean Dolbec <sdolbec1@gmail.com>
The existing bridge treats every firmware-qualified T8132 machine as J713 and requires a DISP record. Select J773g by its machine compatible and require its AGX record instead, so the GPU can use the retained PMP vote bridge without a DISP record. Reject display consumers on J773g; other T8132 boards retain their existing behavior. The fixed table shape and exact supplier checks remain in place, and an accepted AGX vote is retained until reboot. The exported functions keep their apple_pmp_j713_gpu_*() names to avoid Rust driver churn. A prior J773g bring-up stack logged bridge registration and acknowledged AGX requests on ten boots. That was a different implementation; this change has not been booted on hardware. Assisted-by: LLM checkpatch Signed-off-by: Sean Dolbec <sdolbec1@gmail.com>
Use the shared retained T8132 predicate at the G16 board check. The old apple_pmp_j713_board() already selected firmware-qualified T8132 machines, including J773g, so this is a rename with no admission change. The later handoff, firmware identity, DMA and hardware identity checks remain. A prior J773g bring-up stack admitted the handoff and reached firmware READY with subsequent changes; this rename was not isolated on hardware. Assisted-by: LLM checkpatch Signed-off-by: Sean Dolbec <sdolbec1@gmail.com>
The G16 driver builds its firmware DVFS table from the sixteen performance states of the original ADT, using a list of qualified ten-row index layouts: J713's (four single states, then six equal-voltage pairs) and J604's. The M4 Mac mini (J773g) has the J604 shape: five single states, five equal-voltage pairs and a single top state at 1578 MHz. That is eleven distinct rows, and the J604 layout drops the fifth low state to fit in ten. Keep every state on J773g. Add an eleven-row J773g layout and give each layout its row count. The board pins the row count it is qualified for, ten on J713 and J604 and eleven on J773g, and only layouts with that count are tried, so the J604 and J773g layouts of the same shape cannot be confused. The table holds up to eleven rows with a count, Main 0xfc0 carries that count instead of a constant 10, and the encoder's ceiling is the last row. Nothing changes on J713 or J604: their layouts and order are kept, the host tests' measured J713 ADT gives the same ten rows, the J604-shaped case still selects the J604 layout on a ten-row board, and the qualified initdata goldens still match at ceilings 1, 4 and 9. The host tests use synthetic voltage bins rather than a measured chip's, and substitute them into those goldens before comparing; every other byte is compared unchanged. The runtime ceiling policy is unchanged: it publishes at most S9, and the hardware performance state is still refused above 9. On J773g the top row (S10, 1578 MHz) is in the tables but never requested; using it needs evidence of its own. The reported maximum frequency is the top row's. Tested on a J773g, on an earlier integration/aurora (19f71a1), with a voltage-grouping selection that gives the same rows as the J773g layout: the live ADT gave eleven rows, main/auxiliary 0/0, 338/338, 618/618, 796/796, 928/928, 1056/952, 1170/1053, 1278/1152, 1338/1204, 1470/1326 and 1578/1578 MHz. Voltage bins differ per chip; the table is selected from its ADT. The firmware accepted these tables, reached READY and completed a compute job. This layout-based version has not been booted on hardware. Assisted-by: LLM checkpatch Signed-off-by: Sean Dolbec <sdolbec1@gmail.com>
The utilization governor, the cooling ceiling and the check of the GPU's reported performance state all stopped at S9, the top row of the ten-row J713 and J604 tables. The J773g (Mac mini) table has eleven rows. Its top state S10 runs at 1578 MHz. Initdata already initializes that state and names it the ceiling, but the governor never asked for it, so a busy GPU ran at 1470 MHz. Take the top state from the board's firmware table and use it for the governor's load target, the configured ceiling and the bound on the pstate register. A reported state above the table's top is still a protocol error. Before this change, publishing S10 made the next register check fail-stop the GPU with EPROTO. Cooling keeps one state per level below the top, and S1 at full cooling on every table. The ten-row tables behave exactly as before. Signed-off-by: Diljit Singh <hey@djdev.me>
The retained T8132 PMP session follows apple_t8132_firmware_path(),
which admits the Macs on OS firmware 26.6.2 only. On another firmware
the PMP owner does not keep the session the boot loader left running
and its own start fails ("RTKit: IOP power acknowledgment failed:
-62"), as on a J773g on the macOS 27.2 stub.
The PMP is already running when Linux starts, whatever the firmware:
select the retained session by the SoC. With it go, on every T8132 and
any firmware: the bridge registration in pmp-display.c, the report
readiness wait, the telemetry endpoint, apple_pmp_keep_bound() (the
owner is not unbound) and the owner's latch that treats a message it
cannot handle as fatal.
The bridge registration no longer asks which board it is on: it needs
the exact PMP node with an AGX or a DISP record in
apple,tunable-soc-device, whichever the tree carries, and a vote of
either kind is refused without its record. Its log line names the
record instead of a board.
G16 does not follow. asahi_g16_board(), asahi_g16_perf_rows() and the
AGX vote entry points stay on the 26.6.2 firmware path through
apple_pmp_t8132_g16_board(), so no GPU is admitted, and no AGX vote
sent, on a firmware it was not run on.
An earlier form of the head commit (`9e699c3d`) ran on one J773g off
26.6.2; no other T8132 board has run it.
Assisted-by: LLM
Signed-off-by: Sean Dolbec <sdolbec1@gmail.com>
be82a6f to
423a6c7
Compare
Codex Review Summary: ❌ FailedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
Thanks for carrying this series through many rebases, and for the detailed J773g results. One convention point on the new DVFS table selection. We select behaviour by a hardware property, not by the list of machines it was run on, and this adds two board compares:
The same goes for the DISP consumer: the J773g has no internal panel, so the absence of the DISP record or of a display consumer node should select it rather than the board name. We can run no-regression rows on our lab Macs. |
Two selections in this series compare the machine name. The G16 firmware table has ten or eleven rows and the row count was taken from the board: eleven on the J773g, ten elsewhere. The count follows from the shape of the machine's own ADT performance states: four low states and six equal-voltage pairs give ten rows, five low states, five pairs and a single top state give eleven. Derive it from that. data::select_named() tries the two shapes and no longer takes a row count, and asahi_g16_perf_rows() is gone. This changes the J604: its ADT has the eleven-row shape, and the ten-row selection it had left its fifth low state out only because ten rows were thought to be the firmware's limit. It now gets eleven rows like the J773g, on which eleven rows and the top state S10 were run. No J604 has run this. The J713 shape keeps ten. The DISP vote was refused on the J773g by name. What it has is no internal panel: the DISP consumer is an available main DCP without apple,connector-type. The PMP table cannot decide this; the J773g's carries a DISP record as well as an AGX one. The layouts are named by shape, so the DVFS log line reads "(5+5 pairs+top layout)" where it read "(J773g layout)". Assisted-by: LLM Signed-off-by: Sean Dolbec <sdolbec1@gmail.com>
|
Pushed as b58acd5 on this PR: the row count is derived from the shape of the ADT performance states, and the DISP consumer is an available main DCP without |
|
Thanks for b58acd5: the row count from the shape of the ADT states and the DISP consumer from the main DCP's |
The runner fails the whole run when a tools/asahi test file is not in its table, so that a test cannot be silently skipped. The DISP consumer test added with the DVFS row derivation was not registered: the host test job stops before it runs anything. Register it. It takes no arguments and has no mutation control. Assisted-by: LLM Signed-off-by: Sean Dolbec <sdolbec1@gmail.com>
This branch is #2232's commit (unchanged), the five commits of this PR (unchanged), #2239's commit (unchanged), the session commit, and one new head commit (
b58acd59) that replaces the two board compares asked about in review.Dependencies
Head commit: "soc: apple: pmp-display: retain the T8132 PMP session on any firmware"
Widened to every T8132 on any OS firmware: the retained session, i.e. the bridge registration, the report readiness wait, the telemetry endpoint,
apple_pmp_keep_bound()(the owner is not unbound) and the owner's latch that treats an unhandled message as fatal. The bridge registration no longer compares the board: it needs the exact PMP node with an AGX or a DISP record inapple,tunable-soc-device, and a vote of either kind is refused without its record (DISP is now checked as AGX was). Its log line changes fromJ773g PMP vote bridge ready; …/T8132 PMP vote bridge ready; …toT8132 PMP vote bridge ready (AGX record); retained existing PMP owner(orDISP,AGX+DISP): this is the line quoted in DjDeveloperr's results, so anything matching the old text must follow.Not widened: G16.
asahi_g16_board()and the AGX vote entry points (pmp_power_consumer()for AGX,apple_pmp_j713_gpu_prepare()and its two siblings) are onapple_pmp_t8132_g16_board(), which is the 26.6.2 firmware path as before.An earlier form of the head commit (
9e699c3d) ran on one J773g off 26.6.2; no other T8132 board has run it. It has not been run on 26.6.2.Tested
0564795eon soc: apple: t8132: apply the PMGR policy on any firmware #2317, one boot:RTKit: Initializing (protocol version 12),PMP firmware and endpoint ready, firmwarePMP started;380500000.pmpbound toapple_pmp,3803c0000.pmp-reporttoapple-pmp-report; no warnings;apple,tunable-soc-device: 4216 bytes, AGX and DISP records present (both pass the driver's identity checks); vote bridge not registered because registration is lazy: it is reached only from a consumer's prepare call (pmp_power_prepare()->apple_pmp_display_bound_owner()->apple_pmp_display_register()), and both consumers are on the 26.6.2 firmware path (apple_pmp_j713_display_prepare()throughapple_pmp_j713_board(),apple_pmp_j713_gpu_prepare()throughapple_pmp_t8132_g16_board()), besides the loader disabling the GPU node on that stub. So on 27.2 no vote, G16 or AGX code ran, by design. Without the head commit the PMP probe fails there with -62.9e699c3d,7bd83d9c) on soc: apple: t8132: apply the PMGR policy on any firmware #2317 gave the same PMP lines on the same machine, one boot each.e0835278/be82a6f7, not on this head.drivers/gpu/drm/asahi/): all build.pmp-agx-vote-tests.py,t6030-pmp-graph-tests.py,t6030-pmp-supplier-tests.py,pmp-native26-tests.pypass. Rust host tests:pmp-power-tests.rs3/3,g16/power/policy.rs12/12.Review of 2026-11-19 (two board compares): one more commit
The PR head
423a6c77+ one unsigned commit,b58acd59, "drm/asahi: g16: derive the DVFS rows and the DISP consumer from the tree". No machine has booted a kernel containing this commit.Row count (
glue.c:216). Derived from the shape of the machine's own ADT performance states;asahi_g16_perf_rows()and the board compare are gone. Four low states and six equal-voltage pairs give ten rows; five low states, five pairs and a single top state give eleven. Why the J604 had ten: its ADT has the eleven-row shape, and its ten-row selection left the fifth low state out because ten rows were thought to be the firmware's limit (the comment inboard/data.rssaid so); it was not a hardware cap, and I know of no cooling or other reason for one. So the J604 changes from ten rows to eleven with this commit, and no J604 has run it. If the J604 does need ten for a reason of its own, that reason should be a property of its tree; I did not invent one. #2239's top state follows the row count, so it becomes S10 on the J604 as on the J773g. No J604 ADT is in the tests: the J604-shaped source has the J604's values for states 0-3 and 5-15 and an invented state 4. There is no fallback to ten rows: if a J604's real state 4 fails the table checks, or its firmware refuses eleven rows, its GPU does not start.DISP consumer (
pmp-display.c:327). The absence of the DISP record does not hold: this J773g'sapple,tunable-soc-devicecarries both the AGX and the DISP record (dumped from the running machine). What is true is that it has no internal panel: the DISP consumer is now an available main DCP withoutapple,connector-type(a main DCP that drives a connector, as with #1192 on the J773g, or one that is not available, is none).The DVFS log line names the shape,
(5+5 pairs+top layout), where it read(J773g layout).Tests.
test-perf.pynow feeds two measured ADTs through the derivation, the J713's and this J773g's own (a new fixture with the six/arm-io/sgxproperties from the running machine, its hash pinned in the test as the J713's is), and asserts ten and eleven rows with the exact tables; a J604-shaped source gives eleven. A constant row count fails one of them. Newtools/asahi/pmp-disp-consumer-tests.py: six trees, and both constant mutants fail. Rust tests:policy.rs12/12,pmp-power-tests.rs3/3. The four PMP fixtures pass. The commit builds (W=1,drivers/gpu/drm/asahi/,drivers/soc/apple/).What ran on hardware: nothing of this commit. Both changed paths run only with the GPU enabled on the 26.6.2 firmware path. On our unit (27.2 stub) the loader disables the GPU node, so G16 never probes and the row derivation is never called, and no DISP consumer asks. The derivation was run on this unit's real ADT bytes on the build host instead (the fixture above; the GPU performance-state properties are the same on the 26.6.2 and 27.2 ADTs), giving eleven rows, top 1578 MHz. I did not build a test kernel to log it on the machine: that would need the ADT parser to run for a disabled GPU node, which is new code for no new information. Needed from others: a J773g on 26.6.2 (DjDeveloperr's) for the eleven rows through this commit, and a J604 for the change from ten to eleven.