[alsa-devel] [PATCH 5/5] ARM: dt: tegra cardhu: basic audio support

Stephen Warren swarren at wwwdotorg.org
Sat Mar 31 01:11:37 CEST 2012


From: Stephen Warren <swarren at nvidia.com>

Add WM8903 codec nodes, and top-level sound complex node for basic
analog audio over headset jack and internal speakers.

Signed-off-by: Stephen Warren <swarren at nvidia.com>
---
 arch/arm/boot/dts/tegra-cardhu.dts |   61 ++++++++++++++++++++++++++++++++++++
 1 files changed, 61 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boot/dts/tegra-cardhu.dts b/arch/arm/boot/dts/tegra-cardhu.dts
index 0a9f34a..38a2b32 100644
--- a/arch/arm/boot/dts/tegra-cardhu.dts
+++ b/arch/arm/boot/dts/tegra-cardhu.dts
@@ -51,6 +51,15 @@
 				nvidia,pull = <2>;
 				nvidia,tristate = <0>;
 			};
+			dap2_fs_pa2 {
+				nvidia,pins =	"dap2_fs_pa2",
+						"dap2_sclk_pa3",
+						"dap2_din_pa4",
+						"dap2_dout_pa5";
+				nvidia,function = "i2s1";
+				nvidia,pull = <0>;
+				nvidia,tristate = <0>;
+			};
 		};
 	};
 
@@ -92,6 +101,20 @@
 
 	i2c at 7000d000 {
 		clock-frequency = <100000>;
+
+		wm8903: wm8903 at 1a {
+			compatible = "wlf,wm8903";
+			reg = <0x1a>;
+			interrupt-parent = <&gpio>;
+			interrupts = <179 0x04>; /* gpio PW3 */
+
+			gpio-controller;
+			#gpio-cells = <2>;
+
+			micdet-cfg = <0>;
+			micdet-delay = <100>;
+			gpio-cfg = <0xffffffff 0xffffffff 0 0xffffffff 0xffffffff>;
+		};
 	};
 
 	sdhci at 78000000 {
@@ -111,4 +134,42 @@
 	sdhci at 78000400 {
 		support-8bit;
 	};
+
+	i2s at 70080300 {
+		status = "disable";
+	};
+
+	i2s at 70080500 {
+		status = "disable";
+	};
+
+	i2s at 70080600 {
+		status = "disable";
+	};
+
+	i2s at 70080700 {
+		status = "disable";
+	};
+
+	sound {
+		compatible = "nvidia,tegra30-audio-wm8903-cardhu",
+			     "nvidia,tegra30-audio-wm8903";
+		nvidia,model = "NVIDIA Tegra Cardhu";
+
+		nvidia,audio-routing =
+			"Headphone Jack", "HPOUTR",
+			"Headphone Jack", "HPOUTL",
+			"Int Spk", "ROP",
+			"Int Spk", "RON",
+			"Int Spk", "LOP",
+			"Int Spk", "LON",
+			"Mic Jack", "MICBIAS",
+			"IN1L", "Mic Jack";
+
+		nvidia,i2s-controller = <&tegra_i2s1>;
+		nvidia,audio-codec = <&wm8903>;
+
+		nvidia,spkr-en-gpios = <&wm8903 2 0>;
+		nvidia,hp-det-gpios = <&gpio 178 0>; /* gpio PW2 */
+	};
 };
-- 
1.7.0.4



More information about the Alsa-devel mailing list