ARM: dts: ls1021a: Add dts nodes for audio on LS1021A
authorAlison Wang <b18965@freescale.com>
Wed, 15 Jul 2015 08:02:46 +0000 (16:02 +0800)
committerShawn Guo <shawnguo@kernel.org>
Tue, 11 Aug 2015 15:15:19 +0000 (23:15 +0800)
This patch adds dts nodes for audio on LS1021A.

Signed-off-by: Alison Wang <alison.wang@freescale.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
arch/arm/boot/dts/ls1021a-qds.dts
arch/arm/boot/dts/ls1021a-twr.dts
arch/arm/boot/dts/ls1021a.dtsi

index 9c5e16ba8c951701f49313862aa753b337dd15c6..4e64f38c35c68ea6d6a6672eb94809a7328268a1 100644 (file)
                enet0_sgmii_phy = &sgmii_phy1c;
                enet1_sgmii_phy = &sgmii_phy1d;
        };
+
+       sys_mclk: clock-mclk {
+               compatible = "fixed-clock";
+               #clock-cells = <0>;
+               clock-frequency = <24576000>;
+       };
+
+       regulators {
+               compatible = "simple-bus";
+               #address-cells = <1>;
+               #size-cells = <0>;
+
+               reg_3p3v: regulator@0 {
+                       compatible = "regulator-fixed";
+                       reg = <0>;
+                       regulator-name = "3P3V";
+                       regulator-min-microvolt = <3300000>;
+                       regulator-max-microvolt = <3300000>;
+                       regulator-always-on;
+               };
+       };
+
+       sound {
+               compatible = "simple-audio-card";
+               simple-audio-card,format = "i2s";
+               simple-audio-card,widgets =
+                       "Microphone", "Microphone Jack",
+                       "Headphone", "Headphone Jack",
+                       "Speaker", "Speaker Ext",
+                       "Line", "Line In Jack";
+               simple-audio-card,routing =
+                       "MIC_IN", "Microphone Jack",
+                       "Microphone Jack", "Mic Bias",
+                       "LINE_IN", "Line In Jack",
+                       "Headphone Jack", "HP_OUT",
+                       "Speaker Ext", "LINE_OUT";
+
+               simple-audio-card,cpu {
+                       sound-dai = <&sai2>;
+                       frame-master;
+                       bitclock-master;
+               };
+
+               simple-audio-card,codec {
+                       sound-dai = <&codec>;
+                       frame-master;
+                       bitclock-master;
+               };
+       };
 };
 
 &dspi0 {
        status = "okay";
 
        pca9547: mux@77 {
+               compatible = "nxp,pca9547";
                reg = <0x77>;
                #address-cells = <1>;
                #size-cells = <0>;
                                reg = <0x4c>;
                        };
                };
+
+               i2c@4 {
+                       #address-cells = <1>;
+                       #size-cells = <0>;
+                       reg = <0x4>;
+
+                       codec: sgtl5000@2a {
+                               #sound-dai-cells = <0>;
+                               compatible = "fsl,sgtl5000";
+                               reg = <0x2a>;
+                               VDDA-supply = <&reg_3p3v>;
+                               VDDIO-supply = <&reg_3p3v>;
+                               clocks = <&sys_mclk 1>;
+                       };
+               };
        };
 };
 
        };
 };
 
+&sai2 {
+       status = "okay";
+};
+
 &uart0 {
        status = "okay";
 };
index a2c591e2d9183af91c6653735fd71b5b2584f17d..db41e4f63f7e91b79d44bb6f4097a1cc88a324e7 100644 (file)
                enet0_sgmii_phy = &sgmii_phy2;
                enet1_sgmii_phy = &sgmii_phy0;
        };
+
+       sys_mclk: clock-mclk {
+               compatible = "fixed-clock";
+               #clock-cells = <0>;
+               clock-frequency = <24576000>;
+       };
+
+       regulators {
+               compatible = "simple-bus";
+               #address-cells = <1>;
+               #size-cells = <0>;
+
+               reg_3p3v: regulator@0 {
+                       compatible = "regulator-fixed";
+                       reg = <0>;
+                       regulator-name = "3P3V";
+                       regulator-min-microvolt = <3300000>;
+                       regulator-max-microvolt = <3300000>;
+                       regulator-always-on;
+               };
+       };
+
+       sound {
+               compatible = "simple-audio-card";
+               simple-audio-card,format = "i2s";
+               simple-audio-card,widgets =
+                       "Microphone", "Microphone Jack",
+                       "Headphone", "Headphone Jack",
+                       "Speaker", "Speaker Ext",
+                       "Line", "Line In Jack";
+               simple-audio-card,routing =
+                       "MIC_IN", "Microphone Jack",
+                       "Microphone Jack", "Mic Bias",
+                       "LINE_IN", "Line In Jack",
+                       "Headphone Jack", "HP_OUT",
+                       "Speaker Ext", "LINE_OUT";
+
+               simple-audio-card,cpu {
+                       sound-dai = <&sai1>;
+                       frame-master;
+                       bitclock-master;
+               };
+
+               simple-audio-card,codec {
+                       sound-dai = <&codec>;
+                       frame-master;
+                       bitclock-master;
+               };
+       };
 };
 
 &dspi1 {
 
 &i2c1 {
        status = "okay";
+       codec: sgtl5000@a {
+               #sound-dai-cells = <0>;
+               compatible = "fsl,sgtl5000";
+               reg = <0x0a>;
+               VDDA-supply = <&reg_3p3v>;
+               VDDIO-supply = <&reg_3p3v>;
+               clocks = <&sys_mclk 1>;
+       };
 };
 
 &ifc {
        };
 };
 
+&sai1 {
+       status = "okay";
+};
+
 &uart0 {
        status = "okay";
 };
index 1b306c7ed72e8fcdd4697ee3ca45a5ff4fe81bde..71ea37d11228bd5a627d9fb3aac11ba3efca947d 100644 (file)
                };
 
                sai1: sai@2b50000 {
+                       #sound-dai-cells = <0>;
                        compatible = "fsl,vf610-sai";
                        reg = <0x0 0x2b50000 0x0 0x10000>;
                        interrupts = <GIC_SPI 132 IRQ_TYPE_LEVEL_HIGH>;
-                       clocks = <&platform_clk 1>;
-                       clock-names = "sai";
+                       clocks = <&platform_clk 1>, <&platform_clk 1>,
+                                <&platform_clk 1>, <&platform_clk 1>;
+                       clock-names = "bus", "mclk1", "mclk2", "mclk3";
                        dma-names = "tx", "rx";
                        dmas = <&edma0 1 47>,
                               <&edma0 1 46>;
-                       big-endian;
                        status = "disabled";
                };
 
                sai2: sai@2b60000 {
+                       #sound-dai-cells = <0>;
                        compatible = "fsl,vf610-sai";
                        reg = <0x0 0x2b60000 0x0 0x10000>;
                        interrupts = <GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>;
-                       clocks = <&platform_clk 1>;
-                       clock-names = "sai";
+                       clocks = <&platform_clk 1>, <&platform_clk 1>,
+                                <&platform_clk 1>, <&platform_clk 1>;
+                       clock-names = "bus", "mclk1", "mclk2", "mclk3";
                        dma-names = "tx", "rx";
                        dmas = <&edma0 1 45>,
                               <&edma0 1 44>;
-                       big-endian;
                        status = "disabled";
                };
 
This page took 0.028613 seconds and 5 git commands to generate.