Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
123 changes: 123 additions & 0 deletions Documentation/devicetree/bindings/sound/ti,tas2557.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,123 @@
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
# Copyright (C) 2026 Gianluca Boiano <morf3089@gmail.com>
%YAML 1.2
---
$id: http://devicetree.org/schemas/sound/ti,tas2557.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Texas Instruments TAS2557 Mono Smart Amplifier

maintainers:
- Gianluca Boiano <morf3089@gmail.com>

description: |
The TAS2557 is a mono, digital-input Class-D amplifier with an
integrated DSP for speaker protection. Audio is carried over I2S/TDM
(ASI). The on-chip DSP boots from a firmware image that is generated
for a specific speaker design using the TI PurePath Console tuning
tools.

Stereo playback is built from two devices, each reproducing one audio
slot selected through the ti,channel property and applying the
matching per-device tuning contained in a stereo-tuned firmware
image.

Datasheet: https://www.ti.com/lit/gpn/tas2557

allOf:
- $ref: dai-common.yaml#

properties:
compatible:
const: ti,tas2557

reg:
maxItems: 1

'#sound-dai-cells':
const: 0

reset-gpios:
maxItems: 1
description: GPIO connected to the active-low RESET pin.

interrupts:
maxItems: 1
description: Fault interrupt output (INT).

vbat-supply:
description: Battery/boost input supply (VBAT), 2.9 V to 5.5 V.

iovdd-supply:
description: Digital I/O supply, 1.62 V to 3.6 V.

avdd-supply:
description: Analog supply, 1.65 V to 1.95 V.

dvdd-supply:
description: Digital core supply, 1.65 V to 1.95 V.

Comment thread
M0Rf30 marked this conversation as resolved.
ti,imon-slot-no:
$ref: /schemas/types.yaml#/definitions/uint32
description: TDM TX time slot for current-sense data.
default: 0
minimum: 0
maximum: 7

ti,vmon-slot-no:
$ref: /schemas/types.yaml#/definitions/uint32
description: TDM TX time slot for voltage-sense data.
default: 2
minimum: 0
maximum: 7

ti,channel:
$ref: /schemas/types.yaml#/definitions/uint32
description: |
Audio slot of the stereo stream reproduced by this device (0 =
left, 1 = right). With stereo firmware this also selects which
per-device tuning set is applied.
enum: [0, 1]
default: 0

firmware-name:
$ref: /schemas/types.yaml#/definitions/string
description: |
Name of the DSP firmware image to load. Defaults to a name
derived from the silicon revision. Stereo systems typically use
a stereo-tuned image shared by both devices.

required:
- compatible
- reg
- '#sound-dai-cells'

unevaluatedProperties: false

examples:
- |
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/interrupt-controller/irq.h>

i2c {
#address-cells = <1>;
#size-cells = <0>;

audio-codec@4c {
compatible = "ti,tas2557";
reg = <0x4c>;
#sound-dai-cells = <0>;
reset-gpios = <&tlmm 77 GPIO_ACTIVE_LOW>;
interrupt-parent = <&tlmm>;
interrupts = <73 IRQ_TYPE_LEVEL_HIGH>;

vbat-supply = <&vph_pwr>;
iovdd-supply = <&vreg_l6b_1p8>;
avdd-supply = <&vreg_l6b_1p8>;
dvdd-supply = <&vreg_l6b_1p8>;

ti,imon-slot-no = <0>;
ti,vmon-slot-no = <2>;
ti,channel = <0>;
};
};
1 change: 1 addition & 0 deletions MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -26112,6 +26112,7 @@ M: Baojun Xu <baojun.xu@ti.com>
L: linux-sound@vger.kernel.org
S: Maintained
F: Documentation/devicetree/bindings/sound/ti,tas2552.yaml
F: Documentation/devicetree/bindings/sound/ti,tas2557.yaml
F: Documentation/devicetree/bindings/sound/ti,tas2562.yaml
F: Documentation/devicetree/bindings/sound/ti,tas2770.yaml
F: Documentation/devicetree/bindings/sound/ti,tas27xx.yaml
Expand Down
99 changes: 93 additions & 6 deletions arch/arm64/boot/dts/qcom/sdm636-xiaomi-tulip.dts
Original file line number Diff line number Diff line change
Expand Up @@ -173,12 +173,24 @@
};
};

&blsp_i2c2 {
status = "okay";
};

&blsp_i2c6 {
status = "okay";

tas2557: codec@4c {
compatible = "ti,tas2557";
reg = <0x4c>;
#sound-dai-cells = <0>;

reset-gpios = <&tlmm 77 GPIO_ACTIVE_LOW>;
interrupts-extended = <&tlmm 73 IRQ_TYPE_LEVEL_HIGH>;

vbat-supply = <&vph_pwr>;
iovdd-supply = <&vreg_l6b_1p8>;
avdd-supply = <&vreg_l6b_1p8>;
dvdd-supply = <&vreg_l6b_1p8>;

ti,channel = <0>;
};
};

&blsp1_uart2 {
Expand Down Expand Up @@ -328,6 +340,11 @@
};

&q6afedai {
dai@16 {
reg = <PRIMARY_MI2S_RX>;
qcom,sd-lines = <0>;
};

dai@81 {
reg = <INT0_MI2S_RX>;
qcom,sd-lines = <0 1>;
Expand Down Expand Up @@ -446,6 +463,12 @@
regulator-allow-set-load;
};

vreg_l6b_1p8: l6 {
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
regulator-enable-ramp-delay = <250>;
};

vreg_l7b_3p125: l7 {
regulator-min-microvolt = <2700000>;
regulator-max-microvolt = <3125000>;
Expand Down Expand Up @@ -661,7 +684,8 @@
model = "Xiaomi Redmi Note 6 Pro";

pinctrl-0 = <&cdc_pdm_default>,
<&cdc_dmic_default>;
<&cdc_dmic_default>,
<&pri_mi2s_active>;
pinctrl-names = "default";

audio-routing = "RX_BIAS", "Digital MCLK",
Expand All @@ -676,7 +700,8 @@
"PDM_RX3", "Digital PDM_RX3",
"Digital LPASS_PDM_TX", "PDM_TX",
"AMIC1", "MIC BIAS External1",
"AMIC2", "MIC BIAS External2";
"AMIC2", "MIC BIAS External2",
"ASI2", "Primary MI2S Playback";

mm1-dai-link {
link-name = "MultiMedia1";
Expand Down Expand Up @@ -711,6 +736,22 @@
};
};

pri-mi2s-dai-link {
link-name = "Primary MI2S Playback";

cpu {
sound-dai = <&q6afedai PRIMARY_MI2S_RX>;
};

platform {
sound-dai = <&q6routing>;
};

codec {
sound-dai = <&tas2557>;
};
};

int3-mi2s-dai-link {
link-name = "Internal MI2S Capture";

Expand Down Expand Up @@ -780,6 +821,52 @@
drive-strength = <2>;
bias-disable;
};

pri_mi2s_active: pri-mi2s-active-state {
sck-pins {
pins = "gpio12";
function = "pri_mi2s";
drive-strength = <8>;
bias-disable;
};

ws-pins {
pins = "gpio13";
function = "pri_mi2s_ws";
drive-strength = <8>;
bias-disable;
};

data-pins {
pins = "gpio14", "gpio15";
function = "pri_mi2s";
drive-strength = <8>;
bias-disable;
};
};

pri_mi2s_sleep: pri-mi2s-sleep-state {
sck-pins {
pins = "gpio12";
function = "pri_mi2s";
drive-strength = <2>;
bias-pull-down;
};

ws-pins {
pins = "gpio13";
function = "pri_mi2s_ws";
drive-strength = <2>;
bias-pull-down;
};

data-pins {
pins = "gpio14", "gpio15";
function = "pri_mi2s";
drive-strength = <2>;
bias-pull-down;
};
};
};

&usb3 {
Expand Down
Loading
Loading