Repository navigation
arm64: dts: apple: t6050: K114s bring-up: USB-C, N1, GPU, sound/AOP, ANE, MagSafe, USB4 - #3337
Conversation
… K114s and K116c The K114s and K116c had no USB, no Wi-Fi/Bluetooth and no PCIe: the shared t6050-k114-k116.dtsi disabled ATC1, nub-spmi-a0 and the PCIe host, and only the K114c and K116s described their N1 port and USB-C ports, each in its own copy. The boards' ADTs have the same apcie0 port 0 (registers, IRQ 1523, PERST# GPIO 80, N1 on dart-apcie0 streams 1-3), the same PD controllers (hpm1 at 0xa on nub-spmi-a0, hpm2 at 0xc on nub-spmi-a1, SN201202x) and the same atc-phy, usb-drd and dart-usb nodes on all four boards. So: - t6050-k114-k116.dtsi now describes PCIe port 0 with the N1, its wifi0/bluetooth0 aliases and PERST# pin 80. The board file defines the N1's firmware name and its board-id before including it; the platform ID is board-id << 16 | 0x6050. - The new t6050-k114-k116-usb.dtsi describes ATC1 (left-front) and ATC2 (right): PD controllers, combo PHYs, DWC3s, DARTs and the atcphy aliases. Boards include it after t6050-peripherals.dtsi, which defines nub-spmi-a1 for them. - K114c and K116s keep only their deltas: K114c the nub-spmi-a0 fault queue window, the MagSafe PD controller and the ATC2 router; K116s the SD reader on port 1 and the single nub-spmi-a1 window. - K114s (board-id 0x14) and K116c (board-id 0x06) include both. The K114c and K116s DTBs are byte-identical before and after, as are the other T6050 DTBs. The shared blocks are Joshua Warren's K114c and Jens Axboe's K116s descriptions. Signed-off-by: Ryan Murray <[email protected]>
…e PERST# pin The K board headphone jack change opens pins 134 and 139 (the CS42L84's interrupt and reset) in the shared K114/K116 pinctrl_ap list, and this branch opens pin 80 for PCIe port 0. Use the union, <0 80>, <81 53>, <135 4>, <140 81>, in both so they land in either order. Both pins read cleanly; only pin 112 takes an SError. Signed-off-by: Ryan Murray <[email protected]>
…d K116c The K114s and K116c keep the inventory GPU node of t6050-peripherals.dtsi, compatible "apple,agx-t6050". The boot loader's GPU hand-off looks for "apple,agx-g17s" under the "gpu" alias and drm/asahi does not bind the inventory node, so on a K114s the GPU is never enabled and there is no render node. The K114c and K116s each carry the same G17S description in their own file (t6050-k114c-gpu.dtsi, t6050-k116s-gpu.dtsi). The four boards' ADTs (live K114s 27.2, the K114c, K116s and K116c images) have the same GPU: - sgx: "gpu,t6050", reg 0x21_00000000 + 0x3fdc000 and 0x21_00d00000 + 0x177000, interrupts 2448-2451, 450, 2806, 2463, 2465; - gfx-asc: reg 0x21_02600000 + 0x88000, 0x21_02050000 + 8, interrupts [2798, 2797, 2800, 2799], role GFX, power-gates 614; - gfx1-asc: reg 0x21_02e00000 + 0x88000, 0x21_02850000 + 0x60000, interrupts [2802, 2801, 2804, 2803], role GFX1, power-gates 657; - pmgr GPX (+0x0) and AFR (+0x100) critical, GFX (+0x110) not. On the K114s the GPU ASCs' __TEXT (0x50000 + 0x54000) and fw-data bounds are the K116s's, which the loader checks against its builds. So move the description into t6050-k114-k116-gpu.dtsi and include it from all four boards. It also carries the K114c's apple,sleep-retained on ps_gfx: the G17 firmware stays live across suspend-to-idle on every one of these boards. The K116s keeps only its delta, the GPU on the PMP's GFX report entry, as its board runs the PMP. Everything stays disabled until the loader fills the reservations and enables it, as before. The K114c DTB and the other T6050 DTBs are byte-identical before and after; the K116s DTB gains only apple,sleep-retained on ps_gfx, which its sleep description already keeps always-on. Signed-off-by: Ryan Murray <[email protected]>
…AOP, add them to K114s The K114s has no internal audio card and no AOP: its DT leaves the jack codec, the sound card, the AOP and the microphone's ADMAC disabled. The K114c describes all of them in its own file, with its speakers. The live K114s ADT (27.2) describes the K114c's audio hardware node for node: - i2c2 audio-codec-output at 0x4b, audio-control,cs42l84, reset GPIO 0x8b (pin 139), interrupts [134, 1]; - i2c1/i2c3 audio-speaker* at 0x38-0x3d, six audio-control,sn012776, function-speaker-id0/1 GPIO 0x88/0x89 (pins 136/137), the shutdown line GPIO 0x6b (pin 107) and fault interrupt 106; - aop (reg 0x90600000, 0x90c00000), aop-exclave-mailbox 0x2d067c000 interrupts [585, 582], dart-aop 0x90fc0000 interrupt 616, admac-base-ns 0x93800000 interrupt 637 with 13 + 13 channels, admac-hp-mic-ec-proxy 0x2d3200000 dma-channel 0 and audio-hp-mic. The K114c and K114s static ADTs differ in none of these beyond phandles. So move the K114c's pin list, jack codec, sound card with its jack link, AOP and microphone ADMAC into t6050-k114.dtsi, the 14-inch chassis, and include it from both boards. The shared card is "apple,k114-macaudio", the K114 entry, which runs the jack only. The speakers stay with the K114c: its six SN012776 amps, their shutdown regulator and the "Speaker" link remain in t6050-k114c.dts, which also keeps its "apple,j714-macaudio" card. On the K114s the amps are not described and i2c1 and i2c3 stay disabled: speakerguardd refuses this board (its protection is not qualified), so its speakers stay off. The K114c DTB and the other T6050 DTBs are byte-identical before and after. Signed-off-by: Ryan Murray <[email protected]>
…add it to K114s The K114s has no Neural Engine: ane0, its three DARTs and ANE_SYS stay disabled. The K114c enables them with t6050-j714s-ane.dtsi and the fabric domains ANE_SYS depends on, in its own file. The live K114s ADT has the K114c's and J714s's engine: ane0 "ane,t8132exclave" at 0x3_08000000 + 0x2000000 with the ANE PMGR window 0x80900000 + 0x18000, interrupts [954, 967], pre-loaded = 1 (iBoot loads the personalized firmware), and dart-ane0 at 0x3_09800000, 0x3_09820000 and 0x3_09840000 (0xc000 each) with its DAPF at 0x3_09810000, interrupt 955. These are the inventory nodes of t6050-peripherals.dtsi. So move the K114c's ANE include and its fab0_piogw, fab8_soc and fab9_soc enables into t6050-k114.dtsi. As on the K114c, the engine stays off until the boot loader has filled its two firmware reservations from the ADT. The K114c DTB and the other T6050 DTBs are byte-identical before and after. Signed-off-by: Ryan Murray <[email protected]>
…USB4 router, add them to K114s The K114s describes neither its MagSafe 3 port's PD controller nor the right port's USB4/Thunderbolt router: the K114c has both in its own file, and t6050-max.dtsi and t6050-peripherals.dtsi describe the ATC2 router and its PCIe tunnel only for the boards they list. The live K114s ADT has the K114c's hardware here: - nub-spmi-a0: reg 0x8a188000, 0x8a184000 (the generation 4 fault queue) and 0x8a180000; hpm5 "usbc,sn201202x,spmi" at USID 8, port-type 17 (MagSafe), features-supported 3 (power in only); - acio2 "acio,v2" at 0x1_81f00000 (NHI), 0x1_81ac0000.. (rc and router blocks), interrupts 1655-1666, 1643-1654, 1672, gpio-lstx on AOP pin 0x51; dart-acio2 0x1_81a80000 interrupt 1670; acio-cpu2 0x1_81108000 and 0x1_81100000; - apciec2 "apciec,t6050" at 0x1c_70000000 with its root port blocks at 0x1_84020000.., interrupt 1469; dart-apciec2 0x1_84000000 interrupt 1470; - acio2 thunderbolt-drom identical to the K114c's (no UID). So move the K114c's nub-spmi-a0 fault queue window, hpm5, ATC2 router, DROM and router power states into t6050-k114-usb.dtsi, included after t6050-k114-k116-usb.dtsi by both boards. The K114s now defines T6050_K114S before its includes, as the K114c does, and the two board lists that guard the ATC2 router and its tunnel DART name it. The K114c DTB and the other T6050 DTBs are byte-identical before and after. The new K114s schema message (apple,t6050-pciec "port0") is the one the K114c and J714s already have for the same node. Signed-off-by: Ryan Murray <[email protected]>
|
Non-author review at Blocker
Checked
|
DjDeveloperr
left a comment
There was a problem hiding this comment.
Verdict at a381dc4017e9: changes requested, 1 blocker. The rebase is clean, and the shared K-board files move the K114c and K116s descriptions without changing them. The blocker is this PR's own dt-checks failure.
Blocker: dt-checks fails on two new DARTs without a power domain.
scripts/dtc/apple-dart-pd-check.pyreportst6050-k114sandt6050-k116c/soc@200000000/iommu@410000000(dart_apcie0): "disabled: no power-domains (new)".- It failed in CI at
cb414a5c4020. - I get the same two findings at this head from DTBs I built myself.
- It failed in CI at
- The cause:
pcie0is nowokayon these two boards and usesdart_apcie0throughiommu-map, anddart_apcie0names no power state. - The checker lets the existing copies of this node stand (K114c, K116s, J714s, J714c, J716c), but fails any new one. So a rerun won't turn it green.
- Fix: give
dart_apcie0the apcie0 DART's power state from the ADT. Doing it on the shared T6050 node would also clear the five existing T6050 findings. - If loader-trained ports are meant to run without one, that needs agreeing with the checker's owners first; this can't merge with the check red.
Checked
- Rebase:
main(ef29ad17facb) has no change to any T6050 file since this branch's base,66fbacc273c6. Its only DTS change is one line int8103.dtsi. The K114c ANE block and the K114s NVRAM partition are present. - DTBs: I built all 11 T6050 DTBs at
mainand at this head (cpp and dtc 1.8.1).- J714c, J714s, J716c, J716s, J775c, J775d, J873s and K114c are byte-identical.
- K116s gains only
apple,sleep-retainedonps_gfx, as the GPU commit says. It is a no-op there:t6050-k116s-sleep.dtsialready marksps_gfxalways-on, so genpd never powers it off. - The only new dtc warning is the ANE reserved-memory duplicate unit address on K114s, which K114c already has.
- N1 and USB-C:
- The new nodes are:
- PCIe port 0 with the N1: functions 0-2, PERST# on GPIO 80, DART streams 1-3;
hpm1andhpm2;- the ATC1 and ATC2 PHYs, mailboxes, DWC3s and DARTs.
- Every graph endpoint pairs both ways.
- K114s and K116c differ only in compatible, model, firmware names, platform ID (
0x146050and0x066050) and the K114s NVRAM. nub_spmi_a1keeps the three windows fromt6050-peripherals.dtsi, as K114c does. The binding allows three, and the driver uses reg[1] as the fault queue.
- The new nodes are:
- The 14-inch chassis on K114s:
- Everything this PR adds to K114s matches K114c's merged tree, except that K114s leaves out the speaker amps and the
Speakerlink. The other differences between the two boards were already onmain. apple,k114-macaudiois already in the binding, andmacaudio_k114_cfgkeeps the speakers off.- The jack codec uses pins 134 and 139, and
speaker-id-gpiosuses 136 and 137, all inside the new pin list. - Defining
T6050_K114Searlier only affects the intended ATC2 router guard int6050-max.dtsi. - The ANE, AOP and router DARTs pass the power-domain check.
- Everything this PR adds to K114s matches K114c's merged tree, except that K114s leaves out the speaker amps and the
- Commits:
- All six are signed off by the author, with no attribution.
checkpatch --strictgives 0 errors on each. Apart from the MAINTAINERS notes, which theapple/directory entry already covers, the warnings are:- in
a381dc4017e9, the two#if ... \continuations int6050-max.dtsiandt6050-peripherals.dtsi(over 100 columns, space-indented), and one 104-column comment int6050-k114-usb.dtsi; - in
cb414a5c4020, two commit-message lines over 75 characters.
- in
Not blocking
- On K116c, pins 134 and 139 are exposed with no user, since only the 14-inch files add the jack codec. The comment's "only the pins a node names are exposed" doesn't hold there yet.
- K116c (M5 Max) now gets
apple,agx-g17sas K114c does. The PR already flags the reconciliation with #2276, and the loader's ADT and firmware check keeps the GPU off if it doesn't match.
Before merge
- The blocker fixed and
dt-checksgreen. pr-textfixed in the PR description:- a
Tested:line with the Mac and the head SHA; Risk:saying one-way or two-way;- the Regression and Risk lines no longer saying K116s is byte-identical.
- a
- Rows at the exact head. The K114s rows don't name the SHA their DTB came from, and the branch was re-committed at 00:47 and again at 02:37-02:52 UTC.
- K114s: boot with a device on each port, including the right one; the N1 enumerating; the GPU, cards, AOP and MagSafe port as in the body.
- K116c: a first boot row for USB, the N1 and the GPU hand-off.
- Wi-Fi association, the speakers, the ANE start and USB4 with a device can stay under Still to run.
- No J-board rows are needed: their DTBs are byte-identical, and K116s's one change is a no-op.
…main With the K boards' PCIe port 0 described, pcie0's iommu-map makes the N1 use dart_apcie0, which names no power domain on any T6050 board, so the DART power-domain check flags it as a new user on K114s and K116c. The ADT's apcie0 power-gates start with APCIE_GP (137) and APCIE_SYS_GP (143); APCIE_SYS_GP sits on APCIE_GP and FAB6_SOC, as ps_apcie_sys_gp already says. dart_apcie0 now takes APCIE_SYS_GP, as the T600x/T602x PCIe DARTs take theirs. The boot loader trains port 0 and keeps it powered for the hand-off, so ps_apcie_sys_gp, ps_apcie_gp and ps_fab6_soc are enabled as firmware-owned. They are enabled in t6050-k114-k116-usb.dtsi because the boards include it after t6050-peripherals.dtsi, which defines them. The host node takes no power-domains: its binding allows none. Only the four K board DTBs change. Signed-off-by: Ryan Murray <[email protected]>
|
Hardware row at 1c71360, K114s (14-inch M5 Pro OLED), kernel 7.3.0-42.fc45 (linux a851ca0), DTB from this head in the board's own Stage 2 (aura 1.0.0b14), one-shot boot:
|
|
Merge readiness at
Areas: Updated by pr-readiness on pushes, edits, reviews and comments, and on a schedule. Rules: merge policy · labels. |
|
The dt-checks blocker from the a381dc4 review is fixed in 1c71360: dart_apcie0 now takes ps_apcie_sys_gp (the ADT apcie0 power-gates APCIE_GP 137 and APCIE_SYS_GP 143, the same as the T600x/T602x PCIe DARTs), and the APCIE states are firmware-owned because the loader trains port 0. apple-dart-pd-check.py against main: new 0. The K114s hardware row at this head is in the comment above. A re-review would be appreciated. |
RyanTheTide
left a comment
There was a problem hiding this comment.
Verdict: FINISH, then merge at 1c71360f65af
Blockers
arch/arm64/boot/dts/apple/t6050-max.dtsi:222andt6050-peripherals.dtsi:1620extend inverse board lists for the same ATC2 router and tunnel DART. Each new board with the same hardware must edit both lists to get the right node placement. Put the shared ATC2 layout in a reusable include selected by the boards that describe that topology. Keep oneapciec2_dartdefinition per DTB without extending the SoC-wide board lists.arch/arm64/boot/dts/apple/t6050-max.dtsi:460addsinterrupt-names = "port0"to the K114s DTB's newapple,t6050-pciecnode.Documentation/devicetree/bindings/pci/apple,pcie.yaml:583forbids that property for this compatible. This is a new violation on K114s even though existing boards have it. The T6050 tunnel driver looks up this IRQ by index, so drop the unused name from the shared node and compare the resulting DTBs and schema results.
Checked: The built K114s DTB contains the offending property and the baseline K114s DTB lacks the tunnel node. The port-0 DART power-domain fix is present and the left-front row names this head. The device-attached right-port row remains open.
The right-port USB4 PCIe tunnel (apciec2, apple,t6050-pciec) names its one interrupt "port0". The binding allows no interrupt-names for this controller, so every board that enables the node gets a schema warning; with the K114s now enabling it, CHECK_DTBS reports it as new there. pcie-apple looks interrupts up by name only for hosts that adopt a trained link (hw->adopt_link). t6050_pciec_hw does not, so it maps the port interrupt by index and never reads the name. Dropping the property changes nothing at run time. The J714c, J714s, J716c, K114c and K114s DTBs lose that one property; no other T6050 DTB changes. Signed-off-by: Ryan Murray <[email protected]>
There was a problem hiding this comment.
Verdict: FINISH, then merge at 0a57fc2e7019
Blockers: None in the change.
Checked: Compared this head with the prior reviewed commit, read the PCIe-C binding and traced the IRQ lookup. Current base-relative source still extends both lists for the same hardware. Reviewed the reported five-DTB comparison and zero new CHECK_DTBS messages.
Evidence
t6050-max.dtsi and t6050-peripherals.dtsi choose opposite variants of the ATC2 DART from duplicated lists. The only new commit since 1c71360f removes the unused name from a node whose driver uses IRQ index.
|
Right-port row (Dj's pre-merge ask), K114s, kernel 7.3.0-42, default boot with this PR's DT (1c71360; 0a57fc2 only drops an unused interrupt-names property). The dock was moved from the left-front to the right port while running:
Both USB-C ports this PR describes have now carried the same dock. K116c: no hardware; the K114s stands in through the same shared dtsi, and a Dj/Joshua row is welcome. |
ATC2's USB4/Thunderbolt router (ADT /arm-io/acio2 with its CPU and DART) was selected by two hand-kept board lists: a positive one in t6050-max.dtsi for the router and a negative one in t6050-peripherals.dtsi for the plain apciec2 DART. Adding a board meant editing both. Boards whose ADT has acio2 (J714c, J714s, J716c, K114c, K114s) now define T6050_ATC2_USB4_ROUTER before their includes, and both places test that. All T6050 DTBs are byte-identical before and after. Signed-off-by: Ryan Murray <[email protected]>
|
Review 6083429959 (two hand-kept ATC2 router board lists): done in 354734e. Boards whose ADT has acio2 (J714c, J714s, J716c, K114c, K114s) define |
Resolve t6050-k114c.dts against #1719 (the K114c SD card reader): port 0 and the N1 now come from t6050-k114-k116.dtsi, so the K114c keeps only its port 1 delta (the extra port registers, interrupt and dart-apcie1 stream, port01, dart_apcie1, the sd_pwr_en pcIO output and pin 81) after the includes. The K114c DTB equals main's plus this branch's port-0 DART power domain, firmware-owned port-0 states and router interrupt-name change. Signed-off-by: Ryan Murray <[email protected]>
|
Merged main into this branch at Checked by decompiling the DTBs:
The SD reader port on the K114c needs no new row (its node is unchanged from #1719). The K114s row stands for the shared files. |
|
Merge-train verdict at
Merging as Ryan's top priority for the next installer alpha. Follow-ups: a K116c boot row (Dj or Joshua), and the K116s s2idle row for |
Problem
The 14-inch M5 Pro MacBook Pro (K114s) boots with a nearly empty board DT:
On the shipped image, a dock stays dark and the desktop runs on llvmpipe. The K116c shares most of the USB-C/N1 gaps.
Change
Eight commits, all device tree, each checked against the live K114s ADT:
Testing
On a K114s (macOS 27.2 stub, Aurora alpha 25 install), each boot one-shot over a KIS tether, with the DTB swapped into its own Stage 2 (aura 1.0.0b14):
console=ttyDC0:apple-t6050-dp-phy 2ab000000.phystarts, and xHCI on 2aa280000 registers a USB 2 and a USB 3 bus./sys/class/typechas port0 (1-0a, left-front, data host, partner present) and port1 (2-0c, right, no partner).CONFIG_PHY_APPLE_T6050_DP, on main since 2026-11-24), which provides the DWC3 reset. So USB on these boards needs this tree with a kernel at or after that point.CHECK_DTBS=y) on K114s and K116c: no messages, before or after.glxinfo -Breports "Apple M5 Pro (G17S B1)", Accelerated: yes, OpenGL 4.6 core.apple,sleep-retainedon its GPU power domain, already always-on there).Still to run
apple/centauri/k114s-ftab.bin.Tested: K114s at 1c71360 (kernel 7.3.0-42): left-front dock enumerates (USB 3 Gen 2, Ethernet), MagSafe PD port registers, GPU G17S accelerated (GL 4.6), jack card + AOP mics + ALS/lid sensors, N1 adopted on port 0 with dart_apcie0 bound in its power domain, no deferred devices. Speakers stay off on K114s.
Risk: two-way · K114s, K116c (new: USB-C, N1, GPU and on K114s sound/AOP, ANE, MagSafe, USB4). K114c and K116s also change: they get the port-0 DART power domain and the firmware-owned APCIE states, and K116s gets apple,sleep-retained on ps_gfx. J714c, J714s and J716c only lose that unused interrupt-names property (commit 8); the other J boards are byte-identical.
Evidence and boot method
aura-proxyESP window, caught over KIS from a Linux host (kisd + tuxvdmtool). Its own ESP Stage 2 is then chainloaded in place with that boot'snvme.sartand the DockChannel console kept, and GRUB is driven over KIS. Nothing on the K114s disk changed for the 7.3.0-41 rows. The 7.3.0-42 row used the -42 modules unpacked in the Aurora root, plus an initramfs built there by dracut.sn201202x: waiting for the USB role switch(spmi 1-0a, 2-0c) anddwc3-apple: Failed to get reset control(2aa280000, 382280000).Supersedes #2280.