From aa4adbb38305d71d4859695584a1262eb1dae1e6 Mon Sep 17 00:00:00 2001 From: Raghu Bankapur Date: Wed, 17 Aug 2022 16:00:17 +0530 Subject: [PATCH 1/3] Audio-devicetree: Seperate TX and RX for primary AUX PCM Create seperate device node for primary aux PCM. Change-Id: I16a50f435be8c1921916556a2b9180c1eeea512c Signed-off-by: Raghu Bankapur --- msm-auto-audio-lpass.dtsi | 16 +++++++++++++++- sa8155-audio.dtsi | 8 ++++---- 2 files changed, 19 insertions(+), 5 deletions(-) diff --git a/msm-auto-audio-lpass.dtsi b/msm-auto-audio-lpass.dtsi index 381131be..8511e203 100644 --- a/msm-auto-audio-lpass.dtsi +++ b/msm-auto-audio-lpass.dtsi @@ -415,7 +415,21 @@ qcom,msm-cpudai-auxpcm-slot-mapping = <1>, <1>; qcom,msm-cpudai-auxpcm-data = <0>, <0>; qcom,msm-cpudai-auxpcm-pcm-clk-rate = <2048000>, <2048000>; - qcom,msm-auxpcm-interface = "primary"; + qcom,msm-auxpcm-interface = "primaryRx"; + qcom,msm-cpudai-afe-clk-ver = <2>; + }; + + dai_pri_auxpcm_tx: qcom,msm-pri-auxpcm_tx { + compatible = "qcom,msm-auxpcm-dev"; + qcom,msm-cpudai-auxpcm-mode = <0>, <0>; + qcom,msm-cpudai-auxpcm-sync = <1>, <1>; + qcom,msm-cpudai-auxpcm-frame = <5>, <4>; + qcom,msm-cpudai-auxpcm-quant = <2>, <2>; + qcom,msm-cpudai-auxpcm-num-slots = <1>, <1>; + qcom,msm-cpudai-auxpcm-slot-mapping = <1>, <1>; + qcom,msm-cpudai-auxpcm-data = <0>, <0>; + qcom,msm-cpudai-auxpcm-pcm-clk-rate = <2048000>, <2048000>; + qcom,msm-auxpcm-interface = "primaryTx"; qcom,msm-cpudai-afe-clk-ver = <2>; }; diff --git a/sa8155-audio.dtsi b/sa8155-audio.dtsi index d3e50dc5..1b64a603 100644 --- a/sa8155-audio.dtsi +++ b/sa8155-audio.dtsi @@ -512,7 +512,7 @@ <&dai_mi2s2_rx>, <&dai_mi2s2_tx>, <&dai_mi2s3_rx>, <&dai_mi2s3_tx>, <&dai_mi2s4_rx>, <&dai_mi2s4_tx>, - <&dai_pri_auxpcm>, + <&dai_pri_auxpcm>, <&dai_pri_auxpcm_tx>, <&dai_sec_auxpcm>, <&dai_tert_auxpcm>, <&dai_quat_auxpcm>, <&dai_quin_auxpcm>, <&afe_pcm_rx>, <&afe_pcm_tx>, @@ -551,9 +551,9 @@ "msm-dai-q6-mi2s.4", "msm-dai-q6-mi2s.5", "msm-dai-q6-mi2s.6", "msm-dai-q6-mi2s.7", "msm-dai-q6-mi2s.8", "msm-dai-q6-mi2s.9", - "msm-dai-q6-auxpcm.1", - "msm-dai-q6-auxpcm.2", "msm-dai-q6-auxpcm.3", - "msm-dai-q6-auxpcm.4", "msm-dai-q6-auxpcm.5", + "msm-dai-q6-auxpcm.1","msm-dai-q6-auxpcm.2", + "msm-dai-q6-auxpcm.3", "msm-dai-q6-auxpcm.4", + "msm-dai-q6-auxpcm.5", "msm-dai-q6-auxpcm.6", "msm-dai-q6-dev.224", "msm-dai-q6-dev.225", "msm-dai-q6-dev.241", "msm-dai-q6-dev.240", "msm-dai-q6-dev.226", "msm-dai-q6-dev.242", From bf81a7c450bf2d7c1e5a6cc7817113caa4ca6886 Mon Sep 17 00:00:00 2001 From: sasevs Date: Wed, 17 Aug 2022 12:32:29 +0530 Subject: [PATCH 2/3] audio dts: add support for 8195 target add support for sa8195 target. soundcard will be named as "sa8155-adp-start-snd-card". Change-Id: I86b08fc790cb206cdf4284832f6fafd690fe5e47 --- sa8155-audio.dts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sa8155-audio.dts b/sa8155-audio.dts index 45c82f41..eefe35d0 100644 --- a/sa8155-audio.dts +++ b/sa8155-audio.dts @@ -13,6 +13,7 @@ model = "Qualcomm Technologies, Inc. SA8155"; compatible = "qcom,sa8155"; qcom,msm-id = <339 0x10000>, <339 0x20000>, <362 0x10000>, - <362 0x20000>, <367 0x10000>, <367 0x20000>; + <362 0x20000>, <367 0x10000>, <367 0x20000>, + <405 0x20000>; qcom,board-id = <0 0>; }; From ce3d955e7c080f092d421633c61b50d56100061f Mon Sep 17 00:00:00 2001 From: Raghu Bankapur Date: Mon, 22 Aug 2022 10:46:13 +0530 Subject: [PATCH 3/3] audio-devicetree: AUX PCM TX and RX separation Create separate device tree node for AUX PCM. Change-Id: I3910076ea5f626a13169dd9e11b6f30974dea41c --- msm-auto-audio-lpass.dtsi | 92 ++++++++++++++++++++++++++++++++++----- sa8155-audio.dtsi | 12 +++-- 2 files changed, 89 insertions(+), 15 deletions(-) diff --git a/msm-auto-audio-lpass.dtsi b/msm-auto-audio-lpass.dtsi index 8511e203..1d3f86b0 100644 --- a/msm-auto-audio-lpass.dtsi +++ b/msm-auto-audio-lpass.dtsi @@ -405,7 +405,7 @@ }; }; - dai_pri_auxpcm: qcom,msm-pri-auxpcm { + dai_pri_auxpcm_rx: qcom,msm-pri-auxpcm_rx { compatible = "qcom,msm-auxpcm-dev"; qcom,msm-cpudai-auxpcm-mode = <0>, <0>; qcom,msm-cpudai-auxpcm-sync = <1>, <1>; @@ -433,7 +433,7 @@ qcom,msm-cpudai-afe-clk-ver = <2>; }; - dai_sec_auxpcm: qcom,msm-sec-auxpcm { + dai_sec_auxpcm_rx: qcom,msm-sec-auxpcm_rx { compatible = "qcom,msm-auxpcm-dev"; qcom,msm-cpudai-auxpcm-mode = <0>, <0>; qcom,msm-cpudai-auxpcm-sync = <1>, <1>; @@ -443,11 +443,11 @@ qcom,msm-cpudai-auxpcm-slot-mapping = <1>, <1>; qcom,msm-cpudai-auxpcm-data = <0>, <0>; qcom,msm-cpudai-auxpcm-pcm-clk-rate = <2048000>, <2048000>; - qcom,msm-auxpcm-interface = "secondary"; + qcom,msm-auxpcm-interface = "secondaryRx"; qcom,msm-cpudai-afe-clk-ver = <2>; }; - dai_tert_auxpcm: qcom,msm-tert-auxpcm { + dai_sec_auxpcm_tx: qcom,msm-sec-auxpcm_tx { compatible = "qcom,msm-auxpcm-dev"; qcom,msm-cpudai-auxpcm-mode = <0>, <0>; qcom,msm-cpudai-auxpcm-sync = <1>, <1>; @@ -457,11 +457,11 @@ qcom,msm-cpudai-auxpcm-slot-mapping = <1>, <1>; qcom,msm-cpudai-auxpcm-data = <0>, <0>; qcom,msm-cpudai-auxpcm-pcm-clk-rate = <2048000>, <2048000>; - qcom,msm-auxpcm-interface = "tertiary"; + qcom,msm-auxpcm-interface = "secondaryTx"; qcom,msm-cpudai-afe-clk-ver = <2>; }; - dai_quat_auxpcm: qcom,msm-quat-auxpcm { + dai_tert_auxpcm_rx: qcom,msm-tert-auxpcm_rx { compatible = "qcom,msm-auxpcm-dev"; qcom,msm-cpudai-auxpcm-mode = <0>, <0>; qcom,msm-cpudai-auxpcm-sync = <1>, <1>; @@ -471,11 +471,11 @@ qcom,msm-cpudai-auxpcm-slot-mapping = <1>, <1>; qcom,msm-cpudai-auxpcm-data = <0>, <0>; qcom,msm-cpudai-auxpcm-pcm-clk-rate = <2048000>, <2048000>; - qcom,msm-auxpcm-interface = "quaternary"; + qcom,msm-auxpcm-interface = "tertiaryRx"; qcom,msm-cpudai-afe-clk-ver = <2>; }; - dai_quin_auxpcm: qcom,msm-quin-auxpcm { + dai_tert_auxpcm_tx: qcom,msm-tert-auxpcm_tx { compatible = "qcom,msm-auxpcm-dev"; qcom,msm-cpudai-auxpcm-mode = <0>, <0>; qcom,msm-cpudai-auxpcm-sync = <1>, <1>; @@ -485,11 +485,11 @@ qcom,msm-cpudai-auxpcm-slot-mapping = <1>, <1>; qcom,msm-cpudai-auxpcm-data = <0>, <0>; qcom,msm-cpudai-auxpcm-pcm-clk-rate = <2048000>, <2048000>; - qcom,msm-auxpcm-interface = "quinary"; + qcom,msm-auxpcm-interface = "tertiaryTx"; qcom,msm-cpudai-afe-clk-ver = <2>; }; - dai_sen_auxpcm: qcom,msm-sen-auxpcm { + dai_quat_auxpcm_rx: qcom,msm-quat-auxpcm_rx { compatible = "qcom,msm-auxpcm-dev"; qcom,msm-cpudai-auxpcm-mode = <0>, <0>; qcom,msm-cpudai-auxpcm-sync = <1>, <1>; @@ -499,7 +499,77 @@ qcom,msm-cpudai-auxpcm-slot-mapping = <1>, <1>; qcom,msm-cpudai-auxpcm-data = <0>, <0>; qcom,msm-cpudai-auxpcm-pcm-clk-rate = <2048000>, <2048000>; - qcom,msm-auxpcm-interface = "senary"; + qcom,msm-auxpcm-interface = "quaternaryRx"; + qcom,msm-cpudai-afe-clk-ver = <2>; + }; + + dai_quat_auxpcm_tx: qcom,msm-quat-auxpcm_tx { + compatible = "qcom,msm-auxpcm-dev"; + qcom,msm-cpudai-auxpcm-mode = <0>, <0>; + qcom,msm-cpudai-auxpcm-sync = <1>, <1>; + qcom,msm-cpudai-auxpcm-frame = <5>, <4>; + qcom,msm-cpudai-auxpcm-quant = <2>, <2>; + qcom,msm-cpudai-auxpcm-num-slots = <1>, <1>; + qcom,msm-cpudai-auxpcm-slot-mapping = <1>, <1>; + qcom,msm-cpudai-auxpcm-data = <0>, <0>; + qcom,msm-cpudai-auxpcm-pcm-clk-rate = <2048000>, <2048000>; + qcom,msm-auxpcm-interface = "quaternaryTx"; + qcom,msm-cpudai-afe-clk-ver = <2>; + }; + + dai_quin_auxpcm_rx: qcom,msm-quin-auxpcm_rx { + compatible = "qcom,msm-auxpcm-dev"; + qcom,msm-cpudai-auxpcm-mode = <0>, <0>; + qcom,msm-cpudai-auxpcm-sync = <1>, <1>; + qcom,msm-cpudai-auxpcm-frame = <5>, <4>; + qcom,msm-cpudai-auxpcm-quant = <2>, <2>; + qcom,msm-cpudai-auxpcm-num-slots = <1>, <1>; + qcom,msm-cpudai-auxpcm-slot-mapping = <1>, <1>; + qcom,msm-cpudai-auxpcm-data = <0>, <0>; + qcom,msm-cpudai-auxpcm-pcm-clk-rate = <2048000>, <2048000>; + qcom,msm-auxpcm-interface = "quinaryRx"; + qcom,msm-cpudai-afe-clk-ver = <2>; + }; + + dai_quin_auxpcm_tx: qcom,msm-quin-auxpcm_tx { + compatible = "qcom,msm-auxpcm-dev"; + qcom,msm-cpudai-auxpcm-mode = <0>, <0>; + qcom,msm-cpudai-auxpcm-sync = <1>, <1>; + qcom,msm-cpudai-auxpcm-frame = <5>, <4>; + qcom,msm-cpudai-auxpcm-quant = <2>, <2>; + qcom,msm-cpudai-auxpcm-num-slots = <1>, <1>; + qcom,msm-cpudai-auxpcm-slot-mapping = <1>, <1>; + qcom,msm-cpudai-auxpcm-data = <0>, <0>; + qcom,msm-cpudai-auxpcm-pcm-clk-rate = <2048000>, <2048000>; + qcom,msm-auxpcm-interface = "quinaryTx"; + qcom,msm-cpudai-afe-clk-ver = <2>; + }; + + dai_sen_auxpcm_rx: qcom,msm-sen-auxpcm_rx { + compatible = "qcom,msm-auxpcm-dev"; + qcom,msm-cpudai-auxpcm-mode = <0>, <0>; + qcom,msm-cpudai-auxpcm-sync = <1>, <1>; + qcom,msm-cpudai-auxpcm-frame = <5>, <4>; + qcom,msm-cpudai-auxpcm-quant = <2>, <2>; + qcom,msm-cpudai-auxpcm-num-slots = <1>, <1>; + qcom,msm-cpudai-auxpcm-slot-mapping = <1>, <1>; + qcom,msm-cpudai-auxpcm-data = <0>, <0>; + qcom,msm-cpudai-auxpcm-pcm-clk-rate = <2048000>, <2048000>; + qcom,msm-auxpcm-interface = "senaryRx"; + qcom,msm-cpudai-afe-clk-ver = <2>; + }; + + dai_sen_auxpcm_tx: qcom,msm-sen-auxpcm_tx { + compatible = "qcom,msm-auxpcm-dev"; + qcom,msm-cpudai-auxpcm-mode = <0>, <0>; + qcom,msm-cpudai-auxpcm-sync = <1>, <1>; + qcom,msm-cpudai-auxpcm-frame = <5>, <4>; + qcom,msm-cpudai-auxpcm-quant = <2>, <2>; + qcom,msm-cpudai-auxpcm-num-slots = <1>, <1>; + qcom,msm-cpudai-auxpcm-slot-mapping = <1>, <1>; + qcom,msm-cpudai-auxpcm-data = <0>, <0>; + qcom,msm-cpudai-auxpcm-pcm-clk-rate = <2048000>, <2048000>; + qcom,msm-auxpcm-interface = "senaryTx"; qcom,msm-cpudai-afe-clk-ver = <2>; }; diff --git a/sa8155-audio.dtsi b/sa8155-audio.dtsi index 1b64a603..258c92aa 100644 --- a/sa8155-audio.dtsi +++ b/sa8155-audio.dtsi @@ -452,7 +452,7 @@ }; }; -&dai_pri_auxpcm{ +&dai_pri_auxpcm_rx{ pinctrl-names = "default", "sleep"; pinctrl-0 = <&pri_aux_pcm_clk_active &pri_aux_pcm_sync_active &pri_aux_pcm_din_active &pri_aux_pcm_dout_active>; @@ -512,9 +512,11 @@ <&dai_mi2s2_rx>, <&dai_mi2s2_tx>, <&dai_mi2s3_rx>, <&dai_mi2s3_tx>, <&dai_mi2s4_rx>, <&dai_mi2s4_tx>, - <&dai_pri_auxpcm>, <&dai_pri_auxpcm_tx>, - <&dai_sec_auxpcm>, <&dai_tert_auxpcm>, - <&dai_quat_auxpcm>, <&dai_quin_auxpcm>, + <&dai_pri_auxpcm_rx>, <&dai_pri_auxpcm_tx>, + <&dai_sec_auxpcm_rx>, <&dai_sec_auxpcm_tx>, + <&dai_tert_auxpcm_rx>, <&dai_tert_auxpcm_tx>, + <&dai_quat_auxpcm_rx>, <&dai_quat_auxpcm_tx>, + <&dai_quin_auxpcm_rx>, <&dai_quin_auxpcm_tx>, <&afe_pcm_rx>, <&afe_pcm_tx>, <&afe_proxy_rx>, <&afe_proxy_tx>, <&afe_pcm_rx_1>, <&afe_proxy_tx_1>, @@ -554,6 +556,8 @@ "msm-dai-q6-auxpcm.1","msm-dai-q6-auxpcm.2", "msm-dai-q6-auxpcm.3", "msm-dai-q6-auxpcm.4", "msm-dai-q6-auxpcm.5", "msm-dai-q6-auxpcm.6", + "msm-dai-q6-auxpcm.7", "msm-dai-q6-auxpcm.8", + "msm-dai-q6-auxpcm.9", "msm-dai-q6-auxpcm.10", "msm-dai-q6-dev.224", "msm-dai-q6-dev.225", "msm-dai-q6-dev.241", "msm-dai-q6-dev.240", "msm-dai-q6-dev.226", "msm-dai-q6-dev.242",