arm64: dts: qcom: msm8953-xiaomi-vince: add TAS2557 speaker amplifier #252
Open
M0Rf30 wants to merge 4 commits into
Open
arm64: dts: qcom: msm8953-xiaomi-vince: add TAS2557 speaker amplifier #252M0Rf30 wants to merge 4 commits into
M0Rf30 wants to merge 4 commits into
Conversation
|
Nice, need to try if the amp on FP3+ works with this :) |
3c29ff0 to
0bf8633
Compare
Document the TAS2557 mono Class-D smart amplifier with an integrated DSP for speaker protection. The device is controlled over I2C and receives audio over I2S/TDM (ASI). It can drive a single mono speaker or, as two instances, a stereo pair; an optional firmware-name selects the DSP blob. Signed-off-by: Gianluca Boiano <morf3089@gmail.com>
0bf8633 to
c28ebec
Compare
The TAS2557 is a mono Class-D smart amplifier with an on-chip DSP for speaker protection. Audio is received over I2S/TDM (ASI) and processed by DSP firmware before reaching the Class-D output stage. The driver uses an 8-bit book/page-indirected register map (regmap, REGCACHE_NONE), parses the TI "uCDSP" firmware (programs, configurations and PLL/program/config blocks) and applies program 0 / config 0 on power-up; audio cannot pass without the firmware blob. The ASI inputs, Class-D output and I/V sense paths are exposed via DAPM, together with Speaker, DSP program and configuration controls. Stereo is supported as two cooperating instances: device==3 firmware carries per-amplifier (DEV_A/DEV_B) tuning, selected per instance via the ti,channel property. An optional firmware-name DT property overrides the PG-version-derived blob name. Verbose probe/firmware/PLL-lock logging is provided for bring-up and diagnostics. Signed-off-by: Gianluca Boiano <morf3089@gmail.com>
Build the TAS2557 mono smart amplifier driver as a module, used by the Xiaomi Redmi 5 Plus (vince) for its loudspeaker. Signed-off-by: Gianluca Boiano <morf3089@gmail.com>
Wire up the TAS2557 mono speaker amplifier on the Redmi 5 Plus (vince): - it sits on i2c_2 at 0x4c with reset on GPIO86 and IRQ on GPIO87; its AVDD/DVDD/IOVDD pins are fed by the always-on 1.8 V rail pm8953_l6, and VBAT by the always-on battery rail; - it is the external PA on Quinary MI2S. The Android mixer paths route the speaker through QUIN_MI2S_RX, and the register-compatible Motorola ocean (tfa9874) and Fairphone 3 (aw8898) use Quinary as well. Add a dedicated Quinary MI2S dai-link for the amplifier and register the QUINARY_MI2S_RX AFE DAI (SD0, per the downstream). The internal codec stays on Primary MI2S, so earpiece and headphones are unaffected; - the MI2S pins (gpio88/91/93 plus the gpio92 word-clock, which uses the dedicated pri_mi2s_ws pinmux function) are configured. The LPASS routes Quinary onto these pins through the quin iomux that the apq8016_sbc machine driver already programs in its MI2S_QUINARY path, so no machine-driver change is required. Signed-off-by: Gianluca Boiano <morf3089@gmail.com>
c28ebec to
e205166
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds TAS2557 loudspeaker support for the Xiaomi Redmi 5 Plus (vince).
dai-link
The amp is on Quinary MI2S, not Primary — Primary is the internal codec. Matches the stock mixer_paths and
the existing ocean/FP3 setups, so no machine-driver change.
Needs tas2557_uCDSP.bin (device-specific, pull from stock vendor into /lib/firmware) to actually pass audio.
Tested on device, speaker works.