]> www.infradead.org Git - linux.git/commitdiff
arm64: dts: qcom: qrb4210-rb2: add HDMI audio playback support
authorAlexey Klimov <alexey.klimov@linaro.org>
Tue, 12 Nov 2024 02:53:06 +0000 (02:53 +0000)
committerBjorn Andersson <andersson@kernel.org>
Fri, 27 Dec 2024 04:26:09 +0000 (22:26 -0600)
Add sound node and dsp-related piece to enable HDMI audio
playback support on Qualcomm QRB4210 RB2 board. That is the
only sound output supported for now.

The audio playback is verified using the following commands:

amixer -c0 cset iface=MIXER,name='SEC_MI2S_RX Audio Mixer MultiMedia1' 1
aplay -D hw:0,0 /usr/share/sounds/alsa/Front_Center.wav

Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Signed-off-by: Alexey Klimov <alexey.klimov@linaro.org>
Link: https://lore.kernel.org/r/20241112025306.712122-5-alexey.klimov@linaro.org
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
arch/arm64/boot/dts/qcom/qrb4210-rb2.dts

index d8d4cff7d5abed405d1b4cdf9ab8264aab076830..52db18847803e3d6bc7acf34f5b9b4f0f10e8f32 100644 (file)
@@ -6,6 +6,8 @@
 /dts-v1/;
 
 #include <dt-bindings/leds/common.h>
+#include <dt-bindings/sound/qcom,q6afe.h>
+#include <dt-bindings/sound/qcom,q6asm.h>
 #include <dt-bindings/usb/pd.h>
 #include "sm4250.dtsi"
 #include "pm6125.dtsi"
                };
        };
 
+       sound {
+               compatible = "qcom,qrb4210-rb2-sndcard";
+               pinctrl-0 = <&lpi_i2s2_active>;
+               pinctrl-names = "default";
+               model = "Qualcomm-RB2-WSA8815-Speakers-DMIC0";
+               audio-routing = "MM_DL1", "MultiMedia1 Playback",
+                               "MM_DL2", "MultiMedia2 Playback";
+
+               mm1-dai-link {
+                       link-name = "MultiMedia1";
+
+                       cpu {
+                               sound-dai = <&q6asmdai MSM_FRONTEND_DAI_MULTIMEDIA1>;
+                       };
+               };
+
+               mm2-dai-link {
+                       link-name = "MultiMedia2";
+
+                       cpu {
+                               sound-dai = <&q6asmdai MSM_FRONTEND_DAI_MULTIMEDIA2>;
+                       };
+               };
+
+               mm3-dai-link {
+                       link-name = "MultiMedia3";
+
+                       cpu {
+                               sound-dai = <&q6asmdai MSM_FRONTEND_DAI_MULTIMEDIA3>;
+                       };
+               };
+
+               hdmi-dai-link {
+                       link-name = "HDMI Playback";
+
+                       cpu {
+                               sound-dai = <&q6afedai SECONDARY_MI2S_RX>;
+                       };
+
+                       platform {
+                               sound-dai = <&q6routing>;
+                       };
+
+                       codec {
+                               sound-dai = <&lt9611_codec 0>;
+                       };
+               };
+       };
+
        vreg_hdmi_out_1p2: regulator-hdmi-out-1p2 {
                compatible = "regulator-fixed";
                regulator-name = "VREG_HDMI_OUT_1P2";
        status = "okay";
 };
 
+/* SECONDARY I2S uses 1 I2S SD Line for audio on LT9611UXC HDMI Bridge */
+&q6afedai {
+       dai@20 {
+               reg = <SECONDARY_MI2S_RX>;
+               qcom,sd-lines = <0>;
+       };
+};
+
 &qupv3_id_0 {
        status = "okay";
 };