Repository navigation
Conversation
On J613 the inverted I2S link selects rising-edge SDOUT launch on the TAS2764-class speaker amplifiers. The nominal MCA receive polarity puts speaker V/I sense sampling at that launch boundary, corrupting raw signed samples and preventing speakersafetyd from protecting normal playback. Invert RX polarity only for cluster 2 on apple,j613, retaining the one-bit I2S offset and the existing TX polarity. Hardware capture comparisons show that this opposite-edge window restores quiet samples and isolated bipolar per-amplifier tones without sample masking or gain conversion. Playback sampling and all other boards retain their existing configuration. The same change on a 30.14-based J613 kernel passes protected playback, stop-to-floor and suspend/resume through a fail-closed daemon warm restart. The rebased commit is arm64 compile-tested separately. No timing-chain regression commit has been established, so omit a Fixes tag. Signed-off-by: Satya Benson <satya@benson.earth>
|
Thanks for working out the J613 sense-stream corruption and writing up the edge reasoning. The fix is applied with The edge belongs to the board's amp-to-MCA link, so it fits in the DT: for example a boolean on the MCA cluster or the capture dai-link (along the lines of If you make it a DT property, we can run speaker-sense no-regression rows on our M1 Pro, M2, M4 Pro and A18 Pro. |
Describe which MCA receive clusters sample on the opposite bit clock edge from the DAI format. The transmit polarity stays as configured. Signed-off-by: Satya Benson <satya@benson.earth> Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Read the MCA clusters whose receive serializers use the opposite BCLK edge from the DAI format. The J613 speaker sense frontend still uses cluster 2 with inverted receive polarity, while the transmit edge and DAI format remain the same. Signed-off-by: Satya Benson <satya@benson.earth> Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
|
Claude Fable 5.2 on @satchlj's behalf
|
|
Thanks for the DT property and binding; that is exactly the shape we hoped for, and it keeps speaker protection independent of board names. The J613 sense row on this head is the remaining item, and the red dt-checks/host-tests jobs failed in apt (network), so a re-run should clear them. We will run speaker-sense no-regression rows on our lab Macs. |
Claude Fable 5.2 on @satchlj's behalf
On the J613 (M3 MacBook Air), nominal MCA receive sampling corrupts the speaker amplifier voltage/current sense stream and prevents speakersafetyd from protecting normal playback. The inverted I2S link selects rising-edge SDOUT launch in the TAS2764-class amplifier driver; the nominal MCA RX setting samples at that launch boundary.
Invert only the RX BCLK polarity for MCA cluster 2 when the root machine is compatible with
apple,j613. This is the J613 speaker V/I sense frontend. It retains the I2S one-bit offset (bitstart 1 / edge 1), TX/playback polarity, sample representation and gain. Other clusters and boards, including J413 despite its shared sound-card fallback, keep their existing settings. The patch is three insertions insound/soc/apple/mca.c; the existing local board/cluster condition was already appropriately scoped and needed no rewrite.The receive setting was selected from hardware capture comparisons, supported by the public driver and TAS2764 datasheet timing definitions. No physical oscilloscope edge or setup/hold measurement is claimed. No timing-chain regression commit has been established, so there is no speculative Fixes tag.
Validation:
1f17eef0f378eaadf8d693ee879c589010ec9e3bontointegration/auroraat677be395b9d2e15d98696107ebf88191f08efbf9.sound/soc/apple/mca.ois compile-tested for arm64 in neo-build with LLVM 18.1.3,W=1and the retained production configuration followed byolddefconfig.checkpatch.pl --strict: 0 errors, 0 warnings, 0 checks. This rebased commit has not been boot-tested.d4ed471f8eb5815d0b14510b438fcb57bfdc65c5plus the same three-line change) gave 7.11–8.55 counts quiet RMS across per-amp captures, bipolar isolated tones and positive real power. Other-pair fitted 440 Hz response was at most 0.120 counts. Normal playback, an eight-second loud limiting test, stop-to-floor and restart-mediated suspend/resume passed. These capture/limiting figures belong to that 30.20-based trial.7.3.0-aurora73-ppt-4-sensefix1-ARCH. Its base composition wascba5ede3e1ea62647355eee42136afef493d175a: integration05f3aabb2ae08f84506a3462638885bf77a8c5f8plus the then-recorded drm/apple: support J613 native26 external displays #973 (952c236abf3f), media: apple: isp: enable exact J613 26.6.2 preview #974 (76a7dfbcdd04), arm64: dts: apple: t8122: SPI2 and SPI4 run from the 24 MHz reference, not 200 MHz #1598 (f1c9d85fa75a) and thunderbolt: apple: enable the J613 USB4 host-to-host path #1490 (9b89ce2742e2). With speakersafetyd2.0.1-2.j613spkfix1, protected built-in playback and stop/start fail-safe passed. One s2idle cycle failed closed on an incomplete sense period, then automatically warm-restarted: fresh valid sense at 1.248384 s, protected unlock at 1.249550 s, and both groups at nominal gain at 3.979528 s after wake. Post-resume playback passed. This is recovery through a daemon restart, not seamless same-process continuity.Hardware evidence is limited to J613 and the recorded compositions above; it does not qualify the current rebased integration tree on hardware. Independent common absolute V/I gain calibration remains open. No sample masking, guessed scale correction, daemon change or protection bypass is included.
🤖 Generated with Claude Code