devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/4] arm64: dts: imx8mm-beacon: Migrate sound card to simple-audio-card
@ 2023-08-31 11:51 Adam Ford
  2023-08-31 11:51 ` [PATCH 2/4] arm64: dts: imx8mm-beacon: Add DMIC support Adam Ford
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Adam Ford @ 2023-08-31 11:51 UTC (permalink / raw)
  To: linux-arm-kernel
  Cc: aford, Adam Ford, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Shawn Guo, Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam,
	NXP Linux Team, devicetree, linux-kernel

Instead of using a custom glue layer connecting the wm8962 CODEC
to the SAI3 sound-dai, migrate the sound card to simple-audio-card.
This also brings this board in line with the imx8mn-beacon and
imx8mp-beacon.

Signed-off-by: Adam Ford <aford173@gmail.com>

diff --git a/arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi
index b10e2a703a44..313e93663d6f 100644
--- a/arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi
@@ -98,18 +98,30 @@ reg_usdhc2_vmmc: regulator-usdhc2 {
 		enable-active-high;
 	};
 
-	sound {
-		compatible = "fsl,imx-audio-wm8962";
-		model = "wm8962-audio";
-		audio-cpu = <&sai3>;
-		audio-codec = <&wm8962>;
-		audio-routing =
-			"Headphone Jack", "HPOUTL",
-			"Headphone Jack", "HPOUTR",
-			"Ext Spk", "SPKOUTL",
-			"Ext Spk", "SPKOUTR",
-			"AMIC", "MICBIAS",
-			"IN3R", "AMIC";
+	sound-wm8962 {
+		compatible = "simple-audio-card";
+		simple-audio-card,name = "wm8962";
+		simple-audio-card,format = "i2s";
+		simple-audio-card,widgets = "Headphone", "Headphones",
+					    "Microphone", "Headset Mic",
+					    "Speaker", "Speaker";
+		simple-audio-card,routing = "Headphones", "HPOUTL",
+					    "Headphones", "HPOUTR",
+					    "Speaker", "SPKOUTL",
+					    "Speaker", "SPKOUTR",
+					    "Headset Mic", "MICBIAS",
+					    "IN3R", "Headset Mic";
+
+		simple-audio-card,cpu {
+			sound-dai = <&sai3>;
+		};
+
+		simple-audio-card,codec {
+			sound-dai = <&wm8962>;
+			clocks = <&clk IMX8MM_CLK_SAI3_ROOT>;
+			frame-master;
+			bitclock-master;
+		};
 	};
 };
 
@@ -192,6 +204,7 @@ wm8962: audio-codec@1a {
 			0x0000 /* 4:FN_DMICCDAT */
 			0x0000 /* 5:Default */
 		>;
+		#sound-dai-cells = <0>;
 	};
 
 	pca6416_0: gpio@20 {
-- 
2.39.2


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

* [PATCH 2/4] arm64: dts: imx8mm-beacon: Add DMIC support
  2023-08-31 11:51 [PATCH 1/4] arm64: dts: imx8mm-beacon: Migrate sound card to simple-audio-card Adam Ford
@ 2023-08-31 11:51 ` Adam Ford
  2023-09-25  1:14   ` Shawn Guo
  2023-08-31 11:51 ` [PATCH 3/4] arm64: dts: imx8mn-beacon: " Adam Ford
  2023-08-31 11:51 ` [PATCH 4/4] arm64: dts: imx8mp-beacon: " Adam Ford
  2 siblings, 1 reply; 7+ messages in thread
From: Adam Ford @ 2023-08-31 11:51 UTC (permalink / raw)
  To: linux-arm-kernel
  Cc: aford, Adam Ford, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Shawn Guo, Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam,
	NXP Linux Team, devicetree, linux-kernel

The baseboard has a connector for a pulse density microphone.
This is connected via the micfil interface and uses the DMIC
audio codec with the simple-audio-card.

Signed-off-by: Adam Ford <aford173@gmail.com>

diff --git a/arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi
index 313e93663d6f..d0dd4c81a557 100644
--- a/arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi
@@ -6,6 +6,13 @@
 #include <dt-bindings/phy/phy-imx8-pcie.h>
 
 / {
+
+	dmic_codec: dmic-codec {
+		compatible = "dmic-codec";
+		num-channels = <1>;
+		#sound-dai-cells = <0>;
+	};
+
 	leds {
 		compatible = "gpio-leds";
 
@@ -98,6 +105,22 @@ reg_usdhc2_vmmc: regulator-usdhc2 {
 		enable-active-high;
 	};
 
+	sound-dmic {
+		compatible = "simple-audio-card";
+		simple-audio-card,name = "dmic";
+		simple-audio-card,format = "pdm";
+		simple-audio-card,bitclock-master = <&dailink_master>;
+		simple-audio-card,frame-master = <&dailink_master>;
+
+		dailink_master: simple-audio-card,cpu {
+			sound-dai = <&micfil>;
+		};
+
+		simple-audio-card,codec {
+			sound-dai = <&dmic_codec>;
+		};
+	};
+
 	sound-wm8962 {
 		compatible = "simple-audio-card";
 		simple-audio-card,name = "wm8962";
@@ -228,6 +251,16 @@ pca6416_1: gpio@21 {
 	};
 };
 
+&micfil {
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_pdm>;
+	assigned-clocks = <&clk IMX8MM_CLK_PDM>;
+	assigned-clock-parents = <&clk IMX8MM_AUDIO_PLL1_OUT>;
+	assigned-clock-rates = <49152000>;
+	status = "okay";
+	#sound-dai-cells = <0>;
+};
+
 &mipi_csi {
 	status = "okay";
 	ports {
@@ -365,6 +398,13 @@ MX8MM_IOMUXC_SAI2_MCLK_GPIO4_IO27		0x19
 		>;
 	};
 
+	pinctrl_pdm: pdmgrp {
+		fsl,pins = <
+			MX8MM_IOMUXC_SAI5_RXC_PDM_CLK	0xd6
+			MX8MM_IOMUXC_SAI5_RXD0_PDM_DATA0	0xd6
+		>;
+	};
+
 	pinctrl_reg_usb_otg1: usbotg1grp {
 		fsl,pins = <
 			MX8MM_IOMUXC_SAI3_RXC_GPIO4_IO29     0x19
-- 
2.39.2


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

* [PATCH 3/4] arm64: dts: imx8mn-beacon: Add DMIC support
  2023-08-31 11:51 [PATCH 1/4] arm64: dts: imx8mm-beacon: Migrate sound card to simple-audio-card Adam Ford
  2023-08-31 11:51 ` [PATCH 2/4] arm64: dts: imx8mm-beacon: Add DMIC support Adam Ford
@ 2023-08-31 11:51 ` Adam Ford
  2023-08-31 11:51 ` [PATCH 4/4] arm64: dts: imx8mp-beacon: " Adam Ford
  2 siblings, 0 replies; 7+ messages in thread
From: Adam Ford @ 2023-08-31 11:51 UTC (permalink / raw)
  To: linux-arm-kernel
  Cc: aford, Adam Ford, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Shawn Guo, Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam,
	NXP Linux Team, devicetree, linux-kernel

The baseboard has a connector for a pulse density microphone.
This is connected via the micfil interface and uses the DMIC
audio codec with the simple-audio-card.

Signed-off-by: Adam Ford <aford173@gmail.com>

diff --git a/arch/arm64/boot/dts/freescale/imx8mn-beacon-baseboard.dtsi b/arch/arm64/boot/dts/freescale/imx8mn-beacon-baseboard.dtsi
index 16761975f56e..0b51c0c71423 100644
--- a/arch/arm64/boot/dts/freescale/imx8mn-beacon-baseboard.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx8mn-beacon-baseboard.dtsi
@@ -4,6 +4,12 @@
  */
 
 / {
+	dmic_codec: dmic-codec {
+		compatible = "dmic-codec";
+		num-channels = <1>;
+		#sound-dai-cells = <0>;
+	};
+
 	leds {
 		compatible = "gpio-leds";
 
@@ -74,6 +80,22 @@ reg_usb_otg_vbus: regulator-usb {
 		enable-active-high;
 	};
 
+	sound-dmic {
+		compatible = "simple-audio-card";
+		simple-audio-card,name = "dmic";
+		simple-audio-card,format = "pdm";
+		simple-audio-card,bitclock-master = <&dailink_master>;
+		simple-audio-card,frame-master = <&dailink_master>;
+
+		dailink_master: simple-audio-card,cpu {
+			sound-dai = <&micfil>;
+		};
+
+		simple-audio-card,codec {
+			sound-dai = <&dmic_codec>;
+		};
+	};
+
 	sound-wm8962 {
 		compatible = "simple-audio-card";
 		simple-audio-card,name = "wm8962";
@@ -221,6 +243,16 @@ mipi_csi_in: endpoint {
 	};
 };
 
+&micfil {
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_pdm>;
+	assigned-clocks = <&clk IMX8MN_CLK_PDM>;
+	assigned-clock-parents = <&clk IMX8MN_AUDIO_PLL1_OUT>;
+	assigned-clock-rates = <49152000>;
+	status = "okay";
+	#sound-dai-cells = <0>;
+};
+
 &sai3 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_sai3>;
@@ -311,6 +343,13 @@ MX8MN_IOMUXC_SAI2_MCLK_GPIO4_IO27		0x19
 		>;
 	};
 
+	pinctrl_pdm: pdmgrp {
+		fsl,pins = <
+			MX8MN_IOMUXC_SAI5_RXC_PDM_CLK	0xd6
+			MX8MN_IOMUXC_SAI5_RXD0_PDM_BIT_STREAM0	0xd6
+		>;
+	};
+
 	pinctrl_reg_usb_otg: reg-otggrp {
 		fsl,pins = <
 			MX8MN_IOMUXC_SAI3_RXC_GPIO4_IO29     0x19
-- 
2.39.2


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

* [PATCH 4/4] arm64: dts: imx8mp-beacon: Add DMIC support
  2023-08-31 11:51 [PATCH 1/4] arm64: dts: imx8mm-beacon: Migrate sound card to simple-audio-card Adam Ford
  2023-08-31 11:51 ` [PATCH 2/4] arm64: dts: imx8mm-beacon: Add DMIC support Adam Ford
  2023-08-31 11:51 ` [PATCH 3/4] arm64: dts: imx8mn-beacon: " Adam Ford
@ 2023-08-31 11:51 ` Adam Ford
  2023-08-31 12:34   ` Adam Ford
  2023-08-31 23:13   ` kernel test robot
  2 siblings, 2 replies; 7+ messages in thread
From: Adam Ford @ 2023-08-31 11:51 UTC (permalink / raw)
  To: linux-arm-kernel
  Cc: aford, Adam Ford, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Shawn Guo, Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam,
	NXP Linux Team, devicetree, linux-kernel

The baseboard has a connector for a pulse density microphone.
This is connected via the micfil interface and uses the DMIC
audio codec with the simple-audio-card.

Signed-off-by: Adam Ford <aford173@gmail.com>

diff --git a/arch/arm64/boot/dts/freescale/imx8mp-beacon-kit.dts b/arch/arm64/boot/dts/freescale/imx8mp-beacon-kit.dts
index acd265d8b58e..ee64c6ffb551 100644
--- a/arch/arm64/boot/dts/freescale/imx8mp-beacon-kit.dts
+++ b/arch/arm64/boot/dts/freescale/imx8mp-beacon-kit.dts
@@ -49,6 +49,12 @@ ss_ep: endpoint {
 		};
 	};
 
+	dmic_codec: dmic-codec {
+		compatible = "dmic-codec";
+		num-channels = <1>;
+		#sound-dai-cells = <0>;
+	};
+
 	gpio-keys {
 		compatible = "gpio-keys";
 		autorepeat;
@@ -147,6 +153,22 @@ reg_usb1_host_vbus: regulator-usb1-vbus {
 		enable-active-high;
 	};
 
+	sound-dmic {
+		compatible = "simple-audio-card";
+		simple-audio-card,name = "sound-pdm";
+		simple-audio-card,format = "i2s";
+		simple-audio-card,bitclock-master = <&dailink_master>;
+		simple-audio-card,frame-master = <&dailink_master>;
+
+		dailink_master: simple-audio-card,cpu {
+			sound-dai = <&micfil>;
+		};
+
+		simple-audio-card,codec {
+			sound-dai = <&dmic_codec>;
+		};
+	};
+
 	sound-wm8962 {
 		compatible = "simple-audio-card";
 		simple-audio-card,name = "wm8962";
@@ -174,6 +196,11 @@ simple-audio-card,codec {
 	};
 };
 
+&audio_blk_ctrl {
+	assigned-clocks = <&clk IMX8MP_AUDIO_PLL1>, <&clk IMX8MP_AUDIO_PLL2>;
+	assigned-clock-rates = <393216000>, <135475200>;
+};
+
 &ecspi2 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_ecspi2>;
@@ -364,6 +391,15 @@ hd3ss3220_out_ep: endpoint {
 	};
 };
 
+&micfil {
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_pdm>;
+	assigned-clocks = <&clk IMX8MP_CLK_PDM>;
+	assigned-clock-parents = <&clk IMX8MP_AUDIO_PLL1_OUT>;
+	assigned-clock-rates = <49152000>;
+	status = "okay";
+};
+
 &pcie {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie>;
@@ -545,6 +581,13 @@ MX8MP_IOMUXC_SAI2_RXFS__GPIO4_IO21 0x10	/* PCIe_nRST */
 		>;
 	};
 
+	pinctrl_pdm: pdmgrp {
+		fsl,pins = <
+			MX8MP_IOMUXC_SAI5_RXC__AUDIOMIX_PDM_CLK		0xd6
+			MX8MP_IOMUXC_SAI5_RXD0__AUDIOMIX_PDM_BIT_STREAM00	0xd6
+		>;
+	};
+
 	pinctrl_reg_usdhc2_vmmc: regusdhc2vmmcgrp {
 		fsl,pins = <
 			MX8MP_IOMUXC_SD2_RESET_B__GPIO2_IO19	0x40
-- 
2.39.2


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

* Re: [PATCH 4/4] arm64: dts: imx8mp-beacon: Add DMIC support
  2023-08-31 11:51 ` [PATCH 4/4] arm64: dts: imx8mp-beacon: " Adam Ford
@ 2023-08-31 12:34   ` Adam Ford
  2023-08-31 23:13   ` kernel test robot
  1 sibling, 0 replies; 7+ messages in thread
From: Adam Ford @ 2023-08-31 12:34 UTC (permalink / raw)
  To: linux-arm-kernel
  Cc: aford, Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
	Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam,
	NXP Linux Team, devicetree, linux-kernel

On Thu, Aug 31, 2023 at 6:51 AM Adam Ford <aford173@gmail.com> wrote:
>
> The baseboard has a connector for a pulse density microphone.
> This is connected via the micfil interface and uses the DMIC
> audio codec with the simple-audio-card.
>
> Signed-off-by: Adam Ford <aford173@gmail.com>
>

Shawn,

I forgot to mention that this patch depends on a different patch that is found:

https://patchwork.kernel.org/project/linux-arm-kernel/patch/20230831044431.250338-2-aford173@gmail.com/

Sorry about that.

adam

> diff --git a/arch/arm64/boot/dts/freescale/imx8mp-beacon-kit.dts b/arch/arm64/boot/dts/freescale/imx8mp-beacon-kit.dts
> index acd265d8b58e..ee64c6ffb551 100644
> --- a/arch/arm64/boot/dts/freescale/imx8mp-beacon-kit.dts
> +++ b/arch/arm64/boot/dts/freescale/imx8mp-beacon-kit.dts
> @@ -49,6 +49,12 @@ ss_ep: endpoint {
>                 };
>         };
>
> +       dmic_codec: dmic-codec {
> +               compatible = "dmic-codec";
> +               num-channels = <1>;
> +               #sound-dai-cells = <0>;
> +       };
> +
>         gpio-keys {
>                 compatible = "gpio-keys";
>                 autorepeat;
> @@ -147,6 +153,22 @@ reg_usb1_host_vbus: regulator-usb1-vbus {
>                 enable-active-high;
>         };
>
> +       sound-dmic {
> +               compatible = "simple-audio-card";
> +               simple-audio-card,name = "sound-pdm";
> +               simple-audio-card,format = "i2s";
> +               simple-audio-card,bitclock-master = <&dailink_master>;
> +               simple-audio-card,frame-master = <&dailink_master>;
> +
> +               dailink_master: simple-audio-card,cpu {
> +                       sound-dai = <&micfil>;
> +               };
> +
> +               simple-audio-card,codec {
> +                       sound-dai = <&dmic_codec>;
> +               };
> +       };
> +
>         sound-wm8962 {
>                 compatible = "simple-audio-card";
>                 simple-audio-card,name = "wm8962";
> @@ -174,6 +196,11 @@ simple-audio-card,codec {
>         };
>  };
>
> +&audio_blk_ctrl {
> +       assigned-clocks = <&clk IMX8MP_AUDIO_PLL1>, <&clk IMX8MP_AUDIO_PLL2>;
> +       assigned-clock-rates = <393216000>, <135475200>;
> +};
> +
>  &ecspi2 {
>         pinctrl-names = "default";
>         pinctrl-0 = <&pinctrl_ecspi2>;
> @@ -364,6 +391,15 @@ hd3ss3220_out_ep: endpoint {
>         };
>  };
>
> +&micfil {
> +       pinctrl-names = "default";
> +       pinctrl-0 = <&pinctrl_pdm>;
> +       assigned-clocks = <&clk IMX8MP_CLK_PDM>;
> +       assigned-clock-parents = <&clk IMX8MP_AUDIO_PLL1_OUT>;
> +       assigned-clock-rates = <49152000>;
> +       status = "okay";
> +};
> +
>  &pcie {
>         pinctrl-names = "default";
>         pinctrl-0 = <&pinctrl_pcie>;
> @@ -545,6 +581,13 @@ MX8MP_IOMUXC_SAI2_RXFS__GPIO4_IO21 0x10    /* PCIe_nRST */
>                 >;
>         };
>
> +       pinctrl_pdm: pdmgrp {
> +               fsl,pins = <
> +                       MX8MP_IOMUXC_SAI5_RXC__AUDIOMIX_PDM_CLK         0xd6
> +                       MX8MP_IOMUXC_SAI5_RXD0__AUDIOMIX_PDM_BIT_STREAM00       0xd6
> +               >;
> +       };
> +
>         pinctrl_reg_usdhc2_vmmc: regusdhc2vmmcgrp {
>                 fsl,pins = <
>                         MX8MP_IOMUXC_SD2_RESET_B__GPIO2_IO19    0x40
> --
> 2.39.2
>

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

* Re: [PATCH 4/4] arm64: dts: imx8mp-beacon: Add DMIC support
  2023-08-31 11:51 ` [PATCH 4/4] arm64: dts: imx8mp-beacon: " Adam Ford
  2023-08-31 12:34   ` Adam Ford
@ 2023-08-31 23:13   ` kernel test robot
  1 sibling, 0 replies; 7+ messages in thread
From: kernel test robot @ 2023-08-31 23:13 UTC (permalink / raw)
  To: Adam Ford, linux-arm-kernel
  Cc: oe-kbuild-all, aford, Adam Ford, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Shawn Guo, Sascha Hauer, Pengutronix Kernel Team,
	Fabio Estevam, NXP Linux Team, devicetree, linux-kernel

Hi Adam,

kernel test robot noticed the following build errors:

[auto build test ERROR on robh/for-next]
[also build test ERROR on arm/for-next arm64/for-next/core kvmarm/next rockchip/for-next shawnguo/for-next soc/for-next linus/master v6.5 next-20230831]
[cannot apply to arm/fixes]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Adam-Ford/arm64-dts-imx8mm-beacon-Add-DMIC-support/20230831-195442
base:   https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git for-next
patch link:    https://lore.kernel.org/r/20230831115128.254226-4-aford173%40gmail.com
patch subject: [PATCH 4/4] arm64: dts: imx8mp-beacon: Add DMIC support
config: arm64-defconfig (https://download.01.org/0day-ci/archive/20230901/202309010735.D668npQl-lkp@intel.com/config)
compiler: aarch64-linux-gcc (GCC) 13.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20230901/202309010735.D668npQl-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202309010735.D668npQl-lkp@intel.com/

All errors (new ones prefixed by >>):

>> Error: arch/arm64/boot/dts/freescale/imx8mp-beacon-kit.dts:394.1-8 Label or path micfil not found
>> FATAL ERROR: Syntax error parsing input tree

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

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

* Re: [PATCH 2/4] arm64: dts: imx8mm-beacon: Add DMIC support
  2023-08-31 11:51 ` [PATCH 2/4] arm64: dts: imx8mm-beacon: Add DMIC support Adam Ford
@ 2023-09-25  1:14   ` Shawn Guo
  0 siblings, 0 replies; 7+ messages in thread
From: Shawn Guo @ 2023-09-25  1:14 UTC (permalink / raw)
  To: Adam Ford
  Cc: linux-arm-kernel, aford, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Sascha Hauer, Pengutronix Kernel Team,
	Fabio Estevam, NXP Linux Team, devicetree, linux-kernel

On Thu, Aug 31, 2023 at 06:51:26AM -0500, Adam Ford wrote:
> The baseboard has a connector for a pulse density microphone.
> This is connected via the micfil interface and uses the DMIC
> audio codec with the simple-audio-card.
> 
> Signed-off-by: Adam Ford <aford173@gmail.com>
> 
> diff --git a/arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi
> index 313e93663d6f..d0dd4c81a557 100644
> --- a/arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi
> +++ b/arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi
> @@ -6,6 +6,13 @@
>  #include <dt-bindings/phy/phy-imx8-pcie.h>
>  
>  / {
> +
> +	dmic_codec: dmic-codec {
> +		compatible = "dmic-codec";
> +		num-channels = <1>;
> +		#sound-dai-cells = <0>;
> +	};
> +
>  	leds {
>  		compatible = "gpio-leds";
>  
> @@ -98,6 +105,22 @@ reg_usdhc2_vmmc: regulator-usdhc2 {
>  		enable-active-high;
>  	};
>  
> +	sound-dmic {
> +		compatible = "simple-audio-card";
> +		simple-audio-card,name = "dmic";
> +		simple-audio-card,format = "pdm";
> +		simple-audio-card,bitclock-master = <&dailink_master>;
> +		simple-audio-card,frame-master = <&dailink_master>;
> +
> +		dailink_master: simple-audio-card,cpu {
> +			sound-dai = <&micfil>;
> +		};
> +
> +		simple-audio-card,codec {
> +			sound-dai = <&dmic_codec>;
> +		};
> +	};
> +
>  	sound-wm8962 {
>  		compatible = "simple-audio-card";
>  		simple-audio-card,name = "wm8962";
> @@ -228,6 +251,16 @@ pca6416_1: gpio@21 {
>  	};
>  };
>  
> +&micfil {
> +	pinctrl-names = "default";
> +	pinctrl-0 = <&pinctrl_pdm>;
> +	assigned-clocks = <&clk IMX8MM_CLK_PDM>;
> +	assigned-clock-parents = <&clk IMX8MM_AUDIO_PLL1_OUT>;
> +	assigned-clock-rates = <49152000>;
> +	status = "okay";

We usually end property list with 'status'.

Shawn

> +	#sound-dai-cells = <0>;
> +};
> +
>  &mipi_csi {
>  	status = "okay";
>  	ports {
> @@ -365,6 +398,13 @@ MX8MM_IOMUXC_SAI2_MCLK_GPIO4_IO27		0x19
>  		>;
>  	};
>  
> +	pinctrl_pdm: pdmgrp {
> +		fsl,pins = <
> +			MX8MM_IOMUXC_SAI5_RXC_PDM_CLK	0xd6
> +			MX8MM_IOMUXC_SAI5_RXD0_PDM_DATA0	0xd6
> +		>;
> +	};
> +
>  	pinctrl_reg_usb_otg1: usbotg1grp {
>  		fsl,pins = <
>  			MX8MM_IOMUXC_SAI3_RXC_GPIO4_IO29     0x19
> -- 
> 2.39.2
> 

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

end of thread, other threads:[~2023-09-25  1:15 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-31 11:51 [PATCH 1/4] arm64: dts: imx8mm-beacon: Migrate sound card to simple-audio-card Adam Ford
2023-08-31 11:51 ` [PATCH 2/4] arm64: dts: imx8mm-beacon: Add DMIC support Adam Ford
2023-09-25  1:14   ` Shawn Guo
2023-08-31 11:51 ` [PATCH 3/4] arm64: dts: imx8mn-beacon: " Adam Ford
2023-08-31 11:51 ` [PATCH 4/4] arm64: dts: imx8mp-beacon: " Adam Ford
2023-08-31 12:34   ` Adam Ford
2023-08-31 23:13   ` kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).