]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
ARM: dts: imx28-amarula-rmm: add I2S audio
authorDario Binacchi <dario.binacchi@amarulasolutions.com>
Mon, 27 Oct 2025 16:10:23 +0000 (17:10 +0100)
committerShawn Guo <shawnguo@kernel.org>
Sun, 16 Nov 2025 04:03:08 +0000 (12:03 +0800)
Add support for I2S audio on Amarula rmm board. Audio codec
TLV320AIC3X is connected as slave to SAIF0, which provides
bitclock, frame and MCLK.

Co-developed-by: Michael Trimarchi <michael@amarulasolutions.com>
Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com>
Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
arch/arm/boot/dts/nxp/mxs/imx28-amarula-rmm.dts

index af59211842fb24e608b08b951661616ca900c9b6..ddb64f3d0471ae9c7e5879da73c643b9b5a01fbd 100644 (file)
                enable-active-high;
                regulator-always-on;
        };
+
+       sound {
+               compatible = "simple-audio-card";
+               simple-audio-card,name = "imx28-mrmmi-tlv320aic3x-audio";
+               simple-audio-card,format = "i2s";
+               simple-audio-card,bitclock-master = <&cpu_dai>;
+               simple-audio-card,frame-master = <&cpu_dai>;
+               simple-audio-card,widgets =
+                       "Headphone", "Headphone Jack";
+               simple-audio-card,routing =
+                       "Headphone Jack", "HPROUT",
+                       "Headphone Jack", "HPRCOM";
+               simple-audio-card,mclk-fs = <512>;
+
+               cpu_dai: simple-audio-card,cpu {
+                       sound-dai = <&saif0>;
+                       clocks = <&saif0>;
+               };
+
+               codec_dai: simple-audio-card,codec {
+                       sound-dai = <&tlv320aic3x>;
+               };
+       };
 };
 
 &auart0 {
        pinctrl-0 = <&i2c0_pins_a>;
        status = "okay";
 
+       tlv320aic3x: audio-codec@18 {
+               compatible = "ti,tlv320aic3x";
+               pinctrl-names = "default";
+               pinctrl-0 = <&tlv320aic3x_pins>;
+               reg = <0x18>;
+               reset-gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
+               #sound-dai-cells = <0>;
+               DVDD-supply = <&reg_1v8>;
+               IOVDD-supply = <&reg_3v3>;
+               AVDD-supply = <&reg_3v3>;
+               DRVDD-supply = <&reg_3v3>;
+       };
+
        touchscreen: touchscreen@38 {
                compatible = "edt,edt-ft5306";
                reg = <0x38>;
                fsl,voltage = <MXS_VOLTAGE_HIGH>;
        };
 
+       tlv320aic3x_pins: tlv320aic3x-pins@0 {
+               reg = <0>;
+               fsl,pinmux-ids = <MX28_PAD_SSP0_DATA4__GPIO_2_4>;
+               fsl,drive-strength = <MXS_DRIVE_4mA>;
+               fsl,pull-up = <MXS_PULL_ENABLE>;
+               fsl,voltage = <MXS_VOLTAGE_HIGH>;
+       };
+
        usb0_vbus_enable_pin: usb0-vbus-enable@0 {
                reg = <0>;
                fsl,pinmux-ids = <MX28_PAD_SSP0_DATA5__GPIO_2_5>;
        status = "okay";
 };
 
+&saif0 {
+       pinctrl-names = "default";
+       pinctrl-0 = <&saif0_pins_a>;
+       status = "okay";
+};
+
 /* microSD */
 &ssp0 {
        compatible = "fsl,imx28-mmc";