The Linux Kernel Mailing List
 help / color / mirror / Atom feed
* [PATCH v2 0/2] ASoC: codecs: add Texas Instruments TAS2557 smart amplifier driver
@ 2026-07-11 14:57 Gianluca Boiano
  2026-07-11 14:57 ` [PATCH v2 1/2] dt-bindings: sound: add Texas Instruments TAS2557 Gianluca Boiano
  2026-07-11 14:57 ` [PATCH v2 2/2] ASoC: codecs: add TAS2557 mono smart amplifier driver Gianluca Boiano
  0 siblings, 2 replies; 3+ messages in thread
From: Gianluca Boiano @ 2026-07-11 14:57 UTC (permalink / raw)
  To: Mark Brown, Liam Girdwood, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Jaroslav Kysela, Takashi Iwai
  Cc: Gianluca Boiano, Shenghao Ding, Kevin Lu, Baojun Xu, Wang, Sen,
	linux-sound, devicetree, linux-kernel

The TAS2557 is a mono Class-D smart amplifier with an on-chip DSP for
speaker protection, controlled over I2C with audio carried over
I2S/TDM. The DSP requires a board-specific firmware image generated
with TI's PurePath Console tuning tools; without it the device passes
no audio.

Patch 1 adds the devicetree binding. Patch 2 adds the ASoC codec
driver: mono and dual-device stereo operation, per-device ti,channel
tuning, and fault-interrupt recovery that reloads the firmware
configuration on clock loss, over-current, brownout or
over-temperature.

Tested in mono configuration on Xiaomi Mi A2 (SDM660, jasmine),
Xiaomi Redmi Note 6 Pro (SDM636, tulip) and Xiaomi Redmi 5 Plus
(MSM8953, vince), driving the top speaker, and in dual-device stereo
configuration on Xiaomi Mi Pad 4 (SDM660, clover).

Changes in v2:
- add the four mandatory supplies (vbat/iovdd/avdd/dvdd) to the
  devicetree binding's "required" list (Wang Sen)
- propagate register-write failures out of hw_params() instead of
  only logging them (Wang Sen)
- return IRQ_NONE instead of IRQ_HANDLED from the fault interrupt
  handler when the device isn't in a state to have raised it, so
  shared-IRQ accounting stays correct (Mark Brown)
- re-apply cached runtime state (DAI format, sense enables, DAC gain,
  ASI slot offsets) after every device reset, including fault
  recovery, instead of letting a hardcoded startup sequence silently
  override set_dai_fmt()/the ISENSE/VSENSE mixer controls (Mark Brown)
- honour explicit snd_soc_dai_set_tdm_slot() configuration in
  hw_params, and restore TX (OFFSET2) slot offsets after reset
- wait for the asynchronous firmware load on first stream start
  instead of failing with -ENODEV
- make mute_stream direction-aware so capture-only IV-sense streams
  are unmuted and stopping playback no longer mutes a live capture
- corrected a comment implying the ASI2/GPIO5-8 wiring in
  tas2557_startup_data comes from a TI reference sequence; it does
  not (TI's own driver never touches ASI2)

Link to v1: https://lore.kernel.org/linux-sound/20260709221331.989109-1-morf3089@gmail.com/

Gianluca Boiano (2):
  dt-bindings: sound: add Texas Instruments TAS2557
  ASoC: codecs: add TAS2557 mono smart amplifier driver

 .../devicetree/bindings/sound/ti,tas2557.yaml |  127 +
 MAINTAINERS                                   |    1 +
 sound/soc/codecs/Kconfig                      |   11 +
 sound/soc/codecs/Makefile                     |    2 +
 sound/soc/codecs/tas2557.c                    | 2648 +++++++++++++++++
 sound/soc/codecs/tas2557.h                    |  218 ++
 6 files changed, 3007 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/sound/ti,tas2557.yaml
 create mode 100644 sound/soc/codecs/tas2557.c
 create mode 100644 sound/soc/codecs/tas2557.h


base-commit: dc59e4fea9d83f03bad6bddf3fa2e52491777482
-- 
2.55.0


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-07-11 14:57 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-11 14:57 [PATCH v2 0/2] ASoC: codecs: add Texas Instruments TAS2557 smart amplifier driver Gianluca Boiano
2026-07-11 14:57 ` [PATCH v2 1/2] dt-bindings: sound: add Texas Instruments TAS2557 Gianluca Boiano
2026-07-11 14:57 ` [PATCH v2 2/2] ASoC: codecs: add TAS2557 mono smart amplifier driver Gianluca Boiano

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox