]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
arm64: dts: imx8mp-evk: Use fsl-asoc-card to replace simple card
authorShengjiu Wang <shengjiu.wang@nxp.com>
Tue, 17 Jun 2025 07:26:46 +0000 (15:26 +0800)
committerShawn Guo <shawnguo@kernel.org>
Fri, 11 Jul 2025 08:34:30 +0000 (16:34 +0800)
In order to support Asynchronous Sample Rate Converter (ASRC), switch to
fsl-asoc-card driver for the wm8960 sound card.

Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
arch/arm64/boot/dts/freescale/imx8mp-evk.dts

index 1ba3018c621e25c00e23cb2683c1bb0c51fa7365..c0cc5611048e6a739f13c14bbd2e7b26f2715696 100644 (file)
                #sound-dai-cells = <1>;
        };
 
-       sound {
-               compatible = "simple-audio-card";
-               simple-audio-card,name = "wm8960-audio";
-               simple-audio-card,format = "i2s";
-               simple-audio-card,frame-master = <&cpudai>;
-               simple-audio-card,bitclock-master = <&cpudai>;
-               simple-audio-card,widgets =
-                       "Headphone", "Headphone Jack",
-                       "Speaker", "External Speaker",
-                       "Microphone", "Mic Jack";
-               simple-audio-card,routing =
-                       "Headphone Jack", "HP_L",
-                       "Headphone Jack", "HP_R",
-                       "External Speaker", "SPK_LP",
-                       "External Speaker", "SPK_LN",
-                       "External Speaker", "SPK_RP",
-                       "External Speaker", "SPK_RN",
-                       "LINPUT1", "Mic Jack",
-                       "LINPUT3", "Mic Jack",
-                       "Mic Jack", "MICB";
-
-               cpudai: simple-audio-card,cpu {
-                       sound-dai = <&sai3>;
-               };
-
-               simple-audio-card,codec {
-                       sound-dai = <&wm8960>;
-               };
-
-       };
-
        sound-bt-sco {
                compatible = "simple-audio-card";
                simple-audio-card,name = "bt-sco-audio";
                };
        };
 
+       sound-wm8960 {
+               compatible = "fsl,imx-audio-wm8960";
+               audio-asrc = <&easrc>;
+               audio-codec = <&wm8960>;
+               audio-cpu = <&sai3>;
+               audio-routing = "Headphone Jack", "HP_L",
+                       "Headphone Jack", "HP_R",
+                       "Ext Spk", "SPK_LP",
+                       "Ext Spk", "SPK_LN",
+                       "Ext Spk", "SPK_RP",
+                       "Ext Spk", "SPK_RN",
+                       "LINPUT1", "Mic Jack",
+                       "LINPUT3", "Mic Jack",
+                       "Mic Jack", "MICB";
+               hp-det-gpio = <&gpio4 28 GPIO_ACTIVE_HIGH>;
+               model = "wm8960-audio";
+               pinctrl-0 = <&pinctrl_hpdet>;
+               pinctrl-names = "default";
+       };
+
        sound-xcvr {
                compatible = "fsl,imx-audio-card";
                model = "imx-audio-xcvr";
        status = "okay";
 };
 
+&easrc {
+       fsl,asrc-rate  = <48000>;
+       status = "okay";
+};
+
 &eqos {
        pinctrl-names = "default";
        pinctrl-0 = <&pinctrl_eqos>;
                >;
        };
 
+       pinctrl_hpdet: hpdetgrp {
+               fsl,pins = <
+                       MX8MP_IOMUXC_SAI3_RXFS__GPIO4_IO28              0xd6
+               >;
+       };
+
        pinctrl_i2c1: i2c1grp {
                fsl,pins = <
                        MX8MP_IOMUXC_I2C1_SCL__I2C1_SCL         0x400001c2