All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/5] arm64: dts: arduino-imola: add support for sound
@ 2026-02-23 13:39 Srinivas Kandagatla
  2026-02-23 13:39 ` [PATCH v2 1/5] clk: qcom: fix SM6115 lpasscc register offset Srinivas Kandagatla
                   ` (5 more replies)
  0 siblings, 6 replies; 30+ messages in thread
From: Srinivas Kandagatla @ 2026-02-23 13:39 UTC (permalink / raw)
  To: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd
  Cc: linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini, Srinivas Kandagatla

This patchset adds support for audio on Arduino-Imola platform which is
based on Agatti SoC. As part of series a some of the patches worked by
Alexey are reworked and sent as per previous comments, mainly on the
dt-bindings part.

Other base soc level dtsi change is picked up from 
https://git.codelinaro.org/alexey.klimov/linux_next_tracking/-/commits/rb1_audio_wip_v3?ref_type=HEADS

Along with these changes, add sound nodes for the Imola along with
a fix and defconfig changes.

thanks,
Srini

Changes since v1:
	- updated various register ranges as per documentation.
	- added a fix for sm6115 lpasscc driver.
	- updated commit log
	- fixed various style issues in dt nodes.	

Alexey Klimov (2):
  dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec
  arm64: dts: qcom: agatti: add LPASS devices

Srinivas Kandagatla (3):
  clk: qcom: fix SM6115 lpasscc register offset
  arm64: dts: arduino-imola: add support for sound
  arm64: defconfig: Enable configs for audio drivers on Arduino UnoQ

 .../bindings/mfd/qcom,spmi-pmic.yaml          |   6 +-
 arch/arm64/boot/dts/qcom/agatti.dtsi          | 167 ++++++++++++++++++
 .../boot/dts/qcom/qrb2210-arduino-imola.dts   | 138 +++++++++++++++
 arch/arm64/configs/defconfig                  |   2 +
 drivers/clk/qcom/lpasscc-sm6115.c             |   4 +-
 5 files changed, 314 insertions(+), 3 deletions(-)

-- 
2.47.3


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

* [PATCH v2 1/5] clk: qcom: fix SM6115 lpasscc register offset
  2026-02-23 13:39 [PATCH v2 0/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
@ 2026-02-23 13:39 ` Srinivas Kandagatla
  2026-02-24 12:20   ` Konrad Dybcio
  2026-02-23 13:39 ` [PATCH v2 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec Srinivas Kandagatla
                   ` (4 subsequent siblings)
  5 siblings, 1 reply; 30+ messages in thread
From: Srinivas Kandagatla @ 2026-02-23 13:39 UTC (permalink / raw)
  To: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd
  Cc: linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini, Srinivas Kandagatla, Konrad Dybcio

For some reason we ended with incorrect register offset for soundwire tx
controller reset and the regmap register max was also incorrect it was
0x1000 instead of 0x12000 which is full register range for this IP.

This was somehow compenseated in DT reg property which got it working so
far.

Fix this by correcting the actual offset and max registers as per SoC
documentation.

Fixes: b076b995e225 ("clk: qcom: Add SM6115 LPASSCC")
Cc: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
---
 drivers/clk/qcom/lpasscc-sm6115.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/clk/qcom/lpasscc-sm6115.c b/drivers/clk/qcom/lpasscc-sm6115.c
index ac6d219233b4..47adf4de2cca 100644
--- a/drivers/clk/qcom/lpasscc-sm6115.c
+++ b/drivers/clk/qcom/lpasscc-sm6115.c
@@ -35,7 +35,7 @@ static const struct qcom_cc_desc lpass_audiocc_sm6115_reset_desc = {
 };
 
 static const struct qcom_reset_map lpasscc_sm6115_resets[] = {
-	[LPASS_SWR_TX_CONFIG_CGCR] = { .reg = 0x100, .bit = 1, .udelay = 500 },
+	[LPASS_SWR_TX_CONFIG_CGCR] = { .reg = 0xc100, .bit = 1, .udelay = 500 },
 };
 
 static struct regmap_config lpasscc_sm6115_regmap_config = {
@@ -43,7 +43,7 @@ static struct regmap_config lpasscc_sm6115_regmap_config = {
 	.reg_stride = 4,
 	.val_bits = 32,
 	.name = "lpass-tcsr",
-	.max_register = 0x1000,
+	.max_register = 0x12000,
 };
 
 static const struct qcom_cc_desc lpasscc_sm6115_reset_desc = {
-- 
2.47.3


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

* [PATCH v2 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec
  2026-02-23 13:39 [PATCH v2 0/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
  2026-02-23 13:39 ` [PATCH v2 1/5] clk: qcom: fix SM6115 lpasscc register offset Srinivas Kandagatla
@ 2026-02-23 13:39 ` Srinivas Kandagatla
  2026-02-23 16:56   ` Rob Herring
  2026-02-23 13:39 ` [PATCH v2 3/5] arm64: dts: qcom: agatti: add LPASS devices Srinivas Kandagatla
                   ` (3 subsequent siblings)
  5 siblings, 1 reply; 30+ messages in thread
From: Srinivas Kandagatla @ 2026-02-23 13:39 UTC (permalink / raw)
  To: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd
  Cc: linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini, Srinivas Kandagatla, Krzysztof Kozlowski

From: Alexey Klimov <alexey.klimov@linaro.org>

Qualcomm Agatti SoC has PM4125 PMIC, which includes audio codec.
Audio codec has TX and RX soundwire slave devices to connect to on-chip
soundwire master.

Add missing qcom,pm4125-codec compatible to pattern of audio-codec node
properties in mfd qcom,spmi-pmic schema to complete the audio codec support.

Signed-off-by: Alexey Klimov <alexey.klimov@linaro.org>
[Srini: reworked the patch]
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
---
 Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
index e5931d18d998..f58a85562c26 100644
--- a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
+++ b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
@@ -145,7 +145,11 @@ patternProperties:
 
   "^audio-codec@[0-9a-f]+$":
     type: object
-    $ref: /schemas/sound/qcom,pm8916-wcd-analog-codec.yaml#
+    oneOf:
+      - $ref: /schemas/sound/qcom,pm8916-wcd-analog-codec.yaml#
+      - properties:
+          compatible:
+            const: qcom,pm4125-codec
 
   "^battery@[0-9a-f]+$":
     type: object
-- 
2.47.3


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

* [PATCH v2 3/5] arm64: dts: qcom: agatti: add LPASS devices
  2026-02-23 13:39 [PATCH v2 0/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
  2026-02-23 13:39 ` [PATCH v2 1/5] clk: qcom: fix SM6115 lpasscc register offset Srinivas Kandagatla
  2026-02-23 13:39 ` [PATCH v2 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec Srinivas Kandagatla
@ 2026-02-23 13:39 ` Srinivas Kandagatla
  2026-02-24  2:58   ` Dmitry Baryshkov
                     ` (2 more replies)
  2026-02-23 13:39 ` [PATCH v2 4/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
                   ` (2 subsequent siblings)
  5 siblings, 3 replies; 30+ messages in thread
From: Srinivas Kandagatla @ 2026-02-23 13:39 UTC (permalink / raw)
  To: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd
  Cc: linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini, Srinivas Kandagatla

From: Alexey Klimov <alexey.klimov@linaro.org>

The rxmacro, txmacro, vamacro, soundwire nodes, lpass clock
controllers are required to support audio playback and
audio capture on sm6115 and its derivatives.

Signed-off-by: Alexey Klimov <alexey.klimov@linaro.org>
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
---
 arch/arm64/boot/dts/qcom/agatti.dtsi | 167 +++++++++++++++++++++++++++
 1 file changed, 167 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/agatti.dtsi b/arch/arm64/boot/dts/qcom/agatti.dtsi
index 76b93b7bd50f..e59a1a87ee0a 100644
--- a/arch/arm64/boot/dts/qcom/agatti.dtsi
+++ b/arch/arm64/boot/dts/qcom/agatti.dtsi
@@ -758,6 +758,42 @@ data-pins {
 					drive-strength = <8>;
 				};
 			};
+
+			lpass_tx_swr_active: lpass-tx-swr-active-state {
+				clk-pins {
+					pins = "gpio0";
+					function = "swr_tx_clk";
+					drive-strength = <10>;
+					slew-rate = <3>;
+					bias-disable;
+				};
+
+				data-pins {
+					pins = "gpio1", "gpio2";
+					function = "swr_tx_data";
+					drive-strength = <10>;
+					slew-rate = <3>;
+					bias-bus-hold;
+				};
+			};
+
+			lpass_rx_swr_active: lpass-rx-swr-active-state {
+				clk-pins {
+					pins = "gpio3";
+					function = "swr_rx_clk";
+					drive-strength = <10>;
+					slew-rate = <3>;
+					bias-disable;
+				};
+
+				data-pins {
+					pins = "gpio4", "gpio5";
+					function = "swr_rx_data";
+					drive-strength = <10>;
+					slew-rate = <3>;
+					bias-bus-hold;
+				};
+			};
 		};
 
 		gcc: clock-controller@1400000 {
@@ -2188,6 +2224,137 @@ glink-edge {
 			};
 		};
 
+		rxmacro: codec@a600000 {
+			compatible = "qcom,sm6115-lpass-rx-macro";
+			reg = <0x0 0xa600000 0x0 0x1000>;
+
+			clocks = <&q6afecc LPASS_CLK_ID_RX_CORE_MCLK
+				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&q6afecc LPASS_CLK_ID_RX_CORE_NPL_MCLK
+				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&q6afecc LPASS_HW_DCODEC_VOTE
+				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&vamacro>;
+			clock-names = "mclk",
+				      "npl",
+				      "dcodec",
+				      "fsgen";
+			#clock-cells = <0>;
+			clock-output-names = "mclk";
+			#sound-dai-cells = <1>;
+		};
+
+		swr1: soundwire@a610000 {
+			compatible = "qcom,soundwire-v1.6.0";
+			reg = <0x0 0x0a610000 0x0 0x10000>;
+			interrupts = <GIC_SPI 297 IRQ_TYPE_LEVEL_HIGH>;
+
+			clocks = <&rxmacro>;
+			clock-names = "iface";
+
+			resets = <&lpass_audiocc 0>;
+			reset-names = "swr_audio_cgcr";
+
+			label = "RX";
+			qcom,din-ports = <0>;
+			qcom,dout-ports = <5>;
+
+			qcom,ports-sinterval-low =	/bits/ 8 <0x03 0x1f 0x1f 0x07 0x00>;
+			qcom,ports-offset1 =		/bits/ 8 <0x00 0x00 0x0b 0x01 0x00>;
+			qcom,ports-offset2 =		/bits/ 8 <0x00 0x00 0x0b 0x00 0x00>;
+			qcom,ports-hstart =		/bits/ 8 <0xff 0x03 0xff 0xff 0xff>;
+			qcom,ports-hstop =		/bits/ 8 <0xff 0x06 0xff 0xff 0xff>;
+			qcom,ports-word-length =	/bits/ 8 <0x01 0x07 0x04 0xff 0xff>;
+			qcom,ports-block-pack-mode =	/bits/ 8 <0xff 0x00 0x01 0xff 0xff>;
+			qcom,ports-block-group-count =	/bits/ 8 <0xff 0xff 0xff 0xff 0x00>;
+			qcom,ports-lane-control =	/bits/ 8 <0x01 0x00 0x00 0x00 0x00>;
+
+			#sound-dai-cells = <1>;
+			#address-cells = <2>;
+			#size-cells = <0>;
+		};
+
+
+		txmacro: codec@a620000 {
+			compatible = "qcom,sm6115-lpass-tx-macro";
+			reg = <0x0 0x0a620000 0x0 0x1000>;
+
+			clocks = <&q6afecc LPASS_CLK_ID_TX_CORE_MCLK
+				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&q6afecc LPASS_CLK_ID_TX_CORE_NPL_MCLK
+				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&q6afecc LPASS_HW_DCODEC_VOTE
+				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&vamacro>;
+			clock-names = "mclk",
+				      "npl",
+				      "dcodec",
+				      "fsgen";
+			#clock-cells = <0>;
+			clock-output-names = "mclk";
+			#sound-dai-cells = <1>;
+		};
+
+		lpass_audiocc: clock-controller@a6a9000 {
+			compatible = "qcom,sm6115-lpassaudiocc";
+			reg = <0x0 0x0a6a9000 0x0 0x1000>;
+			#reset-cells = <1>;
+		};
+
+		vamacro: codec@a730000 {
+			compatible = "qcom,sm6115-lpass-va-macro";
+			reg = <0x0 0x0a730000 0x0 0x1000>;
+
+			clocks = <&q6afecc LPASS_CLK_ID_TX_CORE_MCLK
+				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&q6afecc LPASS_HW_DCODEC_VOTE
+				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&q6afecc LPASS_CLK_ID_TX_CORE_NPL_MCLK
+				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>;
+			clock-names = "mclk",
+				      "dcodec",
+				      "npl";
+			#clock-cells = <0>;
+			clock-output-names = "fsgen";
+			#sound-dai-cells = <1>;
+		};
+
+		swr0: soundwire@a740000 {
+			compatible = "qcom,soundwire-v1.6.0";
+			reg = <0x0 0x0a740000 0x0 0x10000>;
+			interrupts = <GIC_SPI 296 IRQ_TYPE_LEVEL_HIGH>,
+				     <GIC_SPI 79 IRQ_TYPE_LEVEL_HIGH>;
+			clocks = <&txmacro>;
+			clock-names = "iface";
+
+			resets = <&lpasscc 0>;
+			reset-names = "swr_audio_cgcr";
+
+			label = "VA_TX";
+			qcom,din-ports = <3>;
+			qcom,dout-ports = <0>;
+
+			qcom,ports-sinterval-low =	/bits/ 8 <0x03 0x03 0x03>;
+			qcom,ports-offset1 =		/bits/ 8 <0x01 0x02 0x01>;
+			qcom,ports-offset2 =		/bits/ 8 <0x00 0x00 0x00>;
+			qcom,ports-hstart =		/bits/ 8 <0xff 0xff 0xff>;
+			qcom,ports-hstop =		/bits/ 8 <0xff 0xff 0xff>;
+			qcom,ports-word-length =	/bits/ 8 <0xff 0xff 0xff>;
+			qcom,ports-block-pack-mode =	/bits/ 8 <0xff 0xff 0xff>;
+			qcom,ports-block-group-count =	/bits/ 8 <0xff 0xff 0xff>;
+			qcom,ports-lane-control =	/bits/ 8 <0x00 0x00 0x00>;
+
+			#sound-dai-cells = <1>;
+			#address-cells = <2>;
+			#size-cells = <0>;
+		};
+
+		lpasscc: clock-controller@a7ec000 {
+			compatible = "qcom,sm6115-lpasscc";
+			reg = <0x0 0x0a7e0000 0x0 0x12000>;
+			#reset-cells = <1>;
+		};
+
 		remoteproc_adsp: remoteproc@ab00000 {
 			compatible = "qcom,qcm2290-adsp-pas", "qcom,sm6115-adsp-pas";
 			reg = <0x0 0x0ab00000 0x0 0x100>;
-- 
2.47.3


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

* [PATCH v2 4/5] arm64: dts: arduino-imola: add support for sound
  2026-02-23 13:39 [PATCH v2 0/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
                   ` (2 preceding siblings ...)
  2026-02-23 13:39 ` [PATCH v2 3/5] arm64: dts: qcom: agatti: add LPASS devices Srinivas Kandagatla
@ 2026-02-23 13:39 ` Srinivas Kandagatla
  2026-02-24 11:48   ` Konrad Dybcio
  2026-02-23 13:39 ` [PATCH v2 5/5] arm64: defconfig: Enable configs for audio drivers on Arduino UnoQ Srinivas Kandagatla
  2026-09-22 22:11 ` [PATCH v3 0/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
  5 siblings, 1 reply; 30+ messages in thread
From: Srinivas Kandagatla @ 2026-02-23 13:39 UTC (permalink / raw)
  To: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd
  Cc: linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini, Srinivas Kandagatla

Add support for sound on Arduino UNO Q board, which includes
- Headset playback and record.
- Lineout

Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
---
 .../boot/dts/qcom/qrb2210-arduino-imola.dts   | 138 ++++++++++++++++++
 1 file changed, 138 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/qrb2210-arduino-imola.dts b/arch/arm64/boot/dts/qcom/qrb2210-arduino-imola.dts
index 197ab6eb1666..53745684ead4 100644
--- a/arch/arm64/boot/dts/qcom/qrb2210-arduino-imola.dts
+++ b/arch/arm64/boot/dts/qcom/qrb2210-arduino-imola.dts
@@ -109,6 +109,101 @@ multi-led {
 		leds = <&ledr>, <&ledg>, <&ledb>;
 	};
 
+	sound {
+		compatible = "qcom,qrb2210-sndcard";
+		model = "Arduino-Imola-HPH-LOUT";
+		audio-routing =	"IN1_HPHL", "HPHL_OUT",
+				"IN2_HPHR", "HPHR_OUT",
+				"AMIC2", "MIC BIAS2";
+
+		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>;
+			};
+		};
+
+		hph-playback-dai-link {
+			link-name = "Headphones Playback";
+
+			cpu {
+				sound-dai = <&q6afedai RX_CODEC_DMA_RX_0>;
+			};
+
+			platform {
+				sound-dai = <&q6routing>;
+			};
+
+			codec {
+				sound-dai = <&pmic4125_codec 0>, <&swr1 0>, <&rxmacro 0>;
+			};
+		};
+
+		lo-playback-dai-link {
+			link-name = "LineOut Playback";
+
+			cpu {
+				sound-dai = <&q6afedai RX_CODEC_DMA_RX_0>;
+			};
+
+			platform {
+				sound-dai = <&q6routing>;
+			};
+
+			codec {
+				sound-dai = <&pmic4125_codec 0>, <&swr1 0>, <&rxmacro 0>;
+			};
+		};
+
+		ear-playback-dai-link {
+			link-name = "EarOut Playback";
+
+			cpu {
+				sound-dai = <&q6afedai RX_CODEC_DMA_RX_0>;
+			};
+
+			platform {
+				sound-dai = <&q6routing>;
+			};
+
+			codec {
+				sound-dai = <&pmic4125_codec 0>, <&swr1 0>, <&rxmacro 0>;
+			};
+		};
+
+		hph-capture-dai-link {
+			link-name = "Headphones Capture";
+			cpu {
+				sound-dai = <&q6afedai TX_CODEC_DMA_TX_3>;
+			};
+
+			platform {
+				sound-dai = <&q6routing>;
+			};
+
+			codec {
+				sound-dai = <&pmic4125_codec 1>, <&swr0 0>, <&txmacro 0>;
+			};
+		};
+	};
+
 	/* PM4125 charger out, supplied by VBAT */
 	vph_pwr: regulator-vph-pwr {
 		compatible = "regulator-fixed";
@@ -333,6 +428,49 @@ spidev@0 {
 	};
 };
 
+&spmi_bus {
+	pmic@0 {
+		pmic4125_codec: audio-codec@f000{
+			compatible = "qcom,pm4125-codec";
+			reg =<0xf000>;
+			vdd-io-supply = <&pm4125_l15>;
+			vdd-cp-supply = <&pm4125_s4>;
+			vdd-pa-vpos-supply = <&pm4125_s4>;
+
+			vdd-mic-bias-supply = <&pm4125_l22>;
+			qcom,micbias1-microvolt = <1800000>;
+			qcom,micbias2-microvolt = <1800000>;
+			qcom,micbias3-microvolt = <1800000>;
+
+			qcom,rx-device = <&pm4125_rx>;
+			qcom,tx-device = <&pm4125_tx>;
+			#sound-dai-cells = <1>;
+		};
+	};
+};
+
+&swr0 {
+	pinctrl-0 = <&lpass_tx_swr_active>;
+	pinctrl-names = "default";
+
+	pm4125_tx: codec@0,3 {
+		compatible = "sdw20217010c00";
+		reg = <0 3>;
+		qcom,tx-port-mapping = <1 1 2 3>;
+	};
+};
+
+&swr1 {
+	pinctrl-0 = <&lpass_rx_swr_active>;
+	pinctrl-names = "default";
+
+	pm4125_rx: codec@0,4 {
+		compatible = "sdw20217010c00";
+		reg = <0 4>;
+		qcom,rx-port-mapping = <1 2 3 4 5>;
+	};
+};
+
 &tlmm {
 	spidev_cs: spidev-cs-state {
 		pins = "gpio17";
-- 
2.47.3


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

* [PATCH v2 5/5] arm64: defconfig: Enable configs for audio drivers on Arduino UnoQ
  2026-02-23 13:39 [PATCH v2 0/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
                   ` (3 preceding siblings ...)
  2026-02-23 13:39 ` [PATCH v2 4/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
@ 2026-02-23 13:39 ` Srinivas Kandagatla
  2026-02-24  2:57   ` Dmitry Baryshkov
  2026-09-22 22:11 ` [PATCH v3 0/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
  5 siblings, 1 reply; 30+ messages in thread
From: Srinivas Kandagatla @ 2026-02-23 13:39 UTC (permalink / raw)
  To: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd
  Cc: linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini, Srinivas Kandagatla

Enable reset controller and pm4125 audio codec driver that are required
to enable audio support on Arduino UnoQ board.

Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
---
 arch/arm64/configs/defconfig | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arm64/configs/defconfig b/arch/arm64/configs/defconfig
index b67d5b1fc45b..6db35c1605a0 100644
--- a/arch/arm64/configs/defconfig
+++ b/arch/arm64/configs/defconfig
@@ -1146,6 +1146,7 @@ CONFIG_SND_SOC_ES8328_I2C=m
 CONFIG_SND_SOC_GTM601=m
 CONFIG_SND_SOC_MSM8916_WCD_ANALOG=m
 CONFIG_SND_SOC_MSM8916_WCD_DIGITAL=m
+CONFIG_SND_SOC_PM4125_SDW=m
 CONFIG_SND_SOC_PCM3168A_I2C=m
 CONFIG_SND_SOC_RK3308=m
 CONFIG_SND_SOC_RK817=m
@@ -1550,6 +1551,7 @@ CONFIG_SM_GPUCC_8350=m
 CONFIG_SM_GPUCC_8450=m
 CONFIG_SM_GPUCC_8550=m
 CONFIG_SM_GPUCC_8650=m
+CONFIG_SM_LPASSCC_6115=m
 CONFIG_SM_TCSRCC_8550=y
 CONFIG_SM_TCSRCC_8650=y
 CONFIG_SM_TCSRCC_8750=m
-- 
2.47.3


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

* Re: [PATCH v2 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec
  2026-02-23 13:39 ` [PATCH v2 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec Srinivas Kandagatla
@ 2026-02-23 16:56   ` Rob Herring
  2026-02-23 18:14     ` Srinivas Kandagatla
  0 siblings, 1 reply; 30+ messages in thread
From: Rob Herring @ 2026-02-23 16:56 UTC (permalink / raw)
  To: Srinivas Kandagatla
  Cc: lee, krzk+dt, conor+dt, andersson, konradybcio, sboyd,
	linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini, Krzysztof Kozlowski

On Mon, Feb 23, 2026 at 01:39:47PM +0000, Srinivas Kandagatla wrote:
> From: Alexey Klimov <alexey.klimov@linaro.org>
> 
> Qualcomm Agatti SoC has PM4125 PMIC, which includes audio codec.
> Audio codec has TX and RX soundwire slave devices to connect to on-chip
> soundwire master.
> 
> Add missing qcom,pm4125-codec compatible to pattern of audio-codec node
> properties in mfd qcom,spmi-pmic schema to complete the audio codec support.
> 
> Signed-off-by: Alexey Klimov <alexey.klimov@linaro.org>
> [Srini: reworked the patch]
> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
> ---
>  Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml | 6 +++++-
>  1 file changed, 5 insertions(+), 1 deletion(-)
> 
> diff --git a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
> index e5931d18d998..f58a85562c26 100644
> --- a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
> +++ b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
> @@ -145,7 +145,11 @@ patternProperties:
>  
>    "^audio-codec@[0-9a-f]+$":
>      type: object
> -    $ref: /schemas/sound/qcom,pm8916-wcd-analog-codec.yaml#
> +    oneOf:
> +      - $ref: /schemas/sound/qcom,pm8916-wcd-analog-codec.yaml#
> +      - properties:
> +          compatible:
> +            const: qcom,pm4125-codec

Don't mix 2 styles. Just do:

type: object
properties:
  compatible:
    contains:
      enum:
        - qcom,pm4125-codec
        - qcom,pm8916-wcd-analog-codec

required:
  - compatible

>  
>    "^battery@[0-9a-f]+$":
>      type: object
> -- 
> 2.47.3
> 

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

* Re: [PATCH v2 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec
  2026-02-23 16:56   ` Rob Herring
@ 2026-02-23 18:14     ` Srinivas Kandagatla
  0 siblings, 0 replies; 30+ messages in thread
From: Srinivas Kandagatla @ 2026-02-23 18:14 UTC (permalink / raw)
  To: Rob Herring
  Cc: lee, krzk+dt, conor+dt, andersson, konradybcio, sboyd,
	linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini, Krzysztof Kozlowski

On 2/23/26 4:56 PM, Rob Herring wrote:
> On Mon, Feb 23, 2026 at 01:39:47PM +0000, Srinivas Kandagatla wrote:
>> From: Alexey Klimov <alexey.klimov@linaro.org>
>>
>> Qualcomm Agatti SoC has PM4125 PMIC, which includes audio codec.
>> Audio codec has TX and RX soundwire slave devices to connect to on-chip
>> soundwire master.
>>
>> Add missing qcom,pm4125-codec compatible to pattern of audio-codec node
>> properties in mfd qcom,spmi-pmic schema to complete the audio codec support.
>>
>> Signed-off-by: Alexey Klimov <alexey.klimov@linaro.org>
>> [Srini: reworked the patch]
>> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
>> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
>> ---
>>  Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml | 6 +++++-
>>  1 file changed, 5 insertions(+), 1 deletion(-)
>>
>> diff --git a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
>> index e5931d18d998..f58a85562c26 100644
>> --- a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
>> +++ b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
>> @@ -145,7 +145,11 @@ patternProperties:
>>  
>>    "^audio-codec@[0-9a-f]+$":
>>      type: object
>> -    $ref: /schemas/sound/qcom,pm8916-wcd-analog-codec.yaml#
>> +    oneOf:
>> +      - $ref: /schemas/sound/qcom,pm8916-wcd-analog-codec.yaml#
>> +      - properties:
>> +          compatible:
>> +            const: qcom,pm4125-codec
> 
> Don't mix 2 styles. Just do:
> 
> type: object
> properties:
>   compatible:
>     contains:
>       enum:
>         - qcom,pm4125-codec
>         - qcom,pm8916-wcd-analog-codec

Thanks Rob, will do that in v3.

--srini
> 
> required:
>   - compatible
> 
>>  
>>    "^battery@[0-9a-f]+$":
>>      type: object
>> -- 
>> 2.47.3
>>


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

* Re: [PATCH v2 5/5] arm64: defconfig: Enable configs for audio drivers on Arduino UnoQ
  2026-02-23 13:39 ` [PATCH v2 5/5] arm64: defconfig: Enable configs for audio drivers on Arduino UnoQ Srinivas Kandagatla
@ 2026-02-24  2:57   ` Dmitry Baryshkov
  0 siblings, 0 replies; 30+ messages in thread
From: Dmitry Baryshkov @ 2026-02-24  2:57 UTC (permalink / raw)
  To: Srinivas Kandagatla
  Cc: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd,
	linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini

On Mon, Feb 23, 2026 at 01:39:50PM +0000, Srinivas Kandagatla wrote:
> Enable reset controller and pm4125 audio codec driver that are required
> to enable audio support on Arduino UnoQ board.
> 
> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
> ---
>  arch/arm64/configs/defconfig | 2 ++
>  1 file changed, 2 insertions(+)
> 

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>


-- 
With best wishes
Dmitry

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

* Re: [PATCH v2 3/5] arm64: dts: qcom: agatti: add LPASS devices
  2026-02-23 13:39 ` [PATCH v2 3/5] arm64: dts: qcom: agatti: add LPASS devices Srinivas Kandagatla
@ 2026-02-24  2:58   ` Dmitry Baryshkov
  2026-02-24 12:24   ` Konrad Dybcio
  2026-02-24 12:28   ` Konrad Dybcio
  2 siblings, 0 replies; 30+ messages in thread
From: Dmitry Baryshkov @ 2026-02-24  2:58 UTC (permalink / raw)
  To: Srinivas Kandagatla
  Cc: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd,
	linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini

On Mon, Feb 23, 2026 at 01:39:48PM +0000, Srinivas Kandagatla wrote:
> From: Alexey Klimov <alexey.klimov@linaro.org>
> 
> The rxmacro, txmacro, vamacro, soundwire nodes, lpass clock
> controllers are required to support audio playback and
> audio capture on sm6115 and its derivatives.
> 
> Signed-off-by: Alexey Klimov <alexey.klimov@linaro.org>
> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
> ---
>  arch/arm64/boot/dts/qcom/agatti.dtsi | 167 +++++++++++++++++++++++++++
>  1 file changed, 167 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/qcom/agatti.dtsi b/arch/arm64/boot/dts/qcom/agatti.dtsi
> index 76b93b7bd50f..e59a1a87ee0a 100644
> --- a/arch/arm64/boot/dts/qcom/agatti.dtsi
> +++ b/arch/arm64/boot/dts/qcom/agatti.dtsi
> @@ -758,6 +758,42 @@ data-pins {
>  					drive-strength = <8>;
>  				};
>  			};
> +
> +			lpass_tx_swr_active: lpass-tx-swr-active-state {
> +				clk-pins {
> +					pins = "gpio0";
> +					function = "swr_tx_clk";
> +					drive-strength = <10>;
> +					slew-rate = <3>;
> +					bias-disable;
> +				};
> +
> +				data-pins {
> +					pins = "gpio1", "gpio2";
> +					function = "swr_tx_data";
> +					drive-strength = <10>;
> +					slew-rate = <3>;
> +					bias-bus-hold;
> +				};
> +			};
> +
> +			lpass_rx_swr_active: lpass-rx-swr-active-state {
> +				clk-pins {
> +					pins = "gpio3";
> +					function = "swr_rx_clk";
> +					drive-strength = <10>;
> +					slew-rate = <3>;
> +					bias-disable;
> +				};
> +
> +				data-pins {
> +					pins = "gpio4", "gpio5";
> +					function = "swr_rx_data";
> +					drive-strength = <10>;
> +					slew-rate = <3>;
> +					bias-bus-hold;
> +				};
> +			};
>  		};
>  
>  		gcc: clock-controller@1400000 {
> @@ -2188,6 +2224,137 @@ glink-edge {
>  			};
>  		};
>  
> +		rxmacro: codec@a600000 {
> +			compatible = "qcom,sm6115-lpass-rx-macro";
> +			reg = <0x0 0xa600000 0x0 0x1000>;
> +
> +			clocks = <&q6afecc LPASS_CLK_ID_RX_CORE_MCLK
> +				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
> +				 <&q6afecc LPASS_CLK_ID_RX_CORE_NPL_MCLK
> +				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
> +				 <&q6afecc LPASS_HW_DCODEC_VOTE
> +				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
> +				 <&vamacro>;
> +			clock-names = "mclk",
> +				      "npl",
> +				      "dcodec",
> +				      "fsgen";
> +			#clock-cells = <0>;
> +			clock-output-names = "mclk";
> +			#sound-dai-cells = <1>;
> +		};
> +
> +		swr1: soundwire@a610000 {
> +			compatible = "qcom,soundwire-v1.6.0";
> +			reg = <0x0 0x0a610000 0x0 0x10000>;
> +			interrupts = <GIC_SPI 297 IRQ_TYPE_LEVEL_HIGH>;
> +
> +			clocks = <&rxmacro>;
> +			clock-names = "iface";
> +
> +			resets = <&lpass_audiocc 0>;
> +			reset-names = "swr_audio_cgcr";
> +
> +			label = "RX";
> +			qcom,din-ports = <0>;
> +			qcom,dout-ports = <5>;
> +
> +			qcom,ports-sinterval-low =	/bits/ 8 <0x03 0x1f 0x1f 0x07 0x00>;
> +			qcom,ports-offset1 =		/bits/ 8 <0x00 0x00 0x0b 0x01 0x00>;
> +			qcom,ports-offset2 =		/bits/ 8 <0x00 0x00 0x0b 0x00 0x00>;
> +			qcom,ports-hstart =		/bits/ 8 <0xff 0x03 0xff 0xff 0xff>;
> +			qcom,ports-hstop =		/bits/ 8 <0xff 0x06 0xff 0xff 0xff>;
> +			qcom,ports-word-length =	/bits/ 8 <0x01 0x07 0x04 0xff 0xff>;
> +			qcom,ports-block-pack-mode =	/bits/ 8 <0xff 0x00 0x01 0xff 0xff>;
> +			qcom,ports-block-group-count =	/bits/ 8 <0xff 0xff 0xff 0xff 0x00>;
> +			qcom,ports-lane-control =	/bits/ 8 <0x01 0x00 0x00 0x00 0x00>;
> +
> +			#sound-dai-cells = <1>;
> +			#address-cells = <2>;
> +			#size-cells = <0>;
> +		};
> +
> +

Double empty line

> +		txmacro: codec@a620000 {
> +			compatible = "qcom,sm6115-lpass-tx-macro";
> +			reg = <0x0 0x0a620000 0x0 0x1000>;
> +
> +			clocks = <&q6afecc LPASS_CLK_ID_TX_CORE_MCLK
> +				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,

Please adjust indentation (the most logical would be to put the whole
clock definition to a single line.

> +				 <&q6afecc LPASS_CLK_ID_TX_CORE_NPL_MCLK
> +				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
> +				 <&q6afecc LPASS_HW_DCODEC_VOTE
> +				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
> +				 <&vamacro>;
> +			clock-names = "mclk",
> +				      "npl",
> +				      "dcodec",
> +				      "fsgen";
> +			#clock-cells = <0>;
> +			clock-output-names = "mclk";
> +			#sound-dai-cells = <1>;
> +		};
> +
> +		lpass_audiocc: clock-controller@a6a9000 {
> +			compatible = "qcom,sm6115-lpassaudiocc";
> +			reg = <0x0 0x0a6a9000 0x0 0x1000>;
> +			#reset-cells = <1>;
> +		};
> +
> +		vamacro: codec@a730000 {
> +			compatible = "qcom,sm6115-lpass-va-macro";
> +			reg = <0x0 0x0a730000 0x0 0x1000>;
> +
> +			clocks = <&q6afecc LPASS_CLK_ID_TX_CORE_MCLK
> +				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,

The same

> +				 <&q6afecc LPASS_HW_DCODEC_VOTE
> +				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
> +				 <&q6afecc LPASS_CLK_ID_TX_CORE_NPL_MCLK
> +				 LPASS_CLK_ATTRIBUTE_COUPLE_NO>;
> +			clock-names = "mclk",
> +				      "dcodec",
> +				      "npl";
> +			#clock-cells = <0>;
> +			clock-output-names = "fsgen";
> +			#sound-dai-cells = <1>;
> +		};
> +
> +		swr0: soundwire@a740000 {
> +			compatible = "qcom,soundwire-v1.6.0";
> +			reg = <0x0 0x0a740000 0x0 0x10000>;
> +			interrupts = <GIC_SPI 296 IRQ_TYPE_LEVEL_HIGH>,
> +				     <GIC_SPI 79 IRQ_TYPE_LEVEL_HIGH>;
> +			clocks = <&txmacro>;
> +			clock-names = "iface";
> +
> +			resets = <&lpasscc 0>;
> +			reset-names = "swr_audio_cgcr";
> +
> +			label = "VA_TX";
> +			qcom,din-ports = <3>;
> +			qcom,dout-ports = <0>;
> +
> +			qcom,ports-sinterval-low =	/bits/ 8 <0x03 0x03 0x03>;
> +			qcom,ports-offset1 =		/bits/ 8 <0x01 0x02 0x01>;
> +			qcom,ports-offset2 =		/bits/ 8 <0x00 0x00 0x00>;
> +			qcom,ports-hstart =		/bits/ 8 <0xff 0xff 0xff>;
> +			qcom,ports-hstop =		/bits/ 8 <0xff 0xff 0xff>;
> +			qcom,ports-word-length =	/bits/ 8 <0xff 0xff 0xff>;
> +			qcom,ports-block-pack-mode =	/bits/ 8 <0xff 0xff 0xff>;
> +			qcom,ports-block-group-count =	/bits/ 8 <0xff 0xff 0xff>;
> +			qcom,ports-lane-control =	/bits/ 8 <0x00 0x00 0x00>;
> +
> +			#sound-dai-cells = <1>;
> +			#address-cells = <2>;
> +			#size-cells = <0>;
> +		};
> +
> +		lpasscc: clock-controller@a7ec000 {
> +			compatible = "qcom,sm6115-lpasscc";
> +			reg = <0x0 0x0a7e0000 0x0 0x12000>;
> +			#reset-cells = <1>;
> +		};
> +
>  		remoteproc_adsp: remoteproc@ab00000 {
>  			compatible = "qcom,qcm2290-adsp-pas", "qcom,sm6115-adsp-pas";
>  			reg = <0x0 0x0ab00000 0x0 0x100>;
> -- 
> 2.47.3
> 

-- 
With best wishes
Dmitry

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

* Re: [PATCH v2 4/5] arm64: dts: arduino-imola: add support for sound
  2026-02-23 13:39 ` [PATCH v2 4/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
@ 2026-02-24 11:48   ` Konrad Dybcio
  0 siblings, 0 replies; 30+ messages in thread
From: Konrad Dybcio @ 2026-02-24 11:48 UTC (permalink / raw)
  To: Srinivas Kandagatla, lee, robh, krzk+dt, conor+dt, andersson,
	konradybcio, sboyd
  Cc: linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini

On 2/23/26 2:39 PM, Srinivas Kandagatla wrote:
> Add support for sound on Arduino UNO Q board, which includes
> - Headset playback and record.
> - Lineout
> 
> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
> ---

Please address the feedback you received on v1

Konrad

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

* Re: [PATCH v2 1/5] clk: qcom: fix SM6115 lpasscc register offset
  2026-02-23 13:39 ` [PATCH v2 1/5] clk: qcom: fix SM6115 lpasscc register offset Srinivas Kandagatla
@ 2026-02-24 12:20   ` Konrad Dybcio
  0 siblings, 0 replies; 30+ messages in thread
From: Konrad Dybcio @ 2026-02-24 12:20 UTC (permalink / raw)
  To: Srinivas Kandagatla, lee, robh, krzk+dt, conor+dt, andersson,
	konradybcio, sboyd
  Cc: linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini

On 2/23/26 2:39 PM, Srinivas Kandagatla wrote:
> For some reason we ended with incorrect register offset for soundwire tx
> controller reset and the regmap register max was also incorrect it was
> 0x1000 instead of 0x12000 which is full register range for this IP.
> 
> This was somehow compenseated in DT reg property which got it working so
> far.
> 
> Fix this by correcting the actual offset and max registers as per SoC
> documentation.
> 
> Fixes: b076b995e225 ("clk: qcom: Add SM6115 LPASSCC")
> Cc: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
> ---
>  drivers/clk/qcom/lpasscc-sm6115.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/clk/qcom/lpasscc-sm6115.c b/drivers/clk/qcom/lpasscc-sm6115.c
> index ac6d219233b4..47adf4de2cca 100644
> --- a/drivers/clk/qcom/lpasscc-sm6115.c
> +++ b/drivers/clk/qcom/lpasscc-sm6115.c
> @@ -35,7 +35,7 @@ static const struct qcom_cc_desc lpass_audiocc_sm6115_reset_desc = {
>  };
>  
>  static const struct qcom_reset_map lpasscc_sm6115_resets[] = {
> -	[LPASS_SWR_TX_CONFIG_CGCR] = { .reg = 0x100, .bit = 1, .udelay = 500 },
> +	[LPASS_SWR_TX_CONFIG_CGCR] = { .reg = 0xc100, .bit = 1, .udelay = 500 },

So after taking a deeper dive, we currently define CGCR "resets" with bit(1)

The CGCRs ("Clock Gating Control Registers") have:

BIT(1) HW_CTL
BIT(0) CLK_ENABLE

so by ""asserting"" the resets, we really put the *clocks* in HW CTL mode
(that's why drivers/soundwire/qcom.c only ever calls reset_control_reset()
and during "configure"-type sequences)

I think for not making a mess out of backwards compatiblity, we could stay
with this model, but we should def write it down somewhere..

I don't know if we ever need to manually assert CLK_ENABLE from Linux.


Now, interestingly, msm-4.19 techpack/audio has this hunk:

/* SW workaround to gate hw_ctl for SWR version >=1.6 */
if (swrm->version >= SWRM_VERSION_1_6) {
        if (swrm->swrm_hctl_reg) {
                temp = ioread32(swrm->swrm_hctl_reg);
                temp &= 0xFFFFFFFD;
                iowrite32(temp, swrm->swrm_hctl_reg);
                usleep_range(500, 505);
                temp = ioread32(swrm->swrm_hctl_reg);
                dev_dbg(swrm->dev, "%s: hctl_reg val: 0x%x\n",
                        __func__, temp);
        }
}

which clears that hw_ctl bit

Konrad

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

* Re: [PATCH v2 3/5] arm64: dts: qcom: agatti: add LPASS devices
  2026-02-23 13:39 ` [PATCH v2 3/5] arm64: dts: qcom: agatti: add LPASS devices Srinivas Kandagatla
  2026-02-24  2:58   ` Dmitry Baryshkov
@ 2026-02-24 12:24   ` Konrad Dybcio
  2026-02-24 12:28   ` Konrad Dybcio
  2 siblings, 0 replies; 30+ messages in thread
From: Konrad Dybcio @ 2026-02-24 12:24 UTC (permalink / raw)
  To: Srinivas Kandagatla, lee, robh, krzk+dt, conor+dt, andersson,
	konradybcio, sboyd
  Cc: linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini

On 2/23/26 2:39 PM, Srinivas Kandagatla wrote:
> From: Alexey Klimov <alexey.klimov@linaro.org>
> 
> The rxmacro, txmacro, vamacro, soundwire nodes, lpass clock
> controllers are required to support audio playback and
> audio capture on sm6115 and its derivatives.
> 
> Signed-off-by: Alexey Klimov <alexey.klimov@linaro.org>
> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
> ---

[...]

> +		swr1: soundwire@a610000 {
> +			compatible = "qcom,soundwire-v1.6.0";
> +			reg = <0x0 0x0a610000 0x0 0x10000>;
> +			interrupts = <GIC_SPI 297 IRQ_TYPE_LEVEL_HIGH>;
> +
> +			clocks = <&rxmacro>;
> +			clock-names = "iface";
> +
> +			resets = <&lpass_audiocc 0>;
> +			reset-names = "swr_audio_cgcr";
> +
> +			label = "RX";
> +			qcom,din-ports = <0>;
> +			qcom,dout-ports = <5>;
> +
> +			qcom,ports-sinterval-low =	/bits/ 8 <0x03 0x1f 0x1f 0x07 0x00>;
> +			qcom,ports-offset1 =		/bits/ 8 <0x00 0x00 0x0b 0x01 0x00>;
> +			qcom,ports-offset2 =		/bits/ 8 <0x00 0x00 0x0b 0x00 0x00>;
> +			qcom,ports-hstart =		/bits/ 8 <0xff 0x03 0xff 0xff 0xff>;
> +			qcom,ports-hstop =		/bits/ 8 <0xff 0x06 0xff 0xff 0xff>;
> +			qcom,ports-word-length =	/bits/ 8 <0x01 0x07 0x04 0xff 0xff>;
> +			qcom,ports-block-pack-mode =	/bits/ 8 <0xff 0x00 0x01 0xff 0xff>;
> +			qcom,ports-block-group-count =	/bits/ 8 <0xff 0xff 0xff 0xff 0x00>;
> +			qcom,ports-lane-control =	/bits/ 8 <0x01 0x00 0x00 0x00 0x00>;

I believe you'll hit the same issue as described here

https://lore.kernel.org/linux-arm-msm/DGJTU2TOFZR7.2MOU6I6J8GV4L@fairphone.com/

with both soundwire controllers

Konrad

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

* Re: [PATCH v2 3/5] arm64: dts: qcom: agatti: add LPASS devices
  2026-02-23 13:39 ` [PATCH v2 3/5] arm64: dts: qcom: agatti: add LPASS devices Srinivas Kandagatla
  2026-02-24  2:58   ` Dmitry Baryshkov
  2026-02-24 12:24   ` Konrad Dybcio
@ 2026-02-24 12:28   ` Konrad Dybcio
  2026-05-15  8:29     ` Srinivas Kandagatla
  2 siblings, 1 reply; 30+ messages in thread
From: Konrad Dybcio @ 2026-02-24 12:28 UTC (permalink / raw)
  To: Srinivas Kandagatla, lee, robh, krzk+dt, conor+dt, andersson,
	konradybcio, sboyd
  Cc: linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini

On 2/23/26 2:39 PM, Srinivas Kandagatla wrote:
> From: Alexey Klimov <alexey.klimov@linaro.org>
> 
> The rxmacro, txmacro, vamacro, soundwire nodes, lpass clock
> controllers are required to support audio playback and
> audio capture on sm6115 and its derivatives.
> 
> Signed-off-by: Alexey Klimov <alexey.klimov@linaro.org>
> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
> ---

[...]

> +		lpass_audiocc: clock-controller@a6a9000 {
> +			compatible = "qcom,sm6115-lpassaudiocc";
> +			reg = <0x0 0x0a6a9000 0x0 0x1000>;
> +			#reset-cells = <1>;
> +		};

This should be called "qcom,sm6115-lpass-audio-csr" and should probably
have a syscon fallback as there's a lot of various magic tunables in
there, in addition to the CGCR bits. The clock driver can continue to
bind to this new compatible, like we do with the SoC-side TCSR on e.g.
8550 and the tcsrcc-sm8550 driver.

[...]

> +		lpasscc: clock-controller@a7ec000 {
> +			compatible = "qcom,sm6115-lpasscc";
> +			reg = <0x0 0x0a7e0000 0x0 0x12000>;
> +			#reset-cells = <1>;
> +		};

All the same, except "qcom,sm6115-lpass-tcsr"

I'm once again sorry for not getting this right n years ago, but I did not
have the sufficient documentation back then

Konrad

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

* Re: [PATCH v2 3/5] arm64: dts: qcom: agatti: add LPASS devices
  2026-02-24 12:28   ` Konrad Dybcio
@ 2026-05-15  8:29     ` Srinivas Kandagatla
  2026-07-17  9:39       ` Konrad Dybcio
  0 siblings, 1 reply; 30+ messages in thread
From: Srinivas Kandagatla @ 2026-05-15  8:29 UTC (permalink / raw)
  To: Konrad Dybcio, lee, robh, krzk+dt, conor+dt, andersson,
	konradybcio, sboyd
  Cc: linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini

On 2/24/26 12:28 PM, Konrad Dybcio wrote:
> On 2/23/26 2:39 PM, Srinivas Kandagatla wrote:
>> From: Alexey Klimov <alexey.klimov@linaro.org>
>>
>> The rxmacro, txmacro, vamacro, soundwire nodes, lpass clock
>> controllers are required to support audio playback and
>> audio capture on sm6115 and its derivatives.
>>
>> Signed-off-by: Alexey Klimov <alexey.klimov@linaro.org>
>> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
>> ---
> 
> [...]
> 
>> +		lpass_audiocc: clock-controller@a6a9000 {
>> +			compatible = "qcom,sm6115-lpassaudiocc";
>> +			reg = <0x0 0x0a6a9000 0x0 0x1000>;
>> +			#reset-cells = <1>;
>> +		};
> 
> This should be called "qcom,sm6115-lpass-audio-csr" and should probably
> have a syscon fallback as there's a lot of various magic tunables in
> there, in addition to the CGCR bits. The clock driver can continue to
> bind to this new compatible, like we do with the SoC-side TCSR on e.g.
> 8550 and the tcsrcc-sm8550 driver.
Are you expecting this to be a reset-controller interface or just syscon
so that drivers can poke into this register space.

The reason to take the full address space here and represent the HW
control bits as reset controller is that we have room for adding these
various magic tunables with some standard interface when required in
this driver.

I could have done the way as you suggested with syscon and let the
drivers poke the whatever values it want, but that is not scalable and
clutters the interfaces and encourage to use the way it was done in
downstream.



This is same for all the Qualcomm SoCs, why sm6115 has to do this change
alone? And its going to break the Device tree abi.

Sorry but I can not do the changes that you suggested here.

I would suggest that we use the existing mechanism which is more future
proof.


Please suggest otherwise, I would like to move on with enabling audio on
UNO Q platform.


--srini

> 
> [...]
> 
>> +		lpasscc: clock-controller@a7ec000 {
>> +			compatible = "qcom,sm6115-lpasscc";
>> +			reg = <0x0 0x0a7e0000 0x0 0x12000>;
>> +			#reset-cells = <1>;
>> +		};
> 
> All the same, except "qcom,sm6115-lpass-tcsr"
> 
> I'm once again sorry for not getting this right n years ago, but I did not
> have the sufficient documentation back then


> 
> Konrad


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

* Re: [PATCH v2 3/5] arm64: dts: qcom: agatti: add LPASS devices
  2026-05-15  8:29     ` Srinivas Kandagatla
@ 2026-07-17  9:39       ` Konrad Dybcio
  0 siblings, 0 replies; 30+ messages in thread
From: Konrad Dybcio @ 2026-07-17  9:39 UTC (permalink / raw)
  To: Srinivas Kandagatla, lee, robh, krzk+dt, conor+dt, andersson,
	konradybcio, sboyd
  Cc: linux-arm-msm, devicetree, linux-kernel, alexey.klimov, r.mereu,
	srini

On 5/15/26 10:29 AM, Srinivas Kandagatla wrote:
> On 2/24/26 12:28 PM, Konrad Dybcio wrote:
>> On 2/23/26 2:39 PM, Srinivas Kandagatla wrote:
>>> From: Alexey Klimov <alexey.klimov@linaro.org>
>>>
>>> The rxmacro, txmacro, vamacro, soundwire nodes, lpass clock
>>> controllers are required to support audio playback and
>>> audio capture on sm6115 and its derivatives.
>>>
>>> Signed-off-by: Alexey Klimov <alexey.klimov@linaro.org>
>>> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
>>> ---


> I would suggest that we use the existing mechanism which is more future
> proof.
> 
> 
> Please suggest otherwise, I would like to move on with enabling audio on
> UNO Q platform.

If you pinky-promise we are never ever going to need the other registers
(or if we do, you'll be able to represent them reasonably), we can go
forward with the established practice

Konrad

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

* [PATCH v3 0/5] arm64: dts: arduino-imola: add support for sound
  2026-02-23 13:39 [PATCH v2 0/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
                   ` (4 preceding siblings ...)
  2026-02-23 13:39 ` [PATCH v2 5/5] arm64: defconfig: Enable configs for audio drivers on Arduino UnoQ Srinivas Kandagatla
@ 2026-09-22 22:11 ` Srinivas Kandagatla
  2026-09-22 22:11   ` [PATCH v3 1/5] clk: qcom: fix SM6115 lpasscc register offset Srinivas Kandagatla
                     ` (4 more replies)
  5 siblings, 5 replies; 30+ messages in thread
From: Srinivas Kandagatla @ 2026-09-22 22:11 UTC (permalink / raw)
  To: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd
  Cc: dmitry.baryshkov, alexey.klimov, r.mereu, srini, linux-arm-msm,
	devicetree, linux-kernel, Srinivas Kandagatla

This patchset adds support for audio on Arduino-Imola platform which is
based on Agatti SoC. Some of Alexey's patches are reworked and sent
here as per previous review comments, mainly on the dt-bindings part.

Base SoC-level dtsi bits are picked up from
https://git.codelinaro.org/alexey.klimov/linux_next_tracking/-/commits/rb1_audio_wip_v3?ref_type=HEADS

Along with these changes, add sound nodes for Imola, a clk fix and
defconfig changes.

thanks,
Srini

Changes since v2:
    - dt-bindings/mfd: switch to properties.compatible.contains.enum
      with required: compatible, per Rob.
    - agatti.dtsi: collapse each <&q6afecc ...> clock cell onto a
      single line, per Dmitry.
    - keep qcom,sm6115-lpassaudiocc / qcom,sm6115-lpasscc compatibles;
      Konrad Acked staying with the established practice.
    - defconfig: carry Reviewed-by from Dmitry.
    - rebase on next-20260917.

Changes since v1:
    - updated various register ranges as per documentation.
    - added a fix for sm6115 lpasscc driver.
    - updated commit log
    - fixed various style issues in dt nodes.

Alexey Klimov (2):
  dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec
  arm64: dts: qcom: agatti: add LPASS devices

Srinivas Kandagatla (3):
  clk: qcom: fix SM6115 lpasscc register offset
  arm64: dts: arduino-imola: add support for sound
  arm64: defconfig: Enable configs for audio drivers on Arduino UnoQ

 .../bindings/mfd/qcom,spmi-pmic.yaml          |  10 +-
 arch/arm64/boot/dts/qcom/agatti.dtsi          | 157 ++++++++++++++++++
 arch/arm64/boot/dts/qcom/pm4125.dtsi          |   7 +
 .../boot/dts/qcom/qrb2210-arduino-imola.dts   | 134 +++++++++++++++
 arch/arm64/configs/defconfig                  |   2 +
 drivers/clk/qcom/lpasscc-sm6115.c             |   4 +-
 6 files changed, 311 insertions(+), 3 deletions(-)


base-commit: e657a464aba873f5eaf3ca821b6e4016674492d6
-- 
2.53.0


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

* [PATCH v3 1/5] clk: qcom: fix SM6115 lpasscc register offset
  2026-09-22 22:11 ` [PATCH v3 0/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
@ 2026-09-22 22:11   ` Srinivas Kandagatla
  2026-09-22 23:42     ` Alexey Klimov
  2026-09-22 22:11   ` [PATCH v3 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec Srinivas Kandagatla
                     ` (3 subsequent siblings)
  4 siblings, 1 reply; 30+ messages in thread
From: Srinivas Kandagatla @ 2026-09-22 22:11 UTC (permalink / raw)
  To: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd
  Cc: dmitry.baryshkov, alexey.klimov, r.mereu, srini, linux-arm-msm,
	devicetree, linux-kernel, Srinivas Kandagatla, Konrad Dybcio

For some reason we ended with incorrect register offset for soundwire tx
controller reset and the regmap register max was also incorrect it was
0x1000 instead of 0x12000 which is full register range for this IP.

This was somehow compenseated in DT reg property which got it working so
far.

Fix this by correcting the actual offset and max registers as per SoC
documentation.

Fixes: b076b995e225 ("clk: qcom: Add SM6115 LPASSCC")
Cc: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
---
 drivers/clk/qcom/lpasscc-sm6115.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/clk/qcom/lpasscc-sm6115.c b/drivers/clk/qcom/lpasscc-sm6115.c
index 226dc02fc42d..fcc1512d4a99 100644
--- a/drivers/clk/qcom/lpasscc-sm6115.c
+++ b/drivers/clk/qcom/lpasscc-sm6115.c
@@ -34,7 +34,7 @@ static const struct qcom_cc_desc lpass_audiocc_sm6115_reset_desc = {
 };
 
 static const struct qcom_reset_map lpasscc_sm6115_resets[] = {
-	[LPASS_SWR_TX_CONFIG_CGCR] = { .reg = 0x100, .bit = 1, .udelay = 500 },
+	[LPASS_SWR_TX_CONFIG_CGCR] = { .reg = 0xc100, .bit = 1, .udelay = 500 },
 };
 
 static struct regmap_config lpasscc_sm6115_regmap_config = {
@@ -42,7 +42,7 @@ static struct regmap_config lpasscc_sm6115_regmap_config = {
 	.reg_stride = 4,
 	.val_bits = 32,
 	.name = "lpass-tcsr",
-	.max_register = 0x1000,
+	.max_register = 0x12000,
 };
 
 static const struct qcom_cc_desc lpasscc_sm6115_reset_desc = {
-- 
2.53.0


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

* [PATCH v3 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec
  2026-09-22 22:11 ` [PATCH v3 0/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
  2026-09-22 22:11   ` [PATCH v3 1/5] clk: qcom: fix SM6115 lpasscc register offset Srinivas Kandagatla
@ 2026-09-22 22:11   ` Srinivas Kandagatla
  2026-09-22 22:21     ` sashiko-bot
  2026-09-28 10:09     ` Krzysztof Kozlowski
  2026-09-22 22:11   ` [PATCH v3 3/5] arm64: dts: qcom: agatti: add LPASS devices Srinivas Kandagatla
                     ` (2 subsequent siblings)
  4 siblings, 2 replies; 30+ messages in thread
From: Srinivas Kandagatla @ 2026-09-22 22:11 UTC (permalink / raw)
  To: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd
  Cc: dmitry.baryshkov, alexey.klimov, r.mereu, srini, linux-arm-msm,
	devicetree, linux-kernel, Srinivas Kandagatla

From: Alexey Klimov <alexey.klimov@linaro.org>

Qualcomm Agatti SoC has PM4125 PMIC, which includes audio codec.
Audio codec has TX and RX soundwire slave devices to connect to on-chip
soundwire master.

Add missing qcom,pm4125-codec compatible to pattern of audio-codec node
properties in mfd qcom,spmi-pmic schema to complete the audio codec support.

Signed-off-by: Alexey Klimov <alexey.klimov@linaro.org>
[Srini: reworked the patch]
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
---
 .../devicetree/bindings/mfd/qcom,spmi-pmic.yaml        | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
index f6534e9e9912..d750da31ae3f 100644
--- a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
+++ b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
@@ -148,7 +148,15 @@ patternProperties:
 
   "^audio-codec@[0-9a-f]+$":
     type: object
-    $ref: /schemas/sound/qcom,pm8916-wcd-analog-codec.yaml#
+    properties:
+      compatible:
+        contains:
+          enum:
+            - qcom,pm4125-codec
+            - qcom,pm8916-wcd-analog-codec
+
+    required:
+      - compatible
 
   "^battery@[0-9a-f]+$":
     type: object
-- 
2.53.0


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

* [PATCH v3 3/5] arm64: dts: qcom: agatti: add LPASS devices
  2026-09-22 22:11 ` [PATCH v3 0/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
  2026-09-22 22:11   ` [PATCH v3 1/5] clk: qcom: fix SM6115 lpasscc register offset Srinivas Kandagatla
  2026-09-22 22:11   ` [PATCH v3 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec Srinivas Kandagatla
@ 2026-09-22 22:11   ` Srinivas Kandagatla
  2026-09-22 22:21     ` sashiko-bot
  2026-09-22 22:11   ` [PATCH v3 4/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
  2026-09-22 22:11   ` [PATCH v3 5/5] arm64: defconfig: Enable configs for audio drivers on Arduino UnoQ Srinivas Kandagatla
  4 siblings, 1 reply; 30+ messages in thread
From: Srinivas Kandagatla @ 2026-09-22 22:11 UTC (permalink / raw)
  To: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd
  Cc: dmitry.baryshkov, alexey.klimov, r.mereu, srini, linux-arm-msm,
	devicetree, linux-kernel, Srinivas Kandagatla

From: Alexey Klimov <alexey.klimov@linaro.org>

The rxmacro, txmacro, vamacro, soundwire nodes, lpass clock
controllers are required to support audio playback and
audio capture on sm6115 and its derivatives.

Signed-off-by: Alexey Klimov <alexey.klimov@linaro.org>
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
---
 arch/arm64/boot/dts/qcom/agatti.dtsi | 157 +++++++++++++++++++++++++++
 1 file changed, 157 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/agatti.dtsi b/arch/arm64/boot/dts/qcom/agatti.dtsi
index e7fed60a59d9..6d99e24e3dc2 100644
--- a/arch/arm64/boot/dts/qcom/agatti.dtsi
+++ b/arch/arm64/boot/dts/qcom/agatti.dtsi
@@ -770,6 +770,42 @@ data-pins {
 					drive-strength = <8>;
 				};
 			};
+
+			lpass_tx_swr_active: lpass-tx-swr-active-state {
+				clk-pins {
+					pins = "gpio0";
+					function = "swr_tx_clk";
+					drive-strength = <10>;
+					slew-rate = <3>;
+					bias-disable;
+				};
+
+				data-pins {
+					pins = "gpio1", "gpio2";
+					function = "swr_tx_data";
+					drive-strength = <10>;
+					slew-rate = <3>;
+					bias-bus-hold;
+				};
+			};
+
+			lpass_rx_swr_active: lpass-rx-swr-active-state {
+				clk-pins {
+					pins = "gpio3";
+					function = "swr_rx_clk";
+					drive-strength = <10>;
+					slew-rate = <3>;
+					bias-disable;
+				};
+
+				data-pins {
+					pins = "gpio4", "gpio5";
+					function = "swr_rx_data";
+					drive-strength = <10>;
+					slew-rate = <3>;
+					bias-bus-hold;
+				};
+			};
 		};
 
 		gcc: clock-controller@1400000 {
@@ -2238,6 +2274,127 @@ glink-edge {
 			};
 		};
 
+		rxmacro: codec@a600000 {
+			compatible = "qcom,sm6115-lpass-rx-macro";
+			reg = <0x0 0xa600000 0x0 0x1000>;
+
+			clocks = <&q6afecc LPASS_CLK_ID_RX_CORE_MCLK LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&q6afecc LPASS_CLK_ID_RX_CORE_NPL_MCLK LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&q6afecc LPASS_HW_DCODEC_VOTE LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&vamacro>;
+			clock-names = "mclk",
+				      "npl",
+				      "dcodec",
+				      "fsgen";
+			#clock-cells = <0>;
+			clock-output-names = "mclk";
+			#sound-dai-cells = <1>;
+		};
+
+		swr1: soundwire@a610000 {
+			compatible = "qcom,soundwire-v1.6.0";
+			reg = <0x0 0x0a610000 0x0 0x10000>;
+			interrupts = <GIC_SPI 297 IRQ_TYPE_LEVEL_HIGH>;
+
+			clocks = <&rxmacro>;
+			clock-names = "iface";
+
+			resets = <&lpass_audiocc 0>;
+			reset-names = "swr_audio_cgcr";
+
+			label = "RX";
+			qcom,din-ports = <0>;
+			qcom,dout-ports = <5>;
+
+			qcom,ports-sinterval-low =	/bits/ 8 <0x03 0x1f 0x1f 0x07 0x00>;
+			qcom,ports-offset1 =		/bits/ 8 <0x00 0x00 0x0b 0x01 0x00>;
+			qcom,ports-offset2 =		/bits/ 8 <0x00 0x00 0x0b 0x00 0x00>;
+			qcom,ports-hstart =		/bits/ 8 <0xff 0x03 0xff 0xff 0xff>;
+			qcom,ports-hstop =		/bits/ 8 <0xff 0x06 0xff 0xff 0xff>;
+			qcom,ports-word-length =	/bits/ 8 <0x01 0x07 0x04 0xff 0xff>;
+			qcom,ports-block-pack-mode =	/bits/ 8 <0xff 0x00 0x01 0xff 0xff>;
+			qcom,ports-block-group-count =	/bits/ 8 <0xff 0xff 0xff 0xff 0x00>;
+			qcom,ports-lane-control =	/bits/ 8 <0x01 0x00 0x00 0x00 0x00>;
+
+			#sound-dai-cells = <1>;
+			#address-cells = <2>;
+			#size-cells = <0>;
+		};
+
+		txmacro: codec@a620000 {
+			compatible = "qcom,sm6115-lpass-tx-macro";
+			reg = <0x0 0x0a620000 0x0 0x1000>;
+
+			clocks = <&q6afecc LPASS_CLK_ID_TX_CORE_MCLK LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&q6afecc LPASS_CLK_ID_TX_CORE_NPL_MCLK LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&q6afecc LPASS_HW_DCODEC_VOTE LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&vamacro>;
+			clock-names = "mclk",
+				      "npl",
+				      "dcodec",
+				      "fsgen";
+			#clock-cells = <0>;
+			clock-output-names = "mclk";
+			#sound-dai-cells = <1>;
+		};
+
+		lpass_audiocc: clock-controller@a6a9000 {
+			compatible = "qcom,sm6115-lpassaudiocc";
+			reg = <0x0 0x0a6a9000 0x0 0x1000>;
+			#reset-cells = <1>;
+		};
+
+		vamacro: codec@a730000 {
+			compatible = "qcom,sm6115-lpass-va-macro";
+			reg = <0x0 0x0a730000 0x0 0x1000>;
+
+			clocks = <&q6afecc LPASS_CLK_ID_TX_CORE_MCLK LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&q6afecc LPASS_HW_DCODEC_VOTE LPASS_CLK_ATTRIBUTE_COUPLE_NO>,
+				 <&q6afecc LPASS_CLK_ID_TX_CORE_NPL_MCLK LPASS_CLK_ATTRIBUTE_COUPLE_NO>;
+			clock-names = "mclk",
+				      "dcodec",
+				      "npl";
+			#clock-cells = <0>;
+			clock-output-names = "fsgen";
+			#sound-dai-cells = <1>;
+		};
+
+		swr0: soundwire@a740000 {
+			compatible = "qcom,soundwire-v1.6.0";
+			reg = <0x0 0x0a740000 0x0 0x10000>;
+			interrupts = <GIC_SPI 296 IRQ_TYPE_LEVEL_HIGH>,
+				     <GIC_SPI 79 IRQ_TYPE_LEVEL_HIGH>;
+			clocks = <&txmacro>;
+			clock-names = "iface";
+
+			resets = <&lpasscc 0>;
+			reset-names = "swr_audio_cgcr";
+
+			label = "VA_TX";
+			qcom,din-ports = <3>;
+			qcom,dout-ports = <0>;
+
+			qcom,ports-sinterval-low =	/bits/ 8 <0x03 0x03 0x03>;
+			qcom,ports-offset1 =		/bits/ 8 <0x01 0x02 0x01>;
+			qcom,ports-offset2 =		/bits/ 8 <0x00 0x00 0x00>;
+			qcom,ports-hstart =		/bits/ 8 <0xff 0xff 0xff>;
+			qcom,ports-hstop =		/bits/ 8 <0xff 0xff 0xff>;
+			qcom,ports-word-length =	/bits/ 8 <0xff 0xff 0xff>;
+			qcom,ports-block-pack-mode =	/bits/ 8 <0xff 0xff 0xff>;
+			qcom,ports-block-group-count =	/bits/ 8 <0xff 0xff 0xff>;
+			qcom,ports-lane-control =	/bits/ 8 <0x00 0x00 0x00>;
+
+			#sound-dai-cells = <1>;
+			#address-cells = <2>;
+			#size-cells = <0>;
+		};
+
+		lpasscc: clock-controller@a7ec000 {
+			compatible = "qcom,sm6115-lpasscc";
+			reg = <0x0 0x0a7e0000 0x0 0x12000>;
+			#reset-cells = <1>;
+		};
+
 		remoteproc_adsp: remoteproc@ab00000 {
 			compatible = "qcom,qcm2290-adsp-pas", "qcom,sm6115-adsp-pas";
 			reg = <0x0 0x0ab00000 0x0 0x100>;
-- 
2.53.0


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

* [PATCH v3 4/5] arm64: dts: arduino-imola: add support for sound
  2026-09-22 22:11 ` [PATCH v3 0/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
                     ` (2 preceding siblings ...)
  2026-09-22 22:11   ` [PATCH v3 3/5] arm64: dts: qcom: agatti: add LPASS devices Srinivas Kandagatla
@ 2026-09-22 22:11   ` Srinivas Kandagatla
  2026-09-22 22:26     ` sashiko-bot
  2026-09-23 19:31     ` Alexey Klimov
  2026-09-22 22:11   ` [PATCH v3 5/5] arm64: defconfig: Enable configs for audio drivers on Arduino UnoQ Srinivas Kandagatla
  4 siblings, 2 replies; 30+ messages in thread
From: Srinivas Kandagatla @ 2026-09-22 22:11 UTC (permalink / raw)
  To: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd
  Cc: dmitry.baryshkov, alexey.klimov, r.mereu, srini, linux-arm-msm,
	devicetree, linux-kernel, Srinivas Kandagatla

Add support for sound on Arduino UNO Q board, which includes
- Headset playback and record.
- Lineout

Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
---
 arch/arm64/boot/dts/qcom/pm4125.dtsi          |   7 +
 .../boot/dts/qcom/qrb2210-arduino-imola.dts   | 134 ++++++++++++++++++
 2 files changed, 141 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/pm4125.dtsi b/arch/arm64/boot/dts/qcom/pm4125.dtsi
index 3dc8d667d091..85da78aec578 100644
--- a/arch/arm64/boot/dts/qcom/pm4125.dtsi
+++ b/arch/arm64/boot/dts/qcom/pm4125.dtsi
@@ -81,6 +81,13 @@ pm4125_gpios: gpio@c000 {
 			interrupt-controller;
 			#interrupt-cells = <2>;
 		};
+
+		pmic4125_codec: audio-codec@f000 {
+			compatible = "qcom,pm4125-codec";
+			reg = <0xf000>;
+			#sound-dai-cells = <1>;
+			status = "disabled";
+		};
 	};
 
 	pmic@1 {
diff --git a/arch/arm64/boot/dts/qcom/qrb2210-arduino-imola.dts b/arch/arm64/boot/dts/qcom/qrb2210-arduino-imola.dts
index c472e13fceca..e99d2a56dc28 100644
--- a/arch/arm64/boot/dts/qcom/qrb2210-arduino-imola.dts
+++ b/arch/arm64/boot/dts/qcom/qrb2210-arduino-imola.dts
@@ -110,6 +110,102 @@ multi-led {
 		leds = <&ledr>, <&ledg>, <&ledb>;
 	};
 
+	sound {
+		compatible = "qcom,qrb2210-sndcard";
+		model = "Arduino-Imola-HPH-LOUT";
+		audio-routing =	"IN1_HPHL", "HPHL_OUT",
+				"IN2_HPHR", "HPHR_OUT",
+				"AMIC2", "MIC BIAS2";
+
+		ear-playback-dai-link {
+			link-name = "Ear Out Playback";
+
+			codec {
+				sound-dai = <&pmic4125_codec 0>, <&swr1 0>, <&rxmacro 0>;
+			};
+
+			cpu {
+				sound-dai = <&q6afedai RX_CODEC_DMA_RX_0>;
+			};
+
+			platform {
+				sound-dai = <&q6routing>;
+			};
+		};
+
+		hph-capture-dai-link {
+			link-name = "Headphones Capture";
+
+			codec {
+				sound-dai = <&pmic4125_codec 1>, <&swr0 0>, <&txmacro 0>;
+			};
+
+			cpu {
+				sound-dai = <&q6afedai TX_CODEC_DMA_TX_3>;
+			};
+
+			platform {
+				sound-dai = <&q6routing>;
+			};
+		};
+
+		hph-playback-dai-link {
+			link-name = "Headphones Playback";
+
+			codec {
+				sound-dai = <&pmic4125_codec 0>, <&swr1 0>, <&rxmacro 0>;
+			};
+
+			cpu {
+				sound-dai = <&q6afedai RX_CODEC_DMA_RX_0>;
+			};
+
+			platform {
+				sound-dai = <&q6routing>;
+			};
+		};
+
+		lo-playback-dai-link {
+			link-name = "Line Out Playback";
+
+			codec {
+				sound-dai = <&pmic4125_codec 0>, <&swr1 0>, <&rxmacro 0>;
+			};
+
+			cpu {
+				sound-dai = <&q6afedai RX_CODEC_DMA_RX_0>;
+			};
+
+			platform {
+				sound-dai = <&q6routing>;
+			};
+		};
+
+		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>;
+			};
+		};
+	};
+
 	vreg_anx_30: regulator-anx-30 {
 		compatible = "regulator-fixed";
 		regulator-name = "anx30";
@@ -421,6 +517,44 @@ mcu@0 {
 	};
 };
 
+&pmic4125_codec {
+	vdd-io-supply = <&pm4125_l15>;
+	vdd-cp-supply = <&pm4125_s4>;
+	vdd-pa-vpos-supply = <&pm4125_s4>;
+	vdd-mic-bias-supply = <&pm4125_l22>;
+
+	qcom,micbias1-microvolt = <1800000>;
+	qcom,micbias2-microvolt = <1800000>;
+	qcom,micbias3-microvolt = <1800000>;
+
+	qcom,rx-device = <&pm4125_rx>;
+	qcom,tx-device = <&pm4125_tx>;
+
+	status = "okay";
+};
+
+&swr0 {
+	pinctrl-0 = <&lpass_tx_swr_active>;
+	pinctrl-names = "default";
+
+	pm4125_tx: codec@0,3 {
+		compatible = "sdw20217010c00";
+		reg = <0 3>;
+		qcom,tx-port-mapping = <1 1 2 3>;
+	};
+};
+
+&swr1 {
+	pinctrl-0 = <&lpass_rx_swr_active>;
+	pinctrl-names = "default";
+
+	pm4125_rx: codec@0,4 {
+		compatible = "sdw20217010c00";
+		reg = <0 4>;
+		qcom,rx-port-mapping = <1 2 3 4 5>;
+	};
+};
+
 &tlmm {
 	jmisc_gpio18: jmisc-gpio18-state {
 		pins = "gpio18";
-- 
2.53.0


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

* [PATCH v3 5/5] arm64: defconfig: Enable configs for audio drivers on Arduino UnoQ
  2026-09-22 22:11 ` [PATCH v3 0/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
                     ` (3 preceding siblings ...)
  2026-09-22 22:11   ` [PATCH v3 4/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
@ 2026-09-22 22:11   ` Srinivas Kandagatla
  2026-09-22 23:39     ` Alexey Klimov
  4 siblings, 1 reply; 30+ messages in thread
From: Srinivas Kandagatla @ 2026-09-22 22:11 UTC (permalink / raw)
  To: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd
  Cc: dmitry.baryshkov, alexey.klimov, r.mereu, srini, linux-arm-msm,
	devicetree, linux-kernel, Srinivas Kandagatla

Enable reset controller and pm4125 audio codec driver that are required
to enable audio support on Arduino UnoQ board.

Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
---
 arch/arm64/configs/defconfig | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arm64/configs/defconfig b/arch/arm64/configs/defconfig
index 982ea1758eb6..f734c413dba5 100644
--- a/arch/arm64/configs/defconfig
+++ b/arch/arm64/configs/defconfig
@@ -1168,6 +1168,7 @@ CONFIG_SND_SOC_GTM601=m
 CONFIG_SND_SOC_MAX98090=m
 CONFIG_SND_SOC_MSM8916_WCD_ANALOG=m
 CONFIG_SND_SOC_MSM8916_WCD_DIGITAL=m
+CONFIG_SND_SOC_PM4125_SDW=m
 CONFIG_SND_SOC_RK3308=m
 CONFIG_SND_SOC_RK817=m
 CONFIG_SND_SOC_RT5640=m
@@ -1586,6 +1587,7 @@ CONFIG_SM_GPUCC_8450=m
 CONFIG_SM_GPUCC_8550=m
 CONFIG_SM_GPUCC_8650=m
 CONFIG_SM_GPUCC_8750=m
+CONFIG_SM_LPASSCC_6115=m
 CONFIG_SM_TCSRCC_8550=y
 CONFIG_SM_TCSRCC_8650=y
 CONFIG_SM_TCSRCC_8750=m
-- 
2.53.0


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

* Re: [PATCH v3 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec
  2026-09-22 22:11   ` [PATCH v3 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec Srinivas Kandagatla
@ 2026-09-22 22:21     ` sashiko-bot
  2026-09-28 10:09     ` Krzysztof Kozlowski
  1 sibling, 0 replies; 30+ messages in thread
From: sashiko-bot @ 2026-09-22 22:21 UTC (permalink / raw)
  To: Srinivas Kandagatla; +Cc: conor+dt, robh, devicetree

Thank you for your contribution! Sashiko AI review found 2 potential issue(s) to consider:
- [Medium] dt-bindings: mfd: qcom,spmi-pmic: schema validation regression for wcd codecs
- [Low] dt-bindings: mfd: qcom,spmi-pmic: typo in commit title (pm4124 vs pm4125)
--

commit aa39b4a36b271ce733e772eaf378517309e2b1c7
Author: Alexey Klimov <alexey.klimov@linaro.org>

dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec

This commit adds the missing qcom,pm4125-codec compatible string to the
audio-codec node pattern properties in the mfd qcom,spmi-pmic schema to
support the audio codec on the Qualcomm Agatti SoC.

> dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec

This isn't a bug, but there is a typo in the commit subject. The title refers
to pm4124-codec, while the commit body and the actual compatible string added
in the patch use qcom,pm4125-codec.

> diff --git a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
> index f6534e9e9912e..d750da31ae3f5 100644
> --- a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
> +++ b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
> @@ -148,7 +148,15 @@ patternProperties:
>  
>    "^audio-codec@[0-9a-f]+$":
>      type: object
> -    $ref: /schemas/sound/qcom,pm8916-wcd-analog-codec.yaml#
> +    properties:
> +      compatible:
> +        contains:
> +          enum:
> +            - qcom,pm4125-codec
> +            - qcom,pm8916-wcd-analog-codec

[Severity: Medium]
Does replacing the $ref with a restricted enum block incorrectly limit the
allowed compatible strings? Devices using standalone compatibles like
qcom,pm8950-wcd-analog-codec or qcom,pm8953-wcd-analog-codec, which were
legally permitted by the child schema, will now fail validation against
qcom,spmi-pmic.yaml when running make dtbs_check.

> +
> +    required:
> +      - compatible

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/cover.1790114902.git.srinivas.kandagatla@oss.qualcomm.com?part=2

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

* Re: [PATCH v3 3/5] arm64: dts: qcom: agatti: add LPASS devices
  2026-09-22 22:11   ` [PATCH v3 3/5] arm64: dts: qcom: agatti: add LPASS devices Srinivas Kandagatla
@ 2026-09-22 22:21     ` sashiko-bot
  0 siblings, 0 replies; 30+ messages in thread
From: sashiko-bot @ 2026-09-22 22:21 UTC (permalink / raw)
  To: Srinivas Kandagatla; +Cc: robh, devicetree, conor+dt

Thank you for your contribution! Sashiko AI review found 2 potential issue(s) to consider:
- [Low] dt-bindings: qcom,agatti: unit address mismatch for lpasscc node
- [Low] dt-bindings: qcom,agatti: swr nodes lack status disabled or pinctrl
--

commit 0dce088f4d3617832ec5dd0787d22b15acf31f29
Author: Alexey Klimov <alexey.klimov@linaro.org>

arm64: dts: qcom: agatti: add LPASS devices
    
This commit adds the rxmacro, txmacro, vamacro, soundwire nodes, and lpass
clock controllers required to support audio playback and capture on sm6115
and its derivatives.

> diff --git a/arch/arm64/boot/dts/qcom/agatti.dtsi b/arch/arm64/boot/dts/qcom/agatti.dtsi
> index e7fed60a59d93..6d99e24e3dc2a 100644
> --- a/arch/arm64/boot/dts/qcom/agatti.dtsi
> +++ b/arch/arm64/boot/dts/qcom/agatti.dtsi

[ ... ]

> @@ -2238,6 +2274,127 @@ glink-edge {
>  			};
>  		};
>  
> +		rxmacro: codec@a600000 {

[ ... ]

> +		swr1: soundwire@a610000 {
> +			compatible = "qcom,soundwire-v1.6.0";
> +			reg = <0x0 0x0a610000 0x0 0x10000>;
> +			interrupts = <GIC_SPI 297 IRQ_TYPE_LEVEL_HIGH>;

[Severity: Low]
Does this node need to be disabled by default?

The swr1 RX soundwire node is added to the common .dtsi without a
status = "disabled" property or default pinctrl properties. If a downstream
board file includes this .dtsi but does not explicitly configure the pinctrl
or disable the node, the driver will unconditionally probe and fail to
operate correctly due to unlinked pins. 

Would it be better to disable external bus interfaces in common includes?

> +
> +			clocks = <&rxmacro>;
> +			clock-names = "iface";

[ ... ]

> +		swr0: soundwire@a740000 {
> +			compatible = "qcom,soundwire-v1.6.0";
> +			reg = <0x0 0x0a740000 0x0 0x10000>;
> +			interrupts = <GIC_SPI 296 IRQ_TYPE_LEVEL_HIGH>,
> +				     <GIC_SPI 79 IRQ_TYPE_LEVEL_HIGH>;

[Severity: Low]
Similarly for the swr0 TX soundwire node, should this node also be disabled
or provided with default pinctrl properties to prevent unconditional probing
on boards that do not configure it?

> +			clocks = <&txmacro>;
> +			clock-names = "iface";

[ ... ]

> +		lpasscc: clock-controller@a7ec000 {
> +			compatible = "qcom,sm6115-lpasscc";
> +			reg = <0x0 0x0a7e0000 0x0 0x12000>;

[Severity: Low]
Is there a typo in the unit address or the reg property here?

The node name clock-controller@a7ec000 does not match the base address in
its reg property (0x0a7e0000). This causes a simple_bus_reg validation
warning during dtc compilation.

> +			#reset-cells = <1>;
> +		};
> +
>  		remoteproc_adsp: remoteproc@ab00000 {

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/cover.1790114902.git.srinivas.kandagatla@oss.qualcomm.com?part=3

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

* Re: [PATCH v3 4/5] arm64: dts: arduino-imola: add support for sound
  2026-09-22 22:11   ` [PATCH v3 4/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
@ 2026-09-22 22:26     ` sashiko-bot
  2026-09-23 19:31     ` Alexey Klimov
  1 sibling, 0 replies; 30+ messages in thread
From: sashiko-bot @ 2026-09-22 22:26 UTC (permalink / raw)
  To: Srinivas Kandagatla; +Cc: devicetree, conor+dt, robh

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [High] ASoC: redundant BE DAI links for identical q6afe CPU DAI
--

commit bd3dd7751e736b11cf0fd37d9d4991d90e6ee507
Author: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>

arm64: dts: arduino-imola: add support for sound

Add support for sound on Arduino UNO Q board, which includes headset
playback and record, and lineout.

> diff --git a/arch/arm64/boot/dts/qcom/qrb2210-arduino-imola.dts b/arch/arm64/boot/dts/qcom/qrb2210-arduino-imola.dts
> index c472e13fceca4..e99d2a56dc287 100644
> --- a/arch/arm64/boot/dts/qcom/qrb2210-arduino-imola.dts
> +++ b/arch/arm64/boot/dts/qcom/qrb2210-arduino-imola.dts
[ ... ]
> +		ear-playback-dai-link {
> +			link-name = "Ear Out Playback";
> +
> +			codec {
> +				sound-dai = <&pmic4125_codec 0>, <&swr1 0>, <&rxmacro 0>;
> +			};
> +
> +			cpu {
> +				sound-dai = <&q6afedai RX_CODEC_DMA_RX_0>;
> +			};
[ ... ]
> +		hph-playback-dai-link {
> +			link-name = "Headphones Playback";
> +
> +			codec {
> +				sound-dai = <&pmic4125_codec 0>, <&swr1 0>, <&rxmacro 0>;
> +			};
> +
> +			cpu {
> +				sound-dai = <&q6afedai RX_CODEC_DMA_RX_0>;
> +			};
[ ... ]
> +		lo-playback-dai-link {
> +			link-name = "Line Out Playback";
> +
> +			codec {
> +				sound-dai = <&pmic4125_codec 0>, <&swr1 0>, <&rxmacro 0>;
> +			};
> +
> +			cpu {
> +				sound-dai = <&q6afedai RX_CODEC_DMA_RX_0>;
> +			};

[Severity: High]
Does defining multiple identical Backend (BE) DAI links cause conflicting
DSP driver operations?

This link, as well as ear-playback-dai-link and hph-playback-dai-link
defined above, map the exact same physical CPU DAI (RX_CODEC_DMA_RX_0) to the
exact same Codec DAIs.

When the ALSA DPCM core registers the card, it instantiates duplicate BE
runtimes. During audio playback, if the DPCM core triggers multiple of these
BEs concurrently or sequentially, could this interrupt active audio and
corrupt the shared hardware state? For instance, q6afe_dai_prepare() in
sound/soc/qcom/qdsp6/q6afe-dai.c checks is_port_started[dai->id]; if two
runtimes call prepare on the same DAI, the driver might abruptly stop and
restart the active DSP port.

Should logical branching to different endpoints (Ear, Headphones, Line Out)
be handled internally by the Codec driver's DAPM routing graph instead of
defining redundant BE bus links?

> +
> +			platform {
> +				sound-dai = <&q6routing>;
> +			};
> +		};

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/cover.1790114902.git.srinivas.kandagatla@oss.qualcomm.com?part=4

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

* Re: [PATCH v3 5/5] arm64: defconfig: Enable configs for audio drivers on Arduino UnoQ
  2026-09-22 22:11   ` [PATCH v3 5/5] arm64: defconfig: Enable configs for audio drivers on Arduino UnoQ Srinivas Kandagatla
@ 2026-09-22 23:39     ` Alexey Klimov
  0 siblings, 0 replies; 30+ messages in thread
From: Alexey Klimov @ 2026-09-22 23:39 UTC (permalink / raw)
  To: Srinivas Kandagatla, lee, robh, krzk+dt, conor+dt, andersson,
	konradybcio, sboyd
  Cc: dmitry.baryshkov, alexey.klimov, r.mereu, srini, linux-arm-msm,
	devicetree, linux-kernel

On Tue Sep 22, 2026 at 11:11 PM BST, Srinivas Kandagatla wrote:
> Enable reset controller and pm4125 audio codec driver that are required
> to enable audio support on Arduino UnoQ board.
>
> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>

Reviewed-by: Alexey Klimov <alexey.klimov@linaro.org>

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

* Re: [PATCH v3 1/5] clk: qcom: fix SM6115 lpasscc register offset
  2026-09-22 22:11   ` [PATCH v3 1/5] clk: qcom: fix SM6115 lpasscc register offset Srinivas Kandagatla
@ 2026-09-22 23:42     ` Alexey Klimov
  0 siblings, 0 replies; 30+ messages in thread
From: Alexey Klimov @ 2026-09-22 23:42 UTC (permalink / raw)
  To: Srinivas Kandagatla, lee, robh, krzk+dt, conor+dt, andersson,
	konradybcio, sboyd
  Cc: dmitry.baryshkov, alexey.klimov, r.mereu, srini, linux-arm-msm,
	devicetree, linux-kernel, Konrad Dybcio

On Tue Sep 22, 2026 at 11:11 PM BST, Srinivas Kandagatla wrote:
> For some reason we ended with incorrect register offset for soundwire tx
> controller reset and the regmap register max was also incorrect it was
> 0x1000 instead of 0x12000 which is full register range for this IP.
>
> This was somehow compenseated in DT reg property which got it working so
> far.
>
> Fix this by correcting the actual offset and max registers as per SoC
> documentation.
>
> Fixes: b076b995e225 ("clk: qcom: Add SM6115 LPASSCC")
> Cc: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>

Reviewed-by: Alexey Klimov <alexey.klimov@linaro.org>


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

* Re: [PATCH v3 4/5] arm64: dts: arduino-imola: add support for sound
  2026-09-22 22:11   ` [PATCH v3 4/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
  2026-09-22 22:26     ` sashiko-bot
@ 2026-09-23 19:31     ` Alexey Klimov
  1 sibling, 0 replies; 30+ messages in thread
From: Alexey Klimov @ 2026-09-23 19:31 UTC (permalink / raw)
  To: Srinivas Kandagatla, lee, robh, krzk+dt, conor+dt, andersson,
	konradybcio, sboyd
  Cc: dmitry.baryshkov, alexey.klimov, r.mereu, srini, linux-arm-msm,
	devicetree, linux-kernel

On Tue Sep 22, 2026 at 11:11 PM BST, Srinivas Kandagatla wrote:
> Add support for sound on Arduino UNO Q board, which includes
> - Headset playback and record.
> - Lineout

And "Ear Out Playback" as well?

> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>

It would be nice to see some Tested-by tags.
I can't it test because I think I don't have this board and no time if
some fancy connectors are required from scratch.

Anyhow, by just looking at this I don't see any issues, tx-port-mapping
also seems to be correct correct, so:

Reviewed-by: Alexey Klimov <alexey.klimov@linaro.org>

[..]

Best regards,
Alexey

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

* Re: [PATCH v3 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec
  2026-09-22 22:11   ` [PATCH v3 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec Srinivas Kandagatla
  2026-09-22 22:21     ` sashiko-bot
@ 2026-09-28 10:09     ` Krzysztof Kozlowski
  2026-09-28 17:42       ` Srinivas Kandagatla
  1 sibling, 1 reply; 30+ messages in thread
From: Krzysztof Kozlowski @ 2026-09-28 10:09 UTC (permalink / raw)
  To: Srinivas Kandagatla
  Cc: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd,
	dmitry.baryshkov, alexey.klimov, r.mereu, srini, linux-arm-msm,
	devicetree, linux-kernel

On Tue, Sep 22, 2026 at 11:11:24PM +0100, Srinivas Kandagatla wrote:
> From: Alexey Klimov <alexey.klimov@linaro.org>
> 
> Qualcomm Agatti SoC has PM4125 PMIC, which includes audio codec.
> Audio codec has TX and RX soundwire slave devices to connect to on-chip
> soundwire master.
> 
> Add missing qcom,pm4125-codec compatible to pattern of audio-codec node
> properties in mfd qcom,spmi-pmic schema to complete the audio codec support.
> 
> Signed-off-by: Alexey Klimov <alexey.klimov@linaro.org>
> [Srini: reworked the patch]
> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
> ---
>  .../devicetree/bindings/mfd/qcom,spmi-pmic.yaml        | 10 +++++++++-
>  1 file changed, 9 insertions(+), 1 deletion(-)
> 
> diff --git a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
> index f6534e9e9912..d750da31ae3f 100644
> --- a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
> +++ b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
> @@ -148,7 +148,15 @@ patternProperties:
>  
>    "^audio-codec@[0-9a-f]+$":
>      type: object
> -    $ref: /schemas/sound/qcom,pm8916-wcd-analog-codec.yaml#

This had three compatibles:

> +    properties:
> +      compatible:
> +        contains:
> +          enum:
> +            - qcom,pm4125-codec
> +            - qcom,pm8916-wcd-analog-codec

This has only one from that list (+a new one).

This must have rationale in commit msg.

Best regards,
Krzysztof


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

* Re: [PATCH v3 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec
  2026-09-28 10:09     ` Krzysztof Kozlowski
@ 2026-09-28 17:42       ` Srinivas Kandagatla
  0 siblings, 0 replies; 30+ messages in thread
From: Srinivas Kandagatla @ 2026-09-28 17:42 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: lee, robh, krzk+dt, conor+dt, andersson, konradybcio, sboyd,
	dmitry.baryshkov, alexey.klimov, r.mereu, srini, linux-arm-msm,
	devicetree, linux-kernel

On 9/28/26 11:09 AM, Krzysztof Kozlowski wrote:
> On Tue, Sep 22, 2026 at 11:11:24PM +0100, Srinivas Kandagatla wrote:
>> From: Alexey Klimov <alexey.klimov@linaro.org>
>>
>> Qualcomm Agatti SoC has PM4125 PMIC, which includes audio codec.
>> Audio codec has TX and RX soundwire slave devices to connect to on-chip
>> soundwire master.
>>
>> Add missing qcom,pm4125-codec compatible to pattern of audio-codec node
>> properties in mfd qcom,spmi-pmic schema to complete the audio codec support.
>>
>> Signed-off-by: Alexey Klimov <alexey.klimov@linaro.org>
>> [Srini: reworked the patch]
>> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
>> ---
>>  .../devicetree/bindings/mfd/qcom,spmi-pmic.yaml        | 10 +++++++++-
>>  1 file changed, 9 insertions(+), 1 deletion(-)
>>
>> diff --git a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
>> index f6534e9e9912..d750da31ae3f 100644
>> --- a/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
>> +++ b/Documentation/devicetree/bindings/mfd/qcom,spmi-pmic.yaml
>> @@ -148,7 +148,15 @@ patternProperties:
>>  
>>    "^audio-codec@[0-9a-f]+$":
>>      type: object
>> -    $ref: /schemas/sound/qcom,pm8916-wcd-analog-codec.yaml#
> 
> This had three compatibles:

That is true, things have moved under the hood.
Thanks for spotting this, I will fix this and send v4.



> 
>> +    properties:
>> +      compatible:
>> +        contains:
>> +          enum:
>> +            - qcom,pm4125-codec
>> +            - qcom,pm8916-wcd-analog-codec
> 
> This has only one from that list (+a new one).
> 
This model was suggested by Rob in last review, I will add the context
in msg.
> This must have rationale in commit msg.
> 
--srini
> Best regards,
> Krzysztof
> 


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

end of thread, other threads:[~2026-09-28 17:42 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-02-23 13:39 [PATCH v2 0/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
2026-02-23 13:39 ` [PATCH v2 1/5] clk: qcom: fix SM6115 lpasscc register offset Srinivas Kandagatla
2026-02-24 12:20   ` Konrad Dybcio
2026-02-23 13:39 ` [PATCH v2 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec Srinivas Kandagatla
2026-02-23 16:56   ` Rob Herring
2026-02-23 18:14     ` Srinivas Kandagatla
2026-02-23 13:39 ` [PATCH v2 3/5] arm64: dts: qcom: agatti: add LPASS devices Srinivas Kandagatla
2026-02-24  2:58   ` Dmitry Baryshkov
2026-02-24 12:24   ` Konrad Dybcio
2026-02-24 12:28   ` Konrad Dybcio
2026-05-15  8:29     ` Srinivas Kandagatla
2026-07-17  9:39       ` Konrad Dybcio
2026-02-23 13:39 ` [PATCH v2 4/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
2026-02-24 11:48   ` Konrad Dybcio
2026-02-23 13:39 ` [PATCH v2 5/5] arm64: defconfig: Enable configs for audio drivers on Arduino UnoQ Srinivas Kandagatla
2026-02-24  2:57   ` Dmitry Baryshkov
2026-09-22 22:11 ` [PATCH v3 0/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
2026-09-22 22:11   ` [PATCH v3 1/5] clk: qcom: fix SM6115 lpasscc register offset Srinivas Kandagatla
2026-09-22 23:42     ` Alexey Klimov
2026-09-22 22:11   ` [PATCH v3 2/5] dt-bindings: mfd: qcom,spmi-pmic: add compatibles for pm4124-codec Srinivas Kandagatla
2026-09-22 22:21     ` sashiko-bot
2026-09-28 10:09     ` Krzysztof Kozlowski
2026-09-28 17:42       ` Srinivas Kandagatla
2026-09-22 22:11   ` [PATCH v3 3/5] arm64: dts: qcom: agatti: add LPASS devices Srinivas Kandagatla
2026-09-22 22:21     ` sashiko-bot
2026-09-22 22:11   ` [PATCH v3 4/5] arm64: dts: arduino-imola: add support for sound Srinivas Kandagatla
2026-09-22 22:26     ` sashiko-bot
2026-09-23 19:31     ` Alexey Klimov
2026-09-22 22:11   ` [PATCH v3 5/5] arm64: defconfig: Enable configs for audio drivers on Arduino UnoQ Srinivas Kandagatla
2026-09-22 23:39     ` Alexey Klimov

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.