Repository navigation
soc: apple: aop: Add the T8132 (M4 MacBook Air) AOP - #819
Conversation
|
Rebased: commit message only (not pushed yet) #819 still merges cleanly. But since I reworded it to nCal 1, with a pointer to 28174f8, and added my sign-off with an Testing:
I haven't pushed it. If you're fine with it, I'd force-push it to 🤖 Written by Claude Opus 5.5 (in Claude Code) for Eryk; the rebase, fixes and tests above were done the same way. |
The T8132 (M4) AOP runs the same firmware transport as the T6041 one, and its bootloader hands it over the same way. It also programs the AOP DART's address filter (DAPF) and reserves the filter's windows, which the firmware reaches through its DART at their physical addresses. The windows come in memory-region with the firmware segments, up to 16 of them. Signed-off-by: Erik Bourget <erik@ebourget.net>
The T8132 (M4) AOP takes the T6040 boot arguments (EC0p 0x100_0000_0000, nCal 1, alig 64, AOPt 0): iBoot leaves the boot-argument table at its defaults in the AOP SRAM and the AOP halted, and the ADT gives __ETEXT the DART address 0x100_0000_0000. The bootloader programs the AOP DART's DAPF and reserves the firmware segments and the DAPF windows, so the T6040 configuration applies unchanged, including the firmware's own nCal of 1 that the T6040 writes since 28174f8 ("soc: apple: aop: Write the T6040 firmware's own nCal boot argument"). Tested on J713 (MacBook Air 13" M4) with m1n1 handing the AOP over (its memory-region holds __ETEXT, __OS_LOG and the 15 DAPF windows): the AOP starts, and the microphones capture (3 channels, 48 kHz) through aop_audio. Signed-off-by: Erik Bourget <erik@ebourget.net> [eryk: rebased onto integration/aurora 21f7ffc; the T8132 config now inherits nCal 1 from the T6040 one (28174f8), so the message says so] Signed-off-by: Eryk Wieliczko <eryk@wieliczko.ninja> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
f698fcb to
b2895d6
Compare
|
Merged. This comment is from Claude, working for Eryk, not from Eryk himself. Rebased onto integration/aurora 🤖 Written by Claude Opus 5.5 (in Claude Code) for Eryk. |
The T8132 AOP (J713, MacBook Air 13" M4). It takes the T6040 configuration, and the bootloader hands it over the T6040 way. This supersedes the AOP half of #434. The J713 audio that runs on it is in #820.
apple,t8132-aoponapple,t6041-aop.yaml. On T8132 the bootloader also programs the AOP DART's DAPF and reserves its windows. The firmware reaches those windows through its DART at their physical addresses, so they come inmemory-regionalong with the firmware segments: up to 18 regions on T8132. T6041 stays at 4.HW_CFG_T8132 = HW_CFG_T6040.The #434 review
iommu_mapin the kernel, so the probe error paths that left DAPF writes and mappings behind are gone with them. The IOMMU core maps the reserved regions, andcheck_fw_regions()verifies them as on T6040.__ETEXT, the moving__OS_LOGand the 15 merged windows with identityiommu-addresses, and disables the AOP on any failure.aurora-wip, but not yet onmain. With an older m1n1 the AOP gets nomemory-region, and the driver refuses to start it.Testing
On a J713, with the audio PR on top, on integration/aurora 41c4055. The boot chain has the m1n1#47 and u-boot#13 handoff.
Startup: the AOP's
memory-regionlists 17 regions (__ETEXT,__OS_LOGand the 15 windows), andRTKit: Initializing (protocol version 12). No DART faults, and the kernel stays untainted. The microphones, jack and speakers all run on it, and a fullsnd-soc-aopreload brings them back.Start failure and rebind:
apple_aoptimes out waiting for the endpoints to acknowledge their shutdown (5 s, mask 0xfff).So on J713 the AOP core can't be rebound without a reboot, but its failure path is safe. T6040 takes the same path. I haven't seen how a J616s behaves there.
Checks:
checkpatch --strictis clean on both commits.drivers/soc/applewith W=1.aop.oalso builds in the universal WERROR build (defconfig + asahi.config).dt_binding_checkis clean forapple,t6041-aop.yaml.