diff mbox series

[5/5] arm64: dts: imx8qxp: mba8xx: Add analog audio output on MBa8Xx

Message ID 20231214150243.1991532-6-alexander.stein@ew.tq-group.com (mailing list archive)
State New, archived
Headers show
Series TQMa8Xx (imx8qxp) audio support | expand

Commit Message

Alexander Stein Dec. 14, 2023, 3:02 p.m. UTC
Enable SAI1, add the codec to enable LINE_IN and LINE_OUT support on
MBa8Xx on connectors X9 & X10.

Signed-off-by: Alexander Stein <alexander.stein@ew.tq-group.com>
---
 arch/arm64/boot/dts/freescale/mba8xx.dtsi | 27 ++++++++++++++++++++---
 1 file changed, 24 insertions(+), 3 deletions(-)
diff mbox series

Patch

diff --git a/arch/arm64/boot/dts/freescale/mba8xx.dtsi b/arch/arm64/boot/dts/freescale/mba8xx.dtsi
index a263c3d008023..6164fefb92184 100644
--- a/arch/arm64/boot/dts/freescale/mba8xx.dtsi
+++ b/arch/arm64/boot/dts/freescale/mba8xx.dtsi
@@ -116,7 +116,12 @@  reg_3v3_mb: regulator-usdhc2-vmmc {
 		regulator-max-microvolt = <3300000>;
 	};
 
-	/* TODO: Audio */
+	sound {
+		compatible = "fsl,imx-audio-tlv320aic32x4";
+		model = "tqm-tlv320aic32";
+		audio-codec = <&tlv320aic3x04>;
+		ssi-controller = <&sai1>;
+	};
 };
 
 &adc0 {
@@ -204,7 +209,14 @@  &flexcan2 {
 };
 
 &i2c1 {
-	/* TODO: Add Audio codec */
+	tlv320aic3x04: audio-codec@18 {
+		compatible = "ti,tlv320aic32x4";
+		reg = <0x18>;
+		clocks = <&mclkout0_lpcg 0>;
+		clock-names = "mclk";
+		iov-supply = <&reg_1v8>;
+		ldoin-supply = <&reg_3v3>;
+	};
 
 	se97b_1c: temperature-sensor@1c {
 		compatible = "nxp,se97b", "jedec,jc-42.4-temp";
@@ -298,7 +310,16 @@  &lsio_gpio3 {
 
 /* TODO: Mini-PCIe */
 
-/* TODO: SAI1 */
+&sai1 {
+	assigned-clocks = <&clk IMX_SC_R_AUDIO_PLL_0 IMX_SC_PM_CLK_PLL>,
+			  <&clk IMX_SC_R_AUDIO_PLL_0 IMX_SC_PM_CLK_SLV_BUS>,
+			  <&clk IMX_SC_R_AUDIO_PLL_0 IMX_SC_PM_CLK_MST_BUS>,
+			  <&sai1_lpcg 0>;
+	assigned-clock-rates = <786432000>, <49152000>, <12288000>, <49152000>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_sai1>;
+	status = "okay";
+};
 
 &usbotg1 {
 	pinctrl-names = "default";