Repository navigation
Conversation
The M4 (T8132) Mac mini needs its NVMe controller, the SART, the SMC, the SPMI controllers, the PCIe controller and their DARTs and mailboxes before it can boot from its SSD and reach the network. Each block works with an existing generation's driver, so add the T8132 compatibles with the fallbacks T8122 and T8140 already use: - apple,t8132-dart (apple,t8110-dart) - apple,t8132-sart (apple,t6000-sart) - apple,t8132-asc-mailbox (apple,asc-mailbox-v4) - apple,t8132-smc (apple,t8103-smc) - apple,t8132-spmi (apple,t8103-spmi) - apple,t8132-pcie (apple,t6020-pcie), next to apple,t8122-pcie - apple,abbey-pmic (apple,spmi-nvmem), the T8132 main PMU A J773g runs today with these compatibles and fallbacks under GravityLinux's gravity-m4 kernel. The DART and mailbox lines are the same as in the open omacom/linux-aurora AsahiLinux#200 (T8132 SEP); whichever change lands second drops them. Signed-off-by: Sean Dolbec <sdolbec1@gmail.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Describe the T8132 System Management Controller and its ASC mailbox. The SMC's GPIO controller switches the power of the PCIe Wi-Fi port and the SMC handles power-off, reboot, the RTC and the power button, so every T8132 board needs it before it can run from its own storage and network. Both nodes stay disabled; a board enables them. [sdolbec: Ported from GravityLinux gravity-m4 commit be925f3 ("t8132 smc"), a cherry-pick of Yureka's commit d7525ca925b6 ("t8132 smc"). Renamed mbox@ to mailbox@ and added status = "disabled", as t8140.dtsi does. The original commit carries no Signed-off-by; it is forwarded here under DCO clause (b), and Yureka's Signed-off-by should be added before this is merged. The J773g runs these nodes, unchanged apart from the status, under that kernel.] Signed-off-by: Sean Dolbec <sdolbec1@gmail.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Describe the T8132 ANS2 NVMe controller, its SART and its mailbox. Signed-off-by: Yureka Lilian <yureka@cyberchaos.dev> [sdolbec: Ported from GravityLinux gravity-m4 79b86cb, a cherry-pick of Yureka's 9a864cea9329. Renamed mbox@ to mailbox@ and sart@ to iommu@ and added status = "disabled" to all three nodes, as t8140.dtsi does. Added the one-line description above.] Signed-off-by: Sean Dolbec <sdolbec1@gmail.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This tree's T8132 ANS2 support (apple_nvme_t8132_hw) maps the NVMMU from its own "nvmmu" resource and fails to probe without it. The T8132 ANS has two windows: the ADT's /arm-io/ans reg[9] is the NVMe controller and reg[3] is the NVMMU, the split m1n1 uses for every chip with nvme-secure-bar. On T8132 they are at 0x4c5cc0000 and 0x485cc0000, the same layout as T8140 (0x3cdcc0000 and 0x38dcc0000). Add the 0x60000 NVMMU window, which holds the TCB registers at +0x28100..+0x28120. Keep the controller window at 0x60000 rather than the 0x28000 the linear queue registers need: GravityLinux's driver reaches the NVMMU registers through this alias at the same offsets, and our J773g runs from its SSD that way today. Keeping the window lets one device tree boot both kernels, which matters while J773g owners move between them and as a fallback while this tree is tested. The window split follows KB2UKA's reading of the J713 ADT (Kb2uka/Omarchy-M4-Native, "fix(dts): t8132: split M4 NVMe and NVMMU windows"). This layout has not been booted with this tree's driver yet. Signed-off-by: Sean Dolbec <sdolbec1@gmail.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Describe the T8132 internal PCIe controller, its three root ports and the DART of each port. On the M4 machines port 0 carries the Wi-Fi and Bluetooth module, and on the Mac mini port 2 carries the Ethernet controller. Give the SoC bus the same dma-ranges as T8112, T8122 and T6030 so that devices behind DARTs get DMA above 4 GiB, and include gpio.h for the PERST# lines. Everything stays disabled. A board enables the controller, the ports it wires and their DARTs, and maps their requester IDs (iommu-map), because the stream IDs differ between boards. [sdolbec: Ported from GravityLinux gravity-m4 commit 9edf52c ("t8132 pcie") and commit bdafece ("t8132 wifi pwren"), cherry-picks of Yureka's commit 19103645439f ("t8132 pcie") and commit c59a7a826661 ("t8132 wifi pwren"). SoC part only; the board parts move to t8132-j773g.dts in a later commit. Changes: port labels pcie0_portN as in t8140.dtsi, status = "disabled" on the controller, its ports and DARTs, iommu-map left to the board, and the controller's power domain apcie_phy_sw instead of apcie_gp, which is what the J773g runs with today under gravity-m4 (changed there after these commits). The original commits carry no Signed-off-by; they are forwarded here under DCO clause (b), and Yureka's Signed-off-by should be added before this is merged.] Signed-off-by: Sean Dolbec <sdolbec1@gmail.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The main PMU of the T8132 machines sits on the nub SPMI bus at 0x388714000 (macOS: nub-spmi0). Its NVMEM holds the shutdown, boot-stage and RTC-offset cells that the SMC reboot and RTC drivers need: without the shutdown flag, the SMC's "off1" restarts the machine instead of powering it off. Add the controller, disabled, with its always-on nub_spmi0 power domain as t8140.dtsi does. Boards add the PMU and enable the bus. Signed-off-by: Sean Dolbec <sdolbec1@gmail.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… RTC Enable the SMC on the Mac mini and give it the reboot and RTC children, fed by the main PMU's (Abbey, SPMI 0xe) NVMEM cells. This gives the mini power-off, reboot, the RTC and the power button (macsmc-input), and the SMC GPIO that switches the Wi-Fi port's power. The cell offsets come from this mini's macOS IORegistry: pmu-main@E "pmu,abbey", info-leg_scrpad 0xf800, info-pm_setting 0x2001, info-clock_offset 0x2100 (6 bytes), info-fault_shadow 0x867b (0x10), info-scrpad_socd 0x8b00 (0x1800). The state cells sit at leg_scrpad + 1, + 2 and + 0xf, as on the other Apple families. These values are the same as on the M4 MacBook Air (J713). Tested on a J773g (2026-10-17) with the same nodes under GravityLinux's gravity-m4 7.1.13 kernel: the PMU cells appear, macsmc-reboot and macsmc-rtc bind, rtc0 keeps time across reboots and `systemctl poweroff` turns the mini off (power LED off). Without the shutdown flag it restarted instead. Signed-off-by: Sean Dolbec <sdolbec1@gmail.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…Ethernet
Enable the internal NVMe SSD (ANS2, its SART and mailbox) and the
internal PCIe controller on the M4 Mac mini, with the BCM4388 Wi-Fi and
Bluetooth module on port 0 and the Ethernet controller on port 2. With
this the mini boots from its own SSD and reaches the network, with the
display on the boot framebuffer.
- Port 0 is powered by SMC GPIO 19 (pwren-pcie0-port0). Its Wi-Fi and
Bluetooth functions use the "apple,sakhalin" firmware.
- Port 2 has its own DART. The requester IDs map to stream 1 of the
port 0 and port 2 DARTs.
- The ethernet0, wifi0 and bluetooth0 aliases let m1n1 fill in the MAC
and Bluetooth addresses and the Wi-Fi calibration.
The board wiring follows Yureka Lilian's J773g PCIe description ("t8132
pcie", picked into GravityLinux gravity-m4 as 9edf52c) and the
board-type fix in gravity-m4's current J773g tree. The ATC (USB-C) ports,
HDMI, audio, CPU frequency scaling and the GPU are not part of this
change.
A J773g runs these board nodes today under gravity-m4 7.1.13 (AQC113 on
the atlantic driver, BCM4388 on brcmfmac and hci_bcm4377, NVMe root
file system); this tree with this commit has not been booted yet.
Signed-off-by: Sean Dolbec <sdolbec1@gmail.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Give pstore a fixed 2 MiB RAM region on the Mac mini (J773g): 1 MiB for the kernel console, 256 KiB records and 256 KiB for pmsg. It is near the top of RAM and outside m1n1's kernel and initramfs load area. Without it a J773g boot that fails before the root filesystem leaves no trace: no journal and an empty pstore. That is what a first boot of this tree on a J773g did. With CONFIG_PSTORE_RAM and CONFIG_PSTORE_CONSOLE built in, the console of a crashed boot can be read from /sys/fs/pstore on the next one. Signed-off-by: Niklas Sheth <hi@niklassheth.com> [sdolbec: split out of GravityLinux gravity-m4 877c574 "drm/apple: bring up T8132 DCP hotplug" (the ramoops hunk only, unchanged values); the same region is in use on our J773g under GravityLinux 7.1.13] Signed-off-by: Sean Dolbec <sdolbec1@gmail.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The T8132 (M4) controller has three root ports, each with its own PHY register window, like the T8140: config, rc, port0-2 and phy0-2. It uses the apple,t6020-pcie fallback, whose rule asks for four ports and four PHY windows (ten regions), so a T8132 node with its eight regions failed dtbs_check. Give T8132 the T8140 list and leave the other T6020-derived controllers unchanged. Signed-off-by: Sean Dolbec <sdolbec1@gmail.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Describe the Wi-Fi/Bluetooth port's power enable (SMC GPIO 19) as pwren-gpios on the root port, as the other Apple boards in this tree do. pcie-apple then drives it itself, with its power-on delay, before the link comes up. Before, the J773g used a fixed regulator through the generic PCI power-control driver, with "pciclass,0604" root-port compatibles. Both are outside apple,pcie.yaml, so dtbs_check refused the J773g tree. Drop the root-port compatibles and the regulator. The GPIO, polarity and port are unchanged. Signed-off-by: Sean Dolbec <sdolbec1@gmail.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
@yuyuyureka, hi Yureka. This draft ports two of your T8132 device-tree commits for the M4 Mac mini (J773g):
Both keep your authorship. The changes made while porting are listed in a Would you be willing to add your sign-off? A reply here with for those two commits is enough; I'll add it to them. If you'd rather not, say so, and I'll rewrite those nodes independently from the ADT instead. Your third commit here ( |
|
Status from the J773g bring-up (2026-11-03), for anyone following this draft:
Keeping the WIP label; still waiting on Yureka's sign-off for the two ported DT commits. |
omacom/linux-aurora, baseintegration/aurora(2a76ae3)techmore:m4/j773g-boot-v3(24f75ab), 11 commits, +403/-2, device tree and bindings onlyStatus: work in progress, not booted
Image modules dtbs, 0 warnings), anddtbs_checkis clean on all six T8132 boards. That is a compile result, not a runtime pass: no kernel from this tree has booted on a J773g yet.techmore:m4/j773g-cpufreq-sensors-v3,techmore:m4/j773g-pmp-rfc-v3). They will be opened once this PR settles.Verification (v3, 2026-11-03)
integration/aurora2a76ae3. The rebase from the v2 base 4fdd0fc was clean; commits 1-8 are unchanged.apple,dma-range, and none of these nodes has one.t8132-*.dtsat every commit, 0 warnings, withavoid_unnecessary_addr_size,alias_paths,unique_unit_address,pci_device_regand the strict name checks.make CHECK_DTBS=y(dt-schema 2026.9): all six T8132 boards clean at this head. Before commits 10 and 11, the J773g PCIe node failed it.dt_binding_checkon the changed bindings:make dt_binding_check(dt-schema 2026.9) withDT_SCHEMA_FILESset to the 11 bindings this series changes: exit 0, and no warning or error names any of them. The only problems reported are in unrelated example files (Apple DCP, i.MX display).--strict:Co-Authored-Bytrailer form, GravityLinux commit ids in port notes, and the standardpciclass/pci14e4PCI compatibles in existing context.make LLVM=1 Image modules dtbson the J773g (rust 1.93.1, the omarchy-pkgslinux-auroraconfig merged withasahi.config) gives exit 0 and 0 warnings. That's Image, 1917 modules and all six T8132 DTBs.Summary
integration/aurorahast8132-j773g.dtswith a RAM-only boot: CPUs, interrupts, power domains, pins, I2C and the boot framebuffer on the HDMI port. This series adds what the Mac mini needs to run an installed system: the NVMe SSD, the internal PCIe bus with Ethernet and the Wi-Fi/Bluetooth module, and the SMC (power-off, reboot, RTC, power button, and the GPIO that powers the Wi-Fi port). No driver changes: every block works with a driver and fallback compatible this tree already has (apple_nvme_t8132_hw,t602xPCIe,t8110DART,t6000SART,asc-mailbox-v4,t8103SMC/SPMI). USB-C, HDMI (DCP), audio and the GPU are not part of it.This is the M4 bring-up work invited for this repo. It is J773g-only in effect: the SoC nodes are added disabled, and the J773g board file enables them.
Layers (in commit order)
apple,t8132-{dart,sart,asc-mailbox,smc,spmi,pcie},apple,abbey-pmicwith the T8122/T8140 fallbacksnvmmuwindow this tree's T8132 ANS2 code needs (ADT reg[3] 0x485cc0000)dma-rangesapple,sakhalin) and port 2 (Ethernet), MAC/BD aliases for m1n1dtbs_checkfailedpwren-gpios(SMC GPIO 19), which pcie-apple drives itself, instead of a fixed regulator pluspciclass,0604root-port compatibles; same GPIO and polarityCredit
Commits 2, 3 and 5 are Yureka Lilian's T8132 nodes as GravityLinux
gravity-m4carries them (be925f3, 79b86cb, 9edf52c + bdafece; cherry-picks of her d7525ca925b6, 9a864cea9329, 19103645439f, c59a7a826661). They keep her authorship and date; the port changes are listed in a[sdolbec: …]note in each. Commits 2 and 5 have no Signed-off-by from Yureka in that history; they are forwarded under DCO (b) and need her Signed-off-by before merge (or a rewrite from the ADT). The NVMMU window follows KB2UKA's J713 ADT reading (Kb2uka/Omarchy-M4-Native). The board wiring in commit 8 follows Yureka's J773g PCIe description; the PMU cells in commit 7 are ours.What was measured
On our J773g (M4, 10-core GPU, 10 Gb Ethernet), the same nodes run today under GravityLinux
gravity-m47.1.13 with m1n1-gravity 1.6.1: root on the NVMe SSD, AQC113 Ethernet onatlantic, BCM4388 onbrcmfmac/hci_bcm4377, SMC power-off (LED off) and reboot, RTC across reboots, power button events. A dtc comparison of this branch'st8132-j773g.dtbagainst that kernel's DTB shows the samereg, interrupts, MSI ranges, IOMMU maps, GPIOs and power domains for every node in this series. The differences are node names (mailbox@/iommu@), status properties, the addednvmmuwindow and the SPMI power domain.What was not measured
nvmmuwindow with this tree's NVMe driver. Gravity's driver reads the NVMMU through the controller window, which is kept at 0x60000 for that reason.pwren-gpiospower sequencing of the Wi-Fi port with this tree's pcie-apple. Gravity powered the port through a regulator.Merge Danger
Door: two-way. Blast radius: J773g boots. Other T8132 boards gain only disabled nodes and the SoC
dma-ranges(the same line T8112, T8122 and T6030 have). On J773g, m1n1 puts this DTB into stage 2 for every kernel; it is built to keep booting GravityLinux kernels too (same compatibles, 0x60000 controller window), but the mini loses USB, DCP, audio and GPU nodes until those follow-ups land, so owners of a working mini setup should not switch stage 2 to it yet.Follow-ups
CPU frequency, SMC sensors and fan (
m4/j773g-cpufreq-sensors-v3, after this PR settles), then USB-C (ATC PHY, dwc3, the SPMI Type-C controllers, the front-port hub), DCP/HDMI, audio, and the GPU once a G16 backend is in this tree. The PMP stays an RFC (m4/j773g-pmp-rfc-v3).🤖 Generated with Claude Code