All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/9] Add support for remoteprocs on the MSM8953 platform
@ 2022-05-11 16:15 Sireesh Kodali
  2022-05-11 16:15 ` [PATCH 1/9] remoteproc: qcom: pas: Add MSM8953 ADSP PIL support Sireesh Kodali
                   ` (8 more replies)
  0 siblings, 9 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-11 16:15 UTC (permalink / raw)
  To: linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Sireesh Kodali

Hi,

This patch series adds support for the audio DSP (q6v5_pas), modem
(q6v5_mss), and WiFi (wcnss-pil) subsystems found on the MSM8953
platform. Device tree bindings for MSS and WCNSS have been converted to
YAML. The relevant nodes have also been added to the MSM8953
device tree.

Sireesh Kodali (8):
  remoteproc: qcom: pas: Add MSM8953 ADSP PIL support
  remoteproc: qcom: q6v5-mss: Add modem support on MSM8953
  dt-bindings: remoteproc: qcom: wcnss: Convert to YAML
  dt-bindings: remoteproc: qcom: wcnss: Add compatible for pronto v3
  dt-bindings: remoteproc: qcom: mss: Convert bindings to YAML
  dt-bindings: remoteproc: qcom: mss: Add MSS on MSM8953
  dt-bindings: remoteproc: qcom: adsp: Add ADSP on MSM8953
  arm64: dts: qcom: msm8953: Add remote processor nodes

Vladimir Lypak (1):
  remoteproc: qcom: qcom_wcnss: Add support for pronto-v3

 .../bindings/remoteproc/qcom,adsp.yaml        |   5 +
 .../bindings/remoteproc/qcom,q6v5.txt         | 302 --------
 .../bindings/remoteproc/qcom,q6v5.yaml        | 727 ++++++++++++++++++
 .../bindings/remoteproc/qcom,wcnss-pil.txt    | 177 -----
 .../bindings/remoteproc/qcom,wcnss-pil.yaml   | 230 ++++++
 arch/arm64/boot/dts/qcom/msm8953.dtsi         | 378 +++++++++
 drivers/remoteproc/qcom_q6v5_mss.c            |  64 +-
 drivers/remoteproc/qcom_q6v5_pas.c            |  31 +
 drivers/remoteproc/qcom_wcnss.c               |  13 +
 9 files changed, 1442 insertions(+), 485 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,q6v5.txt
 create mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,q6v5.yaml
 delete mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.txt
 create mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.yaml

-- 
2.36.0


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

* [PATCH 1/9] remoteproc: qcom: pas: Add MSM8953 ADSP PIL support
  2022-05-11 16:15 [PATCH 0/9] Add support for remoteprocs on the MSM8953 platform Sireesh Kodali
@ 2022-05-11 16:15 ` Sireesh Kodali
  2022-05-11 16:49   ` Dmitry Baryshkov
  2022-05-11 16:51   ` Dmitry Baryshkov
  2022-05-11 16:15 ` [PATCH 2/9] remoteproc: qcom: q6v5-mss: Add modem support on MSM8953 Sireesh Kodali
                   ` (7 subsequent siblings)
  8 siblings, 2 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-11 16:15 UTC (permalink / raw)
  To: linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Sireesh Kodali,
	Andy Gross, Mathieu Poirier

Add support for the Audio DSP PIL found on the Qualcomm MSM8953
platform. The same configuration is used on all SoCs based on the
MSM8953 platform (SDM450, SDA450, SDM625, SDM632, APQ8053).

Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
---
 drivers/remoteproc/qcom_q6v5_pas.c | 31 ++++++++++++++++++++++++++++++
 1 file changed, 31 insertions(+)

diff --git a/drivers/remoteproc/qcom_q6v5_pas.c b/drivers/remoteproc/qcom_q6v5_pas.c
index 1ae47cc153e5..4dcb714a1468 100644
--- a/drivers/remoteproc/qcom_q6v5_pas.c
+++ b/drivers/remoteproc/qcom_q6v5_pas.c
@@ -617,7 +617,37 @@ static const struct adsp_data sm8350_adsp_resource = {
 	.ssctl_id = 0x14,
 };
 
+static const struct adsp_data msm8953_adsp_resource = {
+	.crash_reason_smem = 423,
+	.firmware_name = "adsp.mdt",
+	.pas_id = 1,
+	.has_aggre2_clk = false,
+	.auto_boot = true,
+	.proxy_pd_names = (char*[]){
+		"cx",
+		NULL,
+	},
+	.ssr_name = "lpass",
+	.sysmon_name = "adsp",
+	.ssctl_id = 0x14,
+};
+
 static const struct adsp_data msm8996_adsp_resource = {
+	.crash_reason_smem = 423,
+	.firmware_name = "adsp.mdt",
+	.pas_id = 1,
+	.has_aggre2_clk = false,
+	.auto_boot = true,
+	.proxy_pd_names = (char*[]){
+		"cx",
+		NULL,
+	},
+	.ssr_name = "lpass",
+	.sysmon_name = "adsp",
+	.ssctl_id = 0x14,
+};
+
+static const struct adsp_data msm8998_adsp_resource = {
 		.crash_reason_smem = 423,
 		.firmware_name = "adsp.mdt",
 		.pas_id = 1,
@@ -850,6 +880,7 @@ static const struct adsp_data sdx55_mpss_resource = {
 static const struct of_device_id adsp_of_match[] = {
 	{ .compatible = "qcom,msm8974-adsp-pil", .data = &adsp_resource_init},
 	{ .compatible = "qcom,msm8996-adsp-pil", .data = &msm8996_adsp_resource},
+	{ .compatible = "qcom,msm8953-adsp-pil", .data = &msm8953_adsp_resource},
 	{ .compatible = "qcom,msm8996-slpi-pil", .data = &slpi_resource_init},
 	{ .compatible = "qcom,msm8998-adsp-pas", .data = &msm8996_adsp_resource},
 	{ .compatible = "qcom,msm8998-slpi-pas", .data = &slpi_resource_init},
-- 
2.36.0


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

* [PATCH 2/9] remoteproc: qcom: q6v5-mss: Add modem support on MSM8953
  2022-05-11 16:15 [PATCH 0/9] Add support for remoteprocs on the MSM8953 platform Sireesh Kodali
  2022-05-11 16:15 ` [PATCH 1/9] remoteproc: qcom: pas: Add MSM8953 ADSP PIL support Sireesh Kodali
@ 2022-05-11 16:15 ` Sireesh Kodali
  2022-05-11 16:54   ` Dmitry Baryshkov
  2022-05-11 16:15 ` [PATCH 3/9] remoteproc: qcom: qcom_wcnss: Add support for pronto-v3 Sireesh Kodali
                   ` (6 subsequent siblings)
  8 siblings, 1 reply; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-11 16:15 UTC (permalink / raw)
  To: linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Sireesh Kodali,
	Andy Gross, Mathieu Poirier

The modem on the MSM8953 platform is similar to the modem on the MSM8996
platform in terms of set up. It differs primarily in the way it needs SCM
to bless the MPSS firmware region.

Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
---
 drivers/remoteproc/qcom_q6v5_mss.c | 64 +++++++++++++++++++++++++++---
 1 file changed, 58 insertions(+), 6 deletions(-)

diff --git a/drivers/remoteproc/qcom_q6v5_mss.c b/drivers/remoteproc/qcom_q6v5_mss.c
index af217de75e4d..a73fdcddeda4 100644
--- a/drivers/remoteproc/qcom_q6v5_mss.c
+++ b/drivers/remoteproc/qcom_q6v5_mss.c
@@ -234,6 +234,7 @@ struct q6v5 {
 
 enum {
 	MSS_MSM8916,
+	MSS_MSM8953,
 	MSS_MSM8974,
 	MSS_MSM8996,
 	MSS_MSM8998,
@@ -687,12 +688,14 @@ static int q6v5proc_reset(struct q6v5 *qproc)
 		}
 		goto pbl_wait;
 	} else if (qproc->version == MSS_MSM8996 ||
-		   qproc->version == MSS_MSM8998) {
+		   qproc->version == MSS_MSM8998 ||
+		   qproc->version == MSS_MSM8953) {
 		int mem_pwr_ctl;
 
 		/* Override the ACC value if required */
-		writel(QDSP6SS_ACC_OVERRIDE_VAL,
-		       qproc->reg_base + QDSP6SS_STRAP_ACC);
+		if (qproc->version != MSS_MSM8953)
+			writel(QDSP6SS_ACC_OVERRIDE_VAL,
+					qproc->reg_base + QDSP6SS_STRAP_ACC);
 
 		/* Assert resets, stop core */
 		val = readl(qproc->reg_base + QDSP6SS_RESET_REG);
@@ -734,7 +737,8 @@ static int q6v5proc_reset(struct q6v5 *qproc)
 		writel(val, qproc->reg_base + QDSP6SS_PWR_CTL_REG);
 
 		/* Turn on L1, L2, ETB and JU memories 1 at a time */
-		if (qproc->version == MSS_MSM8996) {
+		if (qproc->version == MSS_MSM8996 ||
+			qproc->version == MSS_MSM8953) {
 			mem_pwr_ctl = QDSP6SS_MEM_PWR_CTL;
 			i = 19;
 		} else {
@@ -1314,7 +1318,16 @@ static int q6v5_mpss_load(struct q6v5 *qproc)
 			max_addr = ALIGN(phdr->p_paddr + phdr->p_memsz, SZ_4K);
 	}
 
-	/*
+	if (qproc->version == MSS_MSM8953) {
+		ret = qcom_scm_pas_mem_setup(5, qproc->mpss_phys, qproc->mpss_size);
+		if (ret) {
+			dev_err(qproc->dev,
+					"setting up mpss memory failed: %d\n", ret);
+			goto release_firmware;
+		}
+	}
+
+	/**
 	 * In case of a modem subsystem restart on secure devices, the modem
 	 * memory can be reclaimed only after MBA is loaded.
 	 */
@@ -1413,7 +1426,6 @@ static int q6v5_mpss_load(struct q6v5 *qproc)
 			writel(RMB_CMD_LOAD_READY, qproc->rmb_base + RMB_MBA_COMMAND_REG);
 		}
 		writel(size, qproc->rmb_base + RMB_PMI_CODE_LENGTH_REG);
-
 		ret = readl(qproc->rmb_base + RMB_MBA_STATUS_REG);
 		if (ret < 0) {
 			dev_err(qproc->dev, "MPSS authentication failed: %d\n",
@@ -1422,6 +1434,7 @@ static int q6v5_mpss_load(struct q6v5 *qproc)
 		}
 	}
 
+
 	/* Transfer ownership of modem ddr region to q6 */
 	ret = q6v5_xfer_mem_ownership(qproc, &qproc->mpss_perm, false, true,
 				      qproc->mpss_phys, qproc->mpss_size);
@@ -2198,6 +2211,44 @@ static const struct rproc_hexagon_res msm8996_mss = {
 	.version = MSS_MSM8996,
 };
 
+static const struct rproc_hexagon_res msm8953_mss = {
+	.hexagon_mba_image = "mba.mbn",
+	.proxy_supply = (struct qcom_mss_reg_res[]) {
+		{
+			.supply = "pll",
+			.uA = 100000,
+		},
+		{}
+	},
+	.proxy_pd_names = (char*[]) {
+			"cx",
+			"mx",
+			NULL
+	},
+	.active_supply = (struct qcom_mss_reg_res[]) {
+		{
+			.supply = "mss",
+			.uV = 1050000,
+			.uA = 100000,
+		},
+		{}
+	},
+	.proxy_clk_names = (char*[]){
+			"xo",
+			NULL
+	},
+	.active_clk_names = (char*[]){
+			"iface",
+			"bus",
+			"mem",
+			NULL
+	},
+	.need_mem_protection = false,
+	.has_alt_reset = false,
+	.has_spare_reg = false,
+	.version = MSS_MSM8953,
+};
+
 static const struct rproc_hexagon_res msm8916_mss = {
 	.hexagon_mba_image = "mba.mbn",
 	.proxy_supply = (struct qcom_mss_reg_res[]) {
@@ -2301,6 +2352,7 @@ static const struct of_device_id q6v5_of_match[] = {
 	{ .compatible = "qcom,msm8916-mss-pil", .data = &msm8916_mss},
 	{ .compatible = "qcom,msm8974-mss-pil", .data = &msm8974_mss},
 	{ .compatible = "qcom,msm8996-mss-pil", .data = &msm8996_mss},
+	{ .compatible = "qcom,msm8953-mss-pil", .data = &msm8953_mss},
 	{ .compatible = "qcom,msm8998-mss-pil", .data = &msm8998_mss},
 	{ .compatible = "qcom,sc7180-mss-pil", .data = &sc7180_mss},
 	{ .compatible = "qcom,sc7280-mss-pil", .data = &sc7280_mss},
-- 
2.36.0


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

* [PATCH 3/9] remoteproc: qcom: qcom_wcnss: Add support for pronto-v3
  2022-05-11 16:15 [PATCH 0/9] Add support for remoteprocs on the MSM8953 platform Sireesh Kodali
  2022-05-11 16:15 ` [PATCH 1/9] remoteproc: qcom: pas: Add MSM8953 ADSP PIL support Sireesh Kodali
  2022-05-11 16:15 ` [PATCH 2/9] remoteproc: qcom: q6v5-mss: Add modem support on MSM8953 Sireesh Kodali
@ 2022-05-11 16:15 ` Sireesh Kodali
  2022-05-11 16:15 ` [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML Sireesh Kodali
                   ` (5 subsequent siblings)
  8 siblings, 0 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-11 16:15 UTC (permalink / raw)
  To: linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Vladimir Lypak,
	Sireesh Kodali, Andy Gross, Mathieu Poirier

From: Vladimir Lypak <vladimir.lypak@gmail.com>

Pronto-v3 is similar to pronto-v2. It requires two power domains, and it
requires the xo clock. It is used on the MSM8953 platform.

Signed-off-by: Vladimir Lypak <vladimir.lypak@gmail.com>
Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
---
 drivers/remoteproc/qcom_wcnss.c | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/drivers/remoteproc/qcom_wcnss.c b/drivers/remoteproc/qcom_wcnss.c
index 9a223d394087..add792d752ba 100644
--- a/drivers/remoteproc/qcom_wcnss.c
+++ b/drivers/remoteproc/qcom_wcnss.c
@@ -141,6 +141,18 @@ static const struct wcnss_data pronto_v2_data = {
 	.num_vregs = 1,
 };
 
+static const struct wcnss_data pronto_v3_data = {
+	.pmu_offset = 0x1004,
+	.spare_offset = 0x1088,
+
+	.pd_names = { "mx", "cx" },
+	.vregs = (struct wcnss_vreg_info[]) {
+		{ "vddpx", 1800000, 1800000, 0 },
+	},
+	.num_pd_vregs = 2,
+	.num_vregs = 1,
+};
+
 static int wcnss_load(struct rproc *rproc, const struct firmware *fw)
 {
 	struct qcom_wcnss *wcnss = (struct qcom_wcnss *)rproc->priv;
@@ -669,6 +681,7 @@ static const struct of_device_id wcnss_of_match[] = {
 	{ .compatible = "qcom,riva-pil", &riva_data },
 	{ .compatible = "qcom,pronto-v1-pil", &pronto_v1_data },
 	{ .compatible = "qcom,pronto-v2-pil", &pronto_v2_data },
+	{ .compatible = "qcom,pronto-v3-pil", &pronto_v3_data },
 	{ },
 };
 MODULE_DEVICE_TABLE(of, wcnss_of_match);
-- 
2.36.0


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

* [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML
  2022-05-11 16:15 [PATCH 0/9] Add support for remoteprocs on the MSM8953 platform Sireesh Kodali
                   ` (2 preceding siblings ...)
  2022-05-11 16:15 ` [PATCH 3/9] remoteproc: qcom: qcom_wcnss: Add support for pronto-v3 Sireesh Kodali
@ 2022-05-11 16:15 ` Sireesh Kodali
  2022-05-11 17:15   ` Krzysztof Kozlowski
                     ` (2 more replies)
  2022-05-11 16:15 ` [PATCH 5/9] dt-bindings: remoteproc: qcom: wcnss: Add compatible for pronto v3 Sireesh Kodali
                   ` (4 subsequent siblings)
  8 siblings, 3 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-11 16:15 UTC (permalink / raw)
  To: linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Sireesh Kodali,
	Andy Gross, Mathieu Poirier, Rob Herring, Krzysztof Kozlowski

Convert the dt-bindings from txt to YAML. This is in preparation for
including the relevant bindings for the MSM8953 platform's wcnss pil.

Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
---
 .../bindings/remoteproc/qcom,wcnss-pil.txt    | 177 --------------
 .../bindings/remoteproc/qcom,wcnss-pil.yaml   | 228 ++++++++++++++++++
 2 files changed, 228 insertions(+), 177 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.txt
 create mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.yaml

diff --git a/Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.txt b/Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.txt
deleted file mode 100644
index a83080b8905c..000000000000
--- a/Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.txt
+++ /dev/null
@@ -1,177 +0,0 @@
-Qualcomm WCNSS Peripheral Image Loader
-
-This document defines the binding for a component that loads and boots firmware
-on the Qualcomm WCNSS core.
-
-- compatible:
-	Usage: required
-	Value type: <string>
-	Definition: must be one of:
-		    "qcom,riva-pil",
-		    "qcom,pronto-v1-pil",
-		    "qcom,pronto-v2-pil"
-
-- reg:
-	Usage: required
-	Value type: <prop-encoded-array>
-	Definition: must specify the base address and size of the CCU, DXE and
-		    PMU register blocks
-
-- reg-names:
-	Usage: required
-	Value type: <stringlist>
-	Definition: must be "ccu", "dxe", "pmu"
-
-- interrupts-extended:
-	Usage: required
-	Value type: <prop-encoded-array>
-	Definition: must list the watchdog and fatal IRQs and may specify the
-		    ready, handover and stop-ack IRQs
-
-- interrupt-names:
-	Usage: required
-	Value type: <stringlist>
-	Definition: should be "wdog", "fatal", optionally followed by "ready",
-		    "handover", "stop-ack"
-
-- firmware-name:
-	Usage: optional
-	Value type: <string>
-	Definition: must list the relative firmware image path for the
-		    WCNSS core. Defaults to "wcnss.mdt".
-
-- vddmx-supply: (deprecated for qcom,pronto-v1/2-pil)
-- vddcx-supply: (deprecated for qcom,pronto-v1/2-pil)
-- vddpx-supply:
-	Usage: required
-	Value type: <phandle>
-	Definition: reference to the regulators to be held on behalf of the
-		    booting of the WCNSS core
-
-- power-domains:
-	Usage: required (for qcom,pronto-v1/2-pil)
-	Value type: <phandle>
-	Definition: reference to the power domains to be held on behalf of the
-		    booting of the WCNSS core
-
-- power-domain-names:
-	Usage: required (for qcom,pronto-v1/2-pil)
-	Value type: <stringlist>
-	Definition: must be "cx", "mx"
-
-- qcom,smem-states:
-	Usage: optional
-	Value type: <prop-encoded-array>
-	Definition: reference to the SMEM state used to indicate to WCNSS that
-		    it should shut down
-
-- qcom,smem-state-names:
-	Usage: optional
-	Value type: <stringlist>
-	Definition: should be "stop"
-
-- memory-region:
-	Usage: required
-	Value type: <prop-encoded-array>
-	Definition: reference to reserved-memory node for the remote processor
-		    see ../reserved-memory/reserved-memory.txt
-
-= SUBNODES
-A required subnode of the WCNSS PIL is used to describe the attached rf module
-and its resource dependencies. It is described by the following properties:
-
-- compatible:
-	Usage: required
-	Value type: <string>
-	Definition: must be one of:
-		    "qcom,wcn3620",
-		    "qcom,wcn3660",
-		    "qcom,wcn3660b",
-		    "qcom,wcn3680"
-
-- clocks:
-	Usage: required
-	Value type: <prop-encoded-array>
-	Definition: should specify the xo clock and optionally the rf clock
-
-- clock-names:
-	Usage: required
-	Value type: <stringlist>
-	Definition: should be "xo", optionally followed by "rf"
-
-- vddxo-supply:
-- vddrfa-supply:
-- vddpa-supply:
-- vdddig-supply:
-	Usage: required
-	Value type: <phandle>
-	Definition: reference to the regulators to be held on behalf of the
-		    booting of the WCNSS core
-
-
-The wcnss node can also have an subnode named "smd-edge" that describes the SMD
-edge, channels and devices related to the WCNSS.
-See ../soc/qcom/qcom,smd.txt for details on how to describe the SMD edge.
-
-= EXAMPLE
-The following example describes the resources needed to boot control the WCNSS,
-with attached WCN3680, as it is commonly found on MSM8974 boards.
-
-pronto@fb204000 {
-	compatible = "qcom,pronto-v2-pil";
-	reg = <0xfb204000 0x2000>, <0xfb202000 0x1000>, <0xfb21b000 0x3000>;
-	reg-names = "ccu", "dxe", "pmu";
-
-	interrupts-extended = <&intc 0 149 1>,
-			      <&wcnss_smp2p_slave 0 0>,
-			      <&wcnss_smp2p_slave 1 0>,
-			      <&wcnss_smp2p_slave 2 0>,
-			      <&wcnss_smp2p_slave 3 0>;
-	interrupt-names = "wdog", "fatal", "ready", "handover", "stop-ack";
-
-	power-domains = <&rpmpd MSM8974_VDDCX>, <&rpmpd MSM8974_VDDMX>;
-	power-domain-names = "cx", "mx";
-
-	vddpx-supply = <&pm8941_s3>;
-
-	qcom,smem-states = <&wcnss_smp2p_out 0>;
-	qcom,smem-state-names = "stop";
-
-	memory-region = <&wcnss_region>;
-
-	pinctrl-names = "default";
-	pinctrl-0 = <&wcnss_pin_a>;
-
-	iris {
-		compatible = "qcom,wcn3680";
-
-		clocks = <&rpmcc RPM_CXO_CLK_SRC>, <&rpmcc RPM_CXO_A2>;
-		clock-names = "xo", "rf";
-
-		vddxo-supply = <&pm8941_l6>;
-		vddrfa-supply = <&pm8941_l11>;
-		vddpa-supply = <&pm8941_l19>;
-		vdddig-supply = <&pm8941_s3>;
-	};
-
-	smd-edge {
-		interrupts = <0 142 1>;
-
-		qcom,ipc = <&apcs 8 17>;
-		qcom,smd-edge = <6>;
-		qcom,remote-pid = <4>;
-
-		label = "pronto";
-
-		wcnss {
-			compatible = "qcom,wcnss";
-			qcom,smd-channels = "WCNSS_CTRL";
-
-			qcom,mmio = <&pronto>;
-
-			bt {
-				compatible = "qcom,wcnss-bt";
-			};
-		};
-	};
-};
diff --git a/Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.yaml b/Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.yaml
new file mode 100644
index 000000000000..d19f9f87a3e3
--- /dev/null
+++ b/Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.yaml
@@ -0,0 +1,228 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/remoteproc/qcom,wcnss-pil.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Qualcomm WCNSS Peripheral Image Loader
+
+maintainers:
+  - Bjorn Andersson <bjorn.andersson@linaro.org>
+
+description:
+  This document defines the binding for a component that loads and boots
+  firmware on the Qualcomm WCNSS core.
+
+properties:
+  compatible:
+    oneOf:
+      - items:
+          - enum:
+              - qcom,pronto-v2-pil
+          - enum:
+              - qcom,pronto
+      - items:
+          - enum:
+              - qcom,riva-pil
+              - qcom,pronto-v1-pil
+              - qcom,pronto-v2-pil
+
+  reg:
+    description: must specify the base address and size of the CCU, DXE and PMU
+      register blocks
+
+  reg-names:
+    items:
+      - const: ccu
+      - const: dxe
+      - const: pmu
+
+  interrupts-extended:
+    description:
+      Interrupt lines
+    minItems: 2
+    maxItems: 5
+
+  interrupt-names:
+    minItems: 2
+    maxItems: 5
+
+  firmware-name:
+    $ref: /schemas/types.yaml#/definitions/string
+    description: Relative firmware image path for the WCNSS core. Defaults to
+      "wcnss.mdt".
+
+  vddpx-supply:
+    description: Reference to the PX regulator to be held on behalf of the
+      booting of the WCNSS core
+
+  vddmx-supply:
+    description: Reference to the MX regulator to be held on behalf of the
+      booting of the WCNSS core.
+
+  vddcx-supply:
+    description: Reference to the CX regulator to be held on behalf of the
+      booting of the WCNSS core.
+
+  power-domains:
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    description: References to the power domains that need to be held on
+      behalf of the booting WCNSS core
+
+  power-domain-names:
+    $ref: /schemas/types.yaml#/definitions/string-array
+    description: Names of the power domains
+    items:
+      - const: cx
+      - const: mx
+
+  qcom,smem-states:
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    description: States used by the AP to signal the WCNSS core that it should
+      shutdown
+    items:
+      - description: Stop the modem
+
+  qcom,smem-state-names:
+    $ref: /schemas/types.yaml#/definitions/string-array
+    description: The names of the state bits used for SMP2P output
+    items:
+      - const: stop
+
+  memory-region:
+    maxItems: 1
+    description: Reference to the reserved-memory for the WCNSS core
+
+  smd-edge:
+    type: object
+    description:
+      Qualcomm Shared Memory subnode which represents communication edge,
+      channels and devices related to the ADSP.
+
+  iris:
+    type: object
+    description:
+      The iris subnode of the WCNSS PIL is used to describe the attached rf module
+      and its resource dependencies.
+
+    properties:
+      compatible:
+        enum:
+          - qcom,wcn3620
+          - qcom,wcn3660
+          - qcom,wcn3660b
+          - qcom,wcn3680
+
+      clocks:
+        description: XO clock
+
+      clock-names:
+        items:
+          - const: xo
+
+    required:
+      - compatible
+
+required:
+  - compatible
+  - reg
+  - reg-names
+  - interrupts-extended
+  - interrupt-names
+  - vddpx-supply
+  - memory-region
+  - smd-edge
+  - iris
+
+additionalProperties: false
+
+if:
+  properties:
+    compatible:
+      contains:
+        enum:
+          - qcom,pronto-v1-pil
+          - qcom,pronto-v2-pil
+then:
+  properties:
+    vddmx-supply:
+      deprecated: true
+      description: Deprecated for qcom,pronto-v1/2-pil
+
+    vddcx-supply:
+      deprecated: true
+      description: Deprecated for qcom,pronto-v1/2-pil
+
+  required:
+    - power-domains
+    - power-domain-names
+
+examples:
+  - |
+    #include <dt-bindings/interrupt-controller/arm-gic.h>
+    #include <dt-bindings/clock/qcom,rpmcc.h>
+    #include <dt-bindings/power/qcom-rpmpd.h>
+    pronto@a21b000 {
+        compatible = "qcom,pronto-v2-pil";
+        reg = <0x0a204000 0x2000>, <0x0a202000 0x1000>, <0x0a21b000 0x3000>;
+        reg-names = "ccu", "dxe", "pmu";
+
+        interrupts-extended = <&intc GIC_SPI 149 IRQ_TYPE_EDGE_RISING>,
+                              <&wcnss_smp2p_in 0 IRQ_TYPE_EDGE_RISING>,
+                              <&wcnss_smp2p_in 1 IRQ_TYPE_EDGE_RISING>,
+                              <&wcnss_smp2p_in 2 IRQ_TYPE_EDGE_RISING>,
+                              <&wcnss_smp2p_in 3 IRQ_TYPE_EDGE_RISING>;
+        interrupt-names = "wdog", "fatal", "ready", "handover", "stop-ack";
+
+        power-domains = <&rpmpd MSM8916_VDDCX>, <&rpmpd MSM8916_VDDMX>;
+        power-domain-names = "cx", "mx";
+
+        vddpx-supply = <&pm8916_l7>;
+
+        qcom,smem-states = <&wcnss_smp2p_out 0>;
+        qcom,smem-state-names = "stop";
+
+        memory-region = <&wcnss_region>;
+
+        pinctrl-names = "default";
+        pinctrl-0 = <&wcnss_pin_a>;
+
+        iris {
+            compatible = "qcom,wcn3620";
+
+            clocks = <&rpmcc RPM_SMD_RF_CLK2>;
+            clock-names = "xo";
+        };
+
+        smd-edge {
+            interrupts = <GIC_SPI 142 IRQ_TYPE_EDGE_RISING>;
+
+            qcom,ipc = <&apcs 8 17>;
+            qcom,smd-edge = <6>;
+            qcom,remote-pid = <4>;
+
+            label = "pronto";
+
+            wcnss {
+                compatible = "qcom,wcnss";
+                qcom,smd-channels = "WCNSS_CTRL";
+
+                qcom,mmio = <&pronto>;
+
+                bt {
+                    compatible = "qcom,wcnss-bt";
+                };
+
+                wifi {
+                    compatible = "qcom,wcnss-wlan";
+
+                    interrupts = <GIC_SPI 145 IRQ_TYPE_LEVEL_HIGH>,
+                                 <GIC_SPI 146 IRQ_TYPE_LEVEL_HIGH>;
+                    interrupt-names = "tx", "rx";
+
+                    qcom,smem-states = <&apps_smsm 10>, <&apps_smsm 9>;
+                    qcom,smem-state-names = "tx-enable", "tx-rings-empty";
+                };
+            };
+        };
+    };
-- 
2.36.0


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

* [PATCH 5/9] dt-bindings: remoteproc: qcom: wcnss: Add compatible for pronto v3
  2022-05-11 16:15 [PATCH 0/9] Add support for remoteprocs on the MSM8953 platform Sireesh Kodali
                   ` (3 preceding siblings ...)
  2022-05-11 16:15 ` [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML Sireesh Kodali
@ 2022-05-11 16:15 ` Sireesh Kodali
  2022-05-11 16:15 ` [PATCH 6/9] dt-bindings: remoteproc: qcom: mss: Convert bindings to YAML Sireesh Kodali
                   ` (3 subsequent siblings)
  8 siblings, 0 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-11 16:15 UTC (permalink / raw)
  To: linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Sireesh Kodali,
	Andy Gross, Mathieu Poirier, Rob Herring, Krzysztof Kozlowski

The pronto v3 remoteproc is similar to pronto v2. It is found on the
MSM8953 platform, which is used by SDM450, SDM625, SDM626, APQ8053 and
other SoCs. Since the configuration is same on all SoCs, a single
compatible is used.

Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
---
 .../devicetree/bindings/remoteproc/qcom,wcnss-pil.yaml      | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.yaml b/Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.yaml
index d19f9f87a3e3..89bef16f153d 100644
--- a/Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.yaml
+++ b/Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.yaml
@@ -26,6 +26,7 @@ properties:
               - qcom,riva-pil
               - qcom,pronto-v1-pil
               - qcom,pronto-v2-pil
+              - qcom,pronto-v3-pil
 
   reg:
     description: must specify the base address and size of the CCU, DXE and PMU
@@ -143,15 +144,16 @@ if:
         enum:
           - qcom,pronto-v1-pil
           - qcom,pronto-v2-pil
+          - qcom,pronto-v3-pil
 then:
   properties:
     vddmx-supply:
       deprecated: true
-      description: Deprecated for qcom,pronto-v1/2-pil
+      description: Deprecated for qcom,pronto-v1/2/3-pil
 
     vddcx-supply:
       deprecated: true
-      description: Deprecated for qcom,pronto-v1/2-pil
+      description: Deprecated for qcom,pronto-v1/2/3-pil
 
   required:
     - power-domains
-- 
2.36.0


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

* [PATCH 6/9] dt-bindings: remoteproc: qcom: mss: Convert bindings to YAML
  2022-05-11 16:15 [PATCH 0/9] Add support for remoteprocs on the MSM8953 platform Sireesh Kodali
                   ` (4 preceding siblings ...)
  2022-05-11 16:15 ` [PATCH 5/9] dt-bindings: remoteproc: qcom: wcnss: Add compatible for pronto v3 Sireesh Kodali
@ 2022-05-11 16:15 ` Sireesh Kodali
  2022-05-11 17:50   ` Krzysztof Kozlowski
  2022-05-12 13:49   ` Rob Herring
  2022-05-11 16:16 ` [PATCH 7/9] dt-bindings: remoteproc: qcom: mss: Add MSS on MSM8953 Sireesh Kodali
                   ` (2 subsequent siblings)
  8 siblings, 2 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-11 16:15 UTC (permalink / raw)
  To: linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Sireesh Kodali,
	Andy Gross, Mathieu Poirier, Rob Herring, Krzysztof Kozlowski

Convert the bindings to YAML from txt. The bindings follow a similar
schema to `qcom,adsp.yaml`.

Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
---
 .../bindings/remoteproc/qcom,q6v5.txt         | 302 --------
 .../bindings/remoteproc/qcom,q6v5.yaml        | 702 ++++++++++++++++++
 2 files changed, 702 insertions(+), 302 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,q6v5.txt
 create mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,q6v5.yaml

diff --git a/Documentation/devicetree/bindings/remoteproc/qcom,q6v5.txt b/Documentation/devicetree/bindings/remoteproc/qcom,q6v5.txt
deleted file mode 100644
index 8f1507052afd..000000000000
--- a/Documentation/devicetree/bindings/remoteproc/qcom,q6v5.txt
+++ /dev/null
@@ -1,302 +0,0 @@
-Qualcomm Hexagon Peripheral Image Loader
-
-This document defines the binding for a component that loads and boots firmware
-on the Qualcomm Hexagon core.
-
-- compatible:
-	Usage: required
-	Value type: <string>
-	Definition: must be one of:
-		    "qcom,q6v5-pil",
-		    "qcom,ipq8074-wcss-pil"
-		    "qcom,qcs404-wcss-pil"
-		    "qcom,msm8916-mss-pil",
-		    "qcom,msm8974-mss-pil"
-		    "qcom,msm8996-mss-pil"
-		    "qcom,msm8998-mss-pil"
-		    "qcom,sc7180-mss-pil"
-		    "qcom,sc7280-mss-pil"
-		    "qcom,sdm845-mss-pil"
-
-- reg:
-	Usage: required
-	Value type: <prop-encoded-array>
-	Definition: must specify the base address and size of the qdsp6 and
-		    rmb register blocks
-
-- reg-names:
-	Usage: required
-	Value type: <stringlist>
-	Definition: must be "q6dsp" and "rmb"
-
-- interrupts-extended:
-	Usage: required
-	Value type: <prop-encoded-array>
-	Definition: reference to the interrupts that match interrupt-names
-
-- interrupt-names:
-	Usage: required
-	Value type: <stringlist>
-	Definition: The interrupts needed depends on the the compatible
-		    string:
-	qcom,q6v5-pil:
-	qcom,ipq8074-wcss-pil:
-	qcom,qcs404-wcss-pil:
-	qcom,msm8916-mss-pil:
-	qcom,msm8974-mss-pil:
-		    must be "wdog", "fatal", "ready", "handover", "stop-ack"
-	qcom,msm8996-mss-pil:
-	qcom,msm8998-mss-pil:
-	qcom,sc7180-mss-pil:
-	qcom,sc7280-mss-pil:
-	qcom,sdm845-mss-pil:
-		    must be "wdog", "fatal", "ready", "handover", "stop-ack",
-		    "shutdown-ack"
-
-- firmware-name:
-	Usage: optional
-	Value type: <stringlist>
-	Definition: must list the relative firmware image paths for mba and
-		    modem. They are used for booting and authenticating the
-		    Hexagon core.
-
-- clocks:
-	Usage: required
-	Value type: <phandle>
-	Definition: reference to the clocks that match clock-names
-
-- clock-names:
-	Usage: required
-	Value type: <stringlist>
-	Definition: The clocks needed depend on the compatible string:
-	qcom,ipq8074-wcss-pil:
-		    no clock names required
-	qcom,qcs404-wcss-pil:
-		    must be "xo", "gcc_abhs_cbcr", "gcc_abhs_cbcr",
-		    "gcc_axim_cbcr", "lcc_ahbfabric_cbc", "tcsr_lcc_cbc",
-		    "lcc_abhs_cbc", "lcc_tcm_slave_cbc", "lcc_abhm_cbc",
-		    "lcc_axim_cbc", "lcc_bcr_sleep"
-	qcom,q6v5-pil:
-	qcom,msm8916-mss-pil:
-	qcom,msm8974-mss-pil:
-		    must be "iface", "bus", "mem", "xo"
-	qcom,msm8996-mss-pil:
-		    must be "iface", "bus", "mem", "xo", "gpll0_mss",
-		    "snoc_axi", "mnoc_axi", "pnoc", "qdss"
-	qcom,msm8998-mss-pil:
-		    must be "iface", "bus", "mem", "xo", "gpll0_mss",
-		    "snoc_axi", "mnoc_axi", "qdss"
-	qcom,sc7180-mss-pil:
-		    must be "iface", "bus", "xo", "snoc_axi", "mnoc_axi",
-		    "nav"
-	qcom,sc7280-mss-pil:
-		    must be "iface", "xo", "snoc_axi", "offline", "pka"
-	qcom,sdm845-mss-pil:
-		    must be "iface", "bus", "mem", "xo", "gpll0_mss",
-		    "snoc_axi", "mnoc_axi", "prng"
-
-- resets:
-	Usage: required
-	Value type: <phandle>
-	Definition: reference to the reset-controller for the modem sub-system
-		    reference to the list of 3 reset-controllers for the
-		    wcss sub-system
-		    reference to the list of 2 reset-controllers for the modem
-		    sub-system on SC7180, SC7280, SDM845 SoCs
-
-- reset-names:
-	Usage: required
-	Value type: <stringlist>
-	Definition: must be "mss_restart" for the modem sub-system
-		    must be "wcss_aon_reset", "wcss_reset", "wcss_q6_reset"
-		    for the wcss sub-system
-		    must be "mss_restart", "pdc_reset" for the modem
-		    sub-system on SC7180, SC7280, SDM845 SoCs
-
-For devices where the mba and mpss sub-nodes are not specified, mba/mpss region
-should be referenced as follows:
-- memory-region:
-	Usage: required
-	Value type: <phandle>
-	Definition: reference to the reserved-memory for the mba region followed
-		    by the mpss region
-
-For the compatible strings below the following supplies are required:
-  "qcom,q6v5-pil"
-  "qcom,msm8916-mss-pil",
-- cx-supply: (deprecated, use power domain instead)
-- mx-supply: (deprecated, use power domain instead)
-- pll-supply:
-	Usage: required
-	Value type: <phandle>
-	Definition: reference to the regulators to be held on behalf of the
-		    booting of the Hexagon core
-
-For the compatible string below the following supplies are required:
-  "qcom,msm8974-mss-pil"
-- cx-supply: (deprecated, use power domain instead)
-- mss-supply:
-- mx-supply: (deprecated, use power domain instead)
-- pll-supply:
-	Usage: required
-	Value type: <phandle>
-	Definition: reference to the regulators to be held on behalf of the
-		    booting of the Hexagon core
-
-For the compatible string below the following supplies are required:
-  "qcom,qcs404-wcss-pil"
-- cx-supply:
-	Usage: required
-	Value type: <phandle>
-	Definition: reference to the regulators to be held on behalf of the
-		    booting of the Hexagon core
-
-For the compatible string below the following supplies are required:
-  "qcom,msm8996-mss-pil"
-- pll-supply:
-	Usage: required
-	Value type: <phandle>
-	Definition: reference to the regulators to be held on behalf of the
-		    booting of the Hexagon core
-
-- power-domains:
-	Usage: required
-	Value type: <phandle>
-	Definition: reference to power-domains that match power-domain-names
-
-- power-domain-names:
-	Usage: required
-	Value type: <stringlist>
-	Definition: The power-domains needed depend on the compatible string:
-	qcom,ipq8074-wcss-pil:
-		    no power-domain names required
-	qcom,q6v5-pil:
-	qcom,msm8916-mss-pil:
-	qcom,msm8974-mss-pil:
-	qcom,msm8996-mss-pil:
-	qcom,msm8998-mss-pil:
-		    must be "cx", "mx"
-	qcom,sc7180-mss-pil:
-		    must be "cx", "mx", "mss"
-	qcom,sc7280-mss-pil:
-		    must be "cx", "mss"
-	qcom,sdm845-mss-pil:
-		    must be "cx", "mx", "mss"
-
-- qcom,qmp:
-	Usage: optional
-	Value type: <phandle>
-	Definition: reference to the AOSS side-channel message RAM.
-
-- qcom,smem-states:
-	Usage: required
-	Value type: <phandle>
-	Definition: reference to the smem state for requesting the Hexagon to
-		    shut down
-
-- qcom,smem-state-names:
-	Usage: required
-	Value type: <stringlist>
-	Definition: must be "stop"
-
-- qcom,halt-regs:
-	Usage: required
-	Value type: <prop-encoded-array>
-	Definition: a phandle reference to a syscon representing TCSR followed
-		    by the three offsets within syscon for q6, modem and nc
-		    halt registers.
-		    a phandle reference to a syscon representing TCSR followed
-		    by the four offsets within syscon for q6, modem, nc and vq6
-		    halt registers on SC7280 SoCs.
-
-For the compatible strings below the following phandle references are required:
-  "qcom,sc7180-mss-pil"
-- qcom,spare-regs:
-	Usage: required
-	Value type: <prop-encoded-array>
-	Definition: a phandle reference to a syscon representing TCSR followed
-		    by the offset within syscon for conn_box_spare0 register
-		    used by the modem sub-system running on SC7180 SoC.
-
-For the compatible strings below the following phandle references are required:
-  "qcom,sc7280-mss-pil"
-- qcom,ext-regs:
-	Usage: required
-	Value type: <prop-encoded-array>
-	Definition: two phandle references to syscons representing TCSR_REG and
-		    TCSR register space followed by the two offsets within the syscon
-		    to force_clk_en/rscc_disable and axim1_clk_off/crypto_clk_off
-		    registers respectively.
-
-- qcom,qaccept-regs:
-	Usage: required
-	Value type: <prop-encoded-array>
-	Definition: a phandle reference to a syscon representing TCSR followed
-		    by the three offsets within syscon for mdm, cx and axi
-		    qaccept registers used by the modem sub-system running on
-		    SC7280 SoC.
-
-The Hexagon node must contain iommus property as described in ../iommu/iommu.txt
-on platforms which do not have TrustZone.
-
-= SUBNODES:
-The Hexagon node must contain two subnodes, named "mba" and "mpss" representing
-the memory regions used by the Hexagon firmware. Each sub-node must contain:
-
-- memory-region:
-	Usage: required
-	Value type: <phandle>
-	Definition: reference to the reserved-memory for the region
-
-The Hexagon node may also have an subnode named either "smd-edge" or
-"glink-edge" that describes the communication edge, channels and devices
-related to the Hexagon.  See ../soc/qcom/qcom,smd.txt and
-../soc/qcom/qcom,glink.txt for details on how to describe these.
-
-= EXAMPLE
-The following example describes the resources needed to boot control the
-Hexagon, as it is found on MSM8974 boards.
-
-	modem-rproc@fc880000 {
-		compatible = "qcom,q6v5-pil";
-		reg = <0xfc880000 0x100>,
-		      <0xfc820000 0x020>;
-		reg-names = "qdsp6", "rmb";
-
-		interrupts-extended = <&intc 0 24 1>,
-				      <&modem_smp2p_in 0 0>,
-				      <&modem_smp2p_in 1 0>,
-				      <&modem_smp2p_in 2 0>,
-				      <&modem_smp2p_in 3 0>;
-		interrupt-names = "wdog",
-				  "fatal",
-				  "ready",
-				  "handover",
-				  "stop-ack";
-
-		clocks = <&gcc GCC_MSS_Q6_BIMC_AXI_CLK>,
-			 <&gcc GCC_MSS_CFG_AHB_CLK>,
-			 <&gcc GCC_BOOT_ROM_AHB_CLK>;
-		clock-names = "iface", "bus", "mem";
-
-		qcom,halt-regs = <&tcsr_mutex_block 0x1180 0x1200 0x1280>;
-
-		resets = <&gcc GCC_MSS_RESTART>;
-		reset-names = "mss_restart";
-
-		cx-supply = <&pm8841_s2>;
-		mss-supply = <&pm8841_s3>;
-		mx-supply = <&pm8841_s1>;
-		pll-supply = <&pm8941_l12>;
-
-		qcom,smem-states = <&modem_smp2p_out 0>;
-		qcom,smem-state-names = "stop";
-
-		mba {
-			memory-region = <&mba_region>;
-		};
-
-		mpss {
-			memory-region = <&mpss_region>;
-		};
-	};
diff --git a/Documentation/devicetree/bindings/remoteproc/qcom,q6v5.yaml b/Documentation/devicetree/bindings/remoteproc/qcom,q6v5.yaml
new file mode 100644
index 000000000000..1c67c6cbf417
--- /dev/null
+++ b/Documentation/devicetree/bindings/remoteproc/qcom,q6v5.yaml
@@ -0,0 +1,702 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/remoteproc/qcom,q6v5.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Qualcomm Hexagon Peripheral Image Loader
+
+maintainers:
+  - Bjorn Andersson <bjorn.andersson@linaro.org>
+
+description:
+  This document defines the binding for a component that loads and boots firmware
+  on the Qualcomm Hexagon core.
+
+properties:
+  compatible:
+    # Special case, because older platforms like MSM8916 use both compatibles together
+    minItems: 1
+    maxItems: 2
+    oneOf:
+      - items:
+          - enum:
+              - qcom,msm8916-mss-pil
+          - enum:
+              - qcom,q6v5-pil
+      - items:
+          - enum:
+              - qcom,q6v5-pil
+              - qcom,ipq8074-wcss-pil
+              - qcom,qcs404-wcss-pil
+              - qcom,msm8916-mss-pil
+              - qcom,msm8974-mss-pil
+              - qcom,msm8996-mss-pil
+              - qcom,msm8998-mss-pil
+              - qcom,sc7180-mss-pil
+              - qcom,sc7280-mss-pil
+              - qcom,sdm845-mss-pil
+
+  reg:
+    description: must specify the base address and size of the qdsp6 and rmb
+      register blocks
+    maxItems: 2
+
+  reg-names:
+    items:
+      - const: qdsp6
+      - const: rmb
+
+  interrupts-extended:
+    minItems: 5
+    maxItems: 6
+
+  interrupt-names:
+    minItems: 5
+    maxItems: 6
+
+  firmware-name:
+    $ref: /schemas/types.yaml#/definitions/string-array
+    description: List the relative firmware image paths for the mba and
+      modem. They are used for booting and authenticating the Hexagon core.
+    maxItems: 2
+
+  clocks:
+    minItems: 4
+    maxItems: 10
+
+  clock-names:
+    minItems: 4
+    maxItems: 10
+
+  resets:
+    description: Reference to the reset-controllwer for the modem subsystem
+    minItems: 1
+    maxItems: 3
+
+  reset-names:
+    minItems: 1
+    maxItems: 3
+
+  memory-region:
+    maxItems: 1
+    description: Reference to the reserved-memory for the mba region followed
+      by the mpss region. Required if the mba and mpss sub-nodes are not
+      specified.
+
+  cx-supply:
+    description: Phandle to the CX regulator
+
+  mx-supply:
+    description: Phandle to the MX regulator
+
+  pll-supply:
+    description: Phandle to the PLL regulator, to be held on behalf of the
+      booting Hexagon core
+
+  mss-supply:
+    description: Phandle to the mss regulator, to be held on behalf of the
+      booting Hexagon core
+
+  power-domains:
+    minItems: 1
+    maxItems: 4
+
+  power-domain-names:
+    minItems: 1
+    maxItems: 4
+
+  qcom,qmp:
+    $ref: /schemas/types.yaml#/definitions/phandle
+    description: Reference to the AOSS side-channel message RAM.
+
+  qcom,smem-states:
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    description: States used by the AP to signal the Hexagon core
+    items:
+      - description: Stop the modem
+
+  qcom,smem-state-names:
+    $ref: /schemas/types.yaml#/definitions/string-array
+    description: The names of the state bits used for SMP2P output
+    items:
+      - const: stop
+
+  qcom,halt-regs:
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    description:
+      Phandle reference to a syscon representing TCSR followed by the
+      three offsets within syscon for q6, modem and nc halt registers.
+
+  qcom,spare-regs:
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    description:
+      A phandle reference to a syscon representing TCSR followed by the
+      offset within syscon for conn_box_spare0 register used by the modem
+      sub-system running on SC7180 SoC.
+
+  qcom,ext-regs:
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    description:
+      Two phandle references to syscons representing TCSR_REG and TCSR
+      register space followed by the two offsets within the syscon to
+      force_clk_en/rscc_disable and axim1_clk_off/crypto_clk_off registers
+      respectively.
+
+  qcom,qaccept-regs:
+    $ref: /schemas/types.yaml#/definitions/phandle-array
+    description:
+      A phandle reference to a syscon representing TCSR followed by the three
+      offsets within syscon for mdm, cx and axi qaccept registers used by the
+      modem sub-system running on SC7280 SoC.
+
+  iommus:
+    description:
+      Only required on platforms that do not have TrustZone.
+
+  smd-edge:
+    type: object
+    description:
+      Qualcomm Shared Memory subnode which represents communication edge,
+      channels and devices related to the ADSP.
+
+  glink-edge:
+    type: object
+    description:
+      Qualcomm G-Link subnode which represents communication edge, channels
+      and devices related to the ADSP.
+
+  mba:
+    type: object
+    properties:
+      memory-region:
+        maxItems: 1
+
+    required:
+      - memory-region
+
+  mpss:
+    type: object
+    properties:
+      memory-region:
+        maxItems: 1
+
+    required:
+      - memory-region
+
+required:
+  - compatible
+  - clocks
+  - clock-names
+  - interrupts-extended
+  - interrupt-names
+  - qcom,smem-states
+  - qcom,smem-state-names
+
+additionalProperties: false
+
+allOf:
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,ipq8074-wcss-pil
+    then:
+      properties:
+        clocks: false
+        clock-names: false
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,qcs404-wcss-pil
+    then:
+      properties:
+        clocks:
+          items:
+            - description: GCC_AHBS_CBCR clock
+            - description: GCC_AXIM_CBCR clock
+            - description: LCC_AHBFABRIC_CBC clock
+            - description: TCSR_LCC_CBC clock
+            - description: LCC_AHBS_CBC clock
+            - description: LCC_TCM_SLAVE_CBC clock
+            - description: LCC_ABHM_CBC clock
+            - description: LCC_AXIM_CBC clock
+            - description: LCC_BCR_SLEEP clock
+            - description: XO clock
+        clock-names:
+          items:
+            - const: gcc_ahbs_cbcr
+            - const: gcc_axim_cbcr
+            - const: lcc_ahbfabric_cbc
+            - const: tcsr_lcc_cbc
+            - const: lcc_abhs_cbc
+            - const: lcc_tcm_slave_cbc
+            - const: lcc_abhm_cbc
+            - const: lcc_axim_cbc
+            - const: lcc_bcr_sleep
+            - const: xo
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,q6v5-pil
+              - qcom,msm8916-mss-pil
+              - qcom,msm8974-mss-pil
+    then:
+      properties:
+        clocks:
+          items:
+            - description: Interface clock
+            - description: Bus clock
+            - description: Memory clock
+            - description: XO clock
+        clock-names:
+          items:
+            - const: iface
+            - const: bus
+            - const: mem
+            - const: xo
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,msm8996-mss-pil
+    then:
+      properties:
+        clocks:
+          items:
+            - description: Interface clock
+            - description: Bus clock
+            - description: Memory clock
+            - description: GPLL0_MSS clock
+            - description: SNOC_AXI clock
+            - description: MNOC_AXI clock
+            - description: PNOC clock
+            - description: QDSS clock
+            - description: XO clock
+        clock-names:
+          items:
+            - const: iface
+            - const: bus
+            - const: mem
+            - const: gpll0_mss
+            - const: snoc_axi
+            - const: mnoc_axi
+            - const: pnoc
+            - const: qdss
+            - const: xo
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,msm8998-mss-pil
+    then:
+      properties:
+        clocks:
+          items:
+            - description: Interface clock
+            - description: Bus clock
+            - description: Memory clock
+            - description: GPLL0_MSS clock
+            - description: SNOC_AXI clock
+            - description: MNOC_AXI clock
+            - description: QDSS clock
+            - description: XO clock
+        clock-names:
+          items:
+            - const: iface
+            - const: bus
+            - const: mem
+            - const: gpll0_mss
+            - const: snoc_axi
+            - const: mnoc_axi
+            - const: qdss
+            - const: xo
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,sc7180-mss-pil
+    then:
+      properties:
+        clocks:
+          items:
+            - description: Interface clock
+            - description: Bus clock
+            - description: NAV clock
+            - description: SNOC_AXI clock
+            - description: MNOC_AXI clock
+            - description: XO clock
+        clock-names:
+          items:
+            - const: iface
+            - const: bus
+            - const: nav
+            - const: snoc_axi
+            - const: mnoc_axi
+            - const: xo
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,sc7280-mss-pil
+    then:
+      properties:
+        clocks:
+          items:
+            - description: Interface clock
+            - description: Offline clock
+            - description: SNOC_AXI clock
+            - description: PKA clock
+            - description: XO clock
+        clock-names:
+          items:
+            - const: iface
+            - const: offline
+            - const: snoc_axi
+            - const: pka
+            - const: xo
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,sdm845-mss-pil
+    then:
+      properties:
+        clocks:
+          items:
+            - description: Interface clock
+            - description: Bus clock
+            - description: Memory clock
+            - description: GPLL0_MSS clock
+            - description: SNOC_AXI clock
+            - description: MNOC_AXI clock
+            - description: PRNG clock
+            - description: XO clock
+        clock-names:
+          items:
+            - const: iface
+            - const: bus
+            - const: mem
+            - const: gpll0_mss
+            - const: snoc_axi
+            - const: mnoc_axi
+            - const: prng
+            - const: xo
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,q6v5-pil
+              - qcom,ipq8074-wcss-pil
+              - qcom,qcs404-wcss-pil
+              - qcom,msm8916-mss-pil
+              - qcom,msm8974-mss-pil
+    then:
+      properties:
+        interrupts-extended:
+          items:
+            - description: Watchdog interrupt
+            - description: Fatal interrupt
+            - description: Ready interrupt
+            - description: Handover interrupt
+            - description: Stop acknowledge interrupt
+        interrupt-names:
+          items:
+            - const: wdog
+            - const: fatal
+            - const: ready
+            - const: handover
+            - const: stop-ack
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,msm8996-mss-pil
+              - qcom,msm8998-mss-pil
+              - qcom,sc7180-mss-pil
+              - qcom,sc7280-mss-pil
+              - qcom,sdm845-mss-pil
+    then:
+      properties:
+        interrupts-extended:
+          items:
+            - description: Watchdog interrupt
+            - description: Fatal interrupt
+            - description: Ready interrupt
+            - description: Handover interrupt
+            - description: Stop acknowledge interrupt
+            - description: Shutdown acknowledge interrupt
+        interrupt-names:
+          items:
+            - const: wdog
+            - const: fatal
+            - const: ready
+            - const: handover
+            - const: stop-ack
+            - const: shutdown-ack
+
+  - if:
+      properties:
+        compatible:
+          enum:
+            - const: qcom,q6v5-pil
+            - const: qcom,msm8916-mss-pil
+            - const: qcom,msm8974-mss-pil
+    then:
+      properties:
+        cx-supply:
+          deprecated: true
+        mx-supply:
+          deprecated: true
+
+      required:
+        - pll-supply
+
+  - if:
+      properties:
+        compatible:
+          enum:
+            - qcom,msm8916-mss-pil
+            - qcom,msm8974-mss-pil
+            - qcom,msm8996-mss-pil
+            - qcom,msm8998-mss-pil
+    then:
+      properties:
+        power-domains:
+          items:
+            - description: CX power domain
+            - description: MX power domain
+        power-domain-names:
+          items:
+            - const: cx
+            - const: mx
+
+      required:
+        - power-domains
+        - power-domain-names
+
+  - if:
+      properties:
+        compatible:
+          enum:
+            - const: qcom,msm8996-mss-pil
+    then:
+      properties:
+        cx-supply: false
+        mx-supply: false
+
+      required:
+        - pll-supply
+
+  - if:
+      properties:
+        compatible:
+          enum:
+            - const: qcom,qcs404-wcss-pil
+    then:
+      required:
+        - cx-supply
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,sdm845-mss-pil
+              - qcom,sc7180-mss-pil
+    then:
+      properties:
+        power-domains:
+          items:
+            - description: CX power domain
+            - description: MX power domain
+            - description: MSS power domain
+        power-domain-names:
+          items:
+            - const: cx
+            - const: mx
+            - const: mss
+
+      required:
+        - power-domains
+        - power-domain-names
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,sc7280-mss-pil
+    then:
+      properties:
+        power-domains:
+          items:
+            - description: CX power domain
+            - description: MSS power domain
+        power-domain-names:
+          items:
+            - const: cx
+            - const: mss
+
+      required:
+        - power-domains
+        - power-domain-names
+        - qcom,ext-regs
+        - qcom,qaccept-regs
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,q6v5-pil
+              - qcom,msm8916-mss-pil
+              - qcom,msm8974-mss-pil
+              - qcom,msm8996-mss-pil
+              - qcom,msm8998-mss-pil
+    then:
+      properties:
+        resets:
+          items:
+            - description: MSS reset
+        reset-names:
+          items:
+            - const: mss_restart
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,ipq8074-wcss-pil
+              - qcom,qcs404-wcss-pil
+    then:
+      properties:
+        resets:
+          items:
+            - description: WCSS Always On restart
+            - description: WCSS reset
+            - description: WCSS Q6 reset
+        reset-names:
+          items:
+            - const: wcss_aon_restart
+            - const: wcss_reset
+            - const: wcss_q6_reset
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,sc7180-mss-pil
+              - qcom,sc7280-mss-pil
+              - qcom,sdm845-mss-pil
+    then:
+      properties:
+        resets:
+          items:
+            - description: MSS restart
+            - description: PDC reset
+        reset-names:
+          items:
+            - const: mss_restart
+            - const: pdc_reset
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,q6v5-pil
+              - qcom,ipq8074-wcss-pil
+              - qcom,qcs404-wcss-pil
+              - qcom,msm8916-mss-pil
+              - qcom,msm8974-mss-pil
+              - qcom,msm8996-mss-pil
+              - qcom,msm8998-mss-pil
+    then:
+      properties:
+        qcom,qmp: false
+        iommus: false
+
+examples:
+  - |
+    #include <dt-bindings/clock/qcom,rpmcc.h>
+    #include <dt-bindings/interrupt-controller/irq.h>
+    #include <dt-bindings/clock/qcom,gcc-msm8974.h>
+    #include <dt-bindings/reset/qcom,gcc-msm8974.h>
+    #include <dt-bindings/interrupt-controller/arm-gic.h>
+    modem-rproc@fc880000 {
+        compatible = "qcom,q6v5-pil";
+        reg = <0xfc880000 0x100>,
+              <0xfc820000 0x020>;
+        reg-names = "qdsp6", "rmb";
+
+        interrupts-extended = <&intc GIC_SPI 24 IRQ_TYPE_EDGE_RISING>,
+                              <&modem_smp2p_in 0 IRQ_TYPE_EDGE_RISING>,
+                              <&modem_smp2p_in 1 IRQ_TYPE_EDGE_RISING>,
+                              <&modem_smp2p_in 2 IRQ_TYPE_EDGE_RISING>,
+                              <&modem_smp2p_in 3 IRQ_TYPE_EDGE_RISING>;
+        interrupt-names = "wdog",
+                          "fatal",
+                          "ready",
+                          "handover",
+                          "stop-ack";
+
+        clocks = <&gcc GCC_MSS_Q6_BIMC_AXI_CLK>,
+                 <&gcc GCC_MSS_CFG_AHB_CLK>,
+                 <&gcc GCC_BOOT_ROM_AHB_CLK>,
+                 <&xo_board>;
+        clock-names = "iface", "bus", "mem", "xo";
+
+        qcom,halt-regs = <&tcsr_mutex_block 0x1180 0x1200 0x1280>;
+
+        resets = <&gcc GCC_MSS_RESTART>;
+        reset-names = "mss_restart";
+
+        cx-supply = <&pm8841_s2>;
+        mss-supply = <&pm8841_s3>;
+        mx-supply = <&pm8841_s1>;
+        pll-supply = <&pm8941_l12>;
+
+        qcom,smem-states = <&modem_smp2p_out 0>;
+        qcom,smem-state-names = "stop";
+
+        mba {
+                memory-region = <&mba_region>;
+        };
+
+        mpss {
+                memory-region = <&mpss_region>;
+        };
+
+        smd-edge {
+                interrupts = <GIC_SPI 25 IRQ_TYPE_EDGE_RISING>;
+
+                qcom,ipc = <&apcs 8 12>;
+                qcom,smd-edge = <0>;
+
+                label = "modem";
+        };
+    };
-- 
2.36.0


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

* [PATCH 7/9] dt-bindings: remoteproc: qcom: mss: Add MSS on MSM8953
  2022-05-11 16:15 [PATCH 0/9] Add support for remoteprocs on the MSM8953 platform Sireesh Kodali
                   ` (5 preceding siblings ...)
  2022-05-11 16:15 ` [PATCH 6/9] dt-bindings: remoteproc: qcom: mss: Convert bindings to YAML Sireesh Kodali
@ 2022-05-11 16:16 ` Sireesh Kodali
  2022-05-11 16:16 ` [PATCH 8/9] dt-bindings: remoteproc: qcom: adsp: Add ADSP " Sireesh Kodali
  2022-05-11 16:16 ` [PATCH 9/9] arm64: dts: qcom: msm8953: Add remote processor nodes Sireesh Kodali
  8 siblings, 0 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-11 16:16 UTC (permalink / raw)
  To: linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Sireesh Kodali,
	Andy Gross, Mathieu Poirier, Rob Herring, Krzysztof Kozlowski

Add bindings for MSS on the MSM8953 platform, which is used by
SDM450, SDM625, SDM626, APQ8053 and SDM632.

Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
---
 .../bindings/remoteproc/qcom,q6v5.yaml        | 25 +++++++++++++++++++
 1 file changed, 25 insertions(+)

diff --git a/Documentation/devicetree/bindings/remoteproc/qcom,q6v5.yaml b/Documentation/devicetree/bindings/remoteproc/qcom,q6v5.yaml
index 1c67c6cbf417..4882553df8b9 100644
--- a/Documentation/devicetree/bindings/remoteproc/qcom,q6v5.yaml
+++ b/Documentation/devicetree/bindings/remoteproc/qcom,q6v5.yaml
@@ -31,6 +31,7 @@ properties:
               - qcom,qcs404-wcss-pil
               - qcom,msm8916-mss-pil
               - qcom,msm8974-mss-pil
+              - qcom,msm8953-mss-pil
               - qcom,msm8996-mss-pil
               - qcom,msm8998-mss-pil
               - qcom,sc7180-mss-pil
@@ -263,6 +264,27 @@ allOf:
             - const: mem
             - const: xo
 
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - qcom,msm8953-mss-pil
+    then:
+      properties:
+        clocks:
+          items:
+            - description: Interface clock
+            - description: Bus clock
+            - description: Memory clock
+            - description: XO clock
+        clock-names:
+          items:
+            - const: iface
+            - const: bus
+            - const: mem
+            - const: xo
+
   - if:
       properties:
         compatible:
@@ -410,6 +432,7 @@ allOf:
               - qcom,qcs404-wcss-pil
               - qcom,msm8916-mss-pil
               - qcom,msm8974-mss-pil
+              - qcom,msm8953-mss-pil
     then:
       properties:
         interrupts-extended:
@@ -479,6 +502,7 @@ allOf:
           enum:
             - qcom,msm8916-mss-pil
             - qcom,msm8974-mss-pil
+            - qcom,msm8953-mss-pil
             - qcom,msm8996-mss-pil
             - qcom,msm8998-mss-pil
     then:
@@ -573,6 +597,7 @@ allOf:
               - qcom,q6v5-pil
               - qcom,msm8916-mss-pil
               - qcom,msm8974-mss-pil
+              - qcom,msm8953-mss-pil
               - qcom,msm8996-mss-pil
               - qcom,msm8998-mss-pil
     then:
-- 
2.36.0


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

* [PATCH 8/9] dt-bindings: remoteproc: qcom: adsp: Add ADSP on MSM8953
  2022-05-11 16:15 [PATCH 0/9] Add support for remoteprocs on the MSM8953 platform Sireesh Kodali
                   ` (6 preceding siblings ...)
  2022-05-11 16:16 ` [PATCH 7/9] dt-bindings: remoteproc: qcom: mss: Add MSS on MSM8953 Sireesh Kodali
@ 2022-05-11 16:16 ` Sireesh Kodali
  2022-05-11 16:16 ` [PATCH 9/9] arm64: dts: qcom: msm8953: Add remote processor nodes Sireesh Kodali
  8 siblings, 0 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-11 16:16 UTC (permalink / raw)
  To: linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Sireesh Kodali,
	Andy Gross, Mathieu Poirier, Rob Herring, Krzysztof Kozlowski,
	Manivannan Sadhasivam

Add support for booting the Audio DSP on the MSM8953 platform. This is
used by SoCs like SDM450, SDM625, SDM626, APQ8053, etc. Since the
configuration is the same on all SoCs, a single compatible string is
used.

Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
---
 Documentation/devicetree/bindings/remoteproc/qcom,adsp.yaml | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/Documentation/devicetree/bindings/remoteproc/qcom,adsp.yaml b/Documentation/devicetree/bindings/remoteproc/qcom,adsp.yaml
index a4409c398193..0e70e49b4e53 100644
--- a/Documentation/devicetree/bindings/remoteproc/qcom,adsp.yaml
+++ b/Documentation/devicetree/bindings/remoteproc/qcom,adsp.yaml
@@ -17,6 +17,7 @@ properties:
   compatible:
     enum:
       - qcom,msm8974-adsp-pil
+      - qcom,msm8953-adsp-pil
       - qcom,msm8996-adsp-pil
       - qcom,msm8996-slpi-pil
       - qcom,msm8998-adsp-pas
@@ -160,6 +161,7 @@ allOf:
           contains:
             enum:
               - qcom,msm8974-adsp-pil
+              - qcom,msm8953-adsp-pil
               - qcom,msm8996-adsp-pil
               - qcom,msm8996-slpi-pil
               - qcom,msm8998-adsp-pas
@@ -275,6 +277,7 @@ allOf:
           contains:
             enum:
               - qcom,msm8974-adsp-pil
+              - qcom,msm8953-adsp-pil
               - qcom,msm8996-adsp-pil
               - qcom,msm8996-slpi-pil
               - qcom,msm8998-adsp-pas
@@ -364,6 +367,7 @@ allOf:
         compatible:
           contains:
             enum:
+              - qcom,msm8953-adsp-pil
               - qcom,msm8996-adsp-pil
               - qcom,msm8998-adsp-pas
     then:
@@ -547,6 +551,7 @@ allOf:
           contains:
             enum:
               - qcom,msm8974-adsp-pil
+              - qcom,msm8953-adsp-pil
               - qcom,msm8996-adsp-pil
               - qcom,msm8996-slpi-pil
               - qcom,msm8998-adsp-pas
-- 
2.36.0


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

* [PATCH 9/9] arm64: dts: qcom: msm8953: Add remote processor nodes
  2022-05-11 16:15 [PATCH 0/9] Add support for remoteprocs on the MSM8953 platform Sireesh Kodali
                   ` (7 preceding siblings ...)
  2022-05-11 16:16 ` [PATCH 8/9] dt-bindings: remoteproc: qcom: adsp: Add ADSP " Sireesh Kodali
@ 2022-05-11 16:16 ` Sireesh Kodali
  2022-05-11 17:55   ` Krzysztof Kozlowski
  8 siblings, 1 reply; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-11 16:16 UTC (permalink / raw)
  To: linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Sireesh Kodali,
	Andy Gross, Rob Herring, Krzysztof Kozlowski

This commit adds the modem (q6v5_mss), WiFi (wcnss-pil) and audio DSP
(q6v5_pas) remote processor nodes for the MSM8953 platform. It also adds
the coresponding SMP2P, SMSM and pinctrl nodes that are needed by these
remote processors.

Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
---
 arch/arm64/boot/dts/qcom/msm8953.dtsi | 378 ++++++++++++++++++++++++++
 1 file changed, 378 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/msm8953.dtsi b/arch/arm64/boot/dts/qcom/msm8953.dtsi
index 431228faacdd..04e285e442ff 100644
--- a/arch/arm64/boot/dts/qcom/msm8953.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8953.dtsi
@@ -2,9 +2,13 @@
 /* Copyright (c) 2022, The Linux Foundation. All rights reserved. */
 
 #include <dt-bindings/clock/qcom,gcc-msm8953.h>
+#include <dt-bindings/clock/qcom,rpmcc.h>
 #include <dt-bindings/gpio/gpio.h>
 #include <dt-bindings/interrupt-controller/arm-gic.h>
 #include <dt-bindings/power/qcom-rpmpd.h>
+#include <dt-bindings/soc/qcom,apr.h>
+#include <dt-bindings/sound/qcom,q6dsp-lpass-ports.h>
+#include <dt-bindings/sound/qcom,q6asm.h>
 #include <dt-bindings/thermal/thermal.h>
 
 / {
@@ -384,6 +388,80 @@ rpmpd_opp_turbo: opp9 {
 		};
 	};
 
+	modem-smp2p {
+		compatible = "qcom,smp2p";
+		qcom,smem = <435>, <428>;
+
+		interrupts = <GIC_SPI 27 IRQ_TYPE_EDGE_RISING>;
+
+		qcom,ipc = <&apcs 8 14>;
+
+		qcom,local-pid = <0>;
+		qcom,remote-pid = <1>;
+
+		modem_smp2p_out: master-kernel {
+			qcom,entry-name = "master-kernel";
+
+			#qcom,smem-state-cells = <1>;
+		};
+
+		modem_smp2p_in: slave-kernel {
+			qcom,entry-name = "slave-kernel";
+
+			interrupt-controller;
+			#interrupt-cells = <2>;
+		};
+	};
+
+	adsp-smp2p {
+		compatible = "qcom,smp2p";
+		qcom,smem = <443>, <429>;
+
+		interrupts = <GIC_SPI 291 IRQ_TYPE_EDGE_RISING>;
+
+		mboxes = <&apcs 10>;
+
+		qcom,local-pid = <0>;
+		qcom,remote-pid = <2>;
+
+		smp2p_adsp_out: master-kernel {
+			qcom,entry-name = "master-kernel";
+			#qcom,smem-state-cells = <1>;
+		};
+
+		smp2p_adsp_in: slave-kernel {
+			qcom,entry-name = "slave-kernel";
+
+			interrupt-controller;
+			#interrupt-cells = <2>;
+		};
+	};
+
+	wcnss-smp2p {
+		compatible = "qcom,smp2p";
+		qcom,smem = <451>, <431>;
+
+		interrupts = <GIC_SPI 143 IRQ_TYPE_EDGE_RISING>;
+
+		qcom,ipc = <&apcs 8 18>;
+
+		qcom,local-pid = <0>;
+		qcom,remote-pid = <4>;
+
+		wcnss_smp2p_out: master-kernel {
+			qcom,entry-name = "master-kernel";
+
+			#qcom,smem-state-cells = <1>;
+		};
+
+		wcnss_smp2p_in: slave-kernel {
+			qcom,entry-name = "slave-kernel";
+
+			interrupt-controller;
+			#interrupt-cells = <2>;
+		};
+	};
+
 	smsm {
 		compatible = "qcom,smsm";
 
@@ -398,6 +476,22 @@ apps_smsm: apps@0 {
 
 			#qcom,smem-state-cells = <1>;
 		};
+
+		hexagon_smsm: hexagon@1 {
+			reg = <1>;
+			interrupts = <GIC_SPI 26 IRQ_TYPE_EDGE_RISING>;
+
+			interrupt-controller;
+			#interrupt-cells = <2>;
+		};
+
+		wcnss_smsm: wcnss@6 {
+			reg = <6>;
+			interrupts = <GIC_SPI 144 IRQ_TYPE_EDGE_RISING>;
+
+			interrupt-controller;
+			#interrupt-cells = <2>;
+		};
 	};
 
 	soc: soc@0 {
@@ -688,6 +782,59 @@ i2c_8_sleep: i2c-8-sleep-pins {
 				drive-strength = <2>;
 				bias-disable;
 			};
+
+			wcnss_default: wcnss-default-pins {
+				wcss_wlan2 {
+					pins = "gpio76";
+					function = "wcss_wlan2";
+				};
+				wcss_wlan1 {
+					pins = "gpio77";
+					function = "wcss_wlan1";
+				};
+				wcss_wlan0 {
+					pins = "gpio78";
+					function = "wcss_wlan0";
+				};
+				wcss_wlan {
+					pins = "gpio79", "gpio80";
+					function = "wcss_wlan";
+				};
+
+				pinconf {
+					pins = "gpio76", "gpio77", "gpio78",
+					     "gpio79", "gpio80";
+					drive-strength = <6>;
+					bias-pull-up;
+				};
+			};
+
+			wcnss_sleep: wcnss-sleep-pins {
+				wcss_wlan2 {
+					pins = "gpio76";
+					function = "wcss_wlan2";
+				};
+				wcss_wlan1 {
+					pins = "gpio77";
+					function = "wcss_wlan1";
+				};
+				wcss_wlan0 {
+					pins = "gpio78";
+					function = "wcss_wlan0";
+				};
+				wcss_wlan {
+					pins = "gpio79", "gpio80";
+					function = "wcss_wlan";
+				};
+
+				pinconf {
+					pins = "gpio76", "gpio77",
+					     "gpio78", "gpio79",
+					     "gpio80";
+					drive-strength = <2>;
+					bias-pull-down;
+				};
+			};
 		};
 
 		gcc: clock-controller@1800000 {
@@ -745,6 +892,59 @@ spmi_bus: spmi@200f000 {
 			#size-cells = <0>;
 		};
 
+		modem: remoteproc@4080000 {
+			compatible = "qcom,msm8953-mss-pil";
+			reg = <0x4080000 0x100>,
+			    <0x4020000 0x040>;
+
+			reg-names = "qdsp6", "rmb";
+
+			interrupts-extended = <&intc 0 24 1>,
+					      <&modem_smp2p_in 0 0>,
+					      <&modem_smp2p_in 1 0>,
+					      <&modem_smp2p_in 2 0>,
+					      <&modem_smp2p_in 3 0>;
+			interrupt-names = "wdog", "fatal", "ready",
+					  "handover", "stop-ack";
+
+			clocks = <&gcc GCC_MSS_CFG_AHB_CLK>,
+				 <&gcc GCC_MSS_Q6_BIMC_AXI_CLK>,
+				 <&gcc GCC_BOOT_ROM_AHB_CLK>,
+				 <&xo_board>;
+			clock-names = "iface", "bus", "mem", "xo";
+
+			power-domains = <&rpmpd MSM8953_VDDCX>, <&rpmpd MSM8953_VDDMX>;
+			power-domain-names = "cx", "mx";
+
+			qcom,smem-states = <&modem_smp2p_out 0>;
+			qcom,smem-state-names = "stop";
+
+			resets = <&gcc GCC_MSS_BCR>;
+			reset-names = "mss_restart";
+
+			qcom,halt-regs = <&tcsr 0x18000 0x19000 0x1a000>;
+
+			status = "okay";
+
+			mba {
+				memory-region = <&mba_mem>;
+			};
+
+			mpss {
+				memory-region = <&mpss_mem>;
+			};
+
+			smd-edge {
+				interrupts = <GIC_SPI 25 IRQ_TYPE_EDGE_RISING>;
+
+				qcom,smd-edge = <0>;
+				qcom,ipc = <&apcs 8 12>;
+				qcom,remote-pid = <1>;
+
+				label = "modem";
+			};
+		};
+
 		usb3: usb@70f8800 {
 			compatible = "qcom,msm8953-dwc3", "qcom,dwc3";
 			reg = <0x70f8800 0x400>;
@@ -1057,6 +1257,74 @@ i2c_8: i2c@7af8000 {
 			status = "disabled";
 		};
 
+		pronto: remoteproc@a21b000 {
+			compatible = "qcom,pronto-v3-pil", "qcom,pronto";
+			reg = <0xa204000 0x2000>,
+			      <0xa202000 0x1000>,
+			      <0xa21b000 0x3000>;
+			reg-names = "ccu", "dxe", "pmu";
+
+			memory-region = <&wcnss_fw_mem>;
+
+			interrupts-extended = <&intc 0 149 IRQ_TYPE_EDGE_RISING>,
+					      <&wcnss_smp2p_in 0 IRQ_TYPE_EDGE_RISING>,
+					      <&wcnss_smp2p_in 1 IRQ_TYPE_EDGE_RISING>,
+					      <&wcnss_smp2p_in 2 IRQ_TYPE_EDGE_RISING>,
+					      <&wcnss_smp2p_in 3 IRQ_TYPE_EDGE_RISING>;
+			interrupt-names = "wdog", "fatal", "ready", "handover", "stop-ack";
+
+			power-domains = <&rpmpd MSM8953_VDDCX>, <&rpmpd MSM8953_VDDMX>;
+			power-domain-names = "cx", "mx";
+
+			qcom,state = <&wcnss_smp2p_out 0>;
+			qcom,state-names = "stop";
+
+			pinctrl-names = "default", "sleep";
+			pinctrl-0 = <&wcnss_default>;
+			pinctrl-1 = <&wcnss_sleep>;
+
+			status = "okay";
+
+			iris: iris {
+				compatible = "qcom,wcn3660b";
+
+				clocks = <&rpmcc RPM_SMD_RF_CLK2>;
+				clock-names = "xo";
+			};
+
+			smd-edge {
+				interrupts = <GIC_SPI 142 IRQ_TYPE_EDGE_RISING>;
+
+				qcom,ipc = <&apcs 8 17>;
+				qcom,smd-edge = <6>;
+				qcom,remote-pid = <4>;
+
+				label = "pronto";
+
+				wcnss {
+					compatible = "qcom,wcnss";
+					qcom,smd-channels = "WCNSS_CTRL";
+
+					qcom,mmio = <&pronto>;
+
+					bt {
+						compatible = "qcom,wcnss-bt";
+					};
+
+					wifi {
+						compatible = "qcom,wcnss-wlan";
+
+						interrupts = <GIC_SPI 145 IRQ_TYPE_LEVEL_HIGH>,
+							     <GIC_SPI 146 IRQ_TYPE_LEVEL_HIGH>;
+						interrupt-names = "tx", "rx";
+
+						qcom,smem-states = <&apps_smsm 10>, <&apps_smsm 9>;
+						qcom,smem-state-names = "tx-enable", "tx-rings-empty";
+					};
+				};
+			};
+		};
+
 		intc: interrupt-controller@b000000 {
 			compatible = "qcom,msm-qgic2";
 			interrupt-controller;
@@ -1070,6 +1338,116 @@ apcs: mailbox@b011000 {
 			#mbox-cells = <1>;
 		};
 
+		lpass: remoteproc@c200000 {
+			compatible = "qcom,msm8953-adsp-pil";
+			reg = <0xc200000 0x100>;
+
+			interrupts-extended = <&intc 0 293 IRQ_TYPE_EDGE_RISING>,
+					      <&smp2p_adsp_in 0 IRQ_TYPE_EDGE_RISING>,
+					      <&smp2p_adsp_in 1 IRQ_TYPE_EDGE_RISING>,
+					      <&smp2p_adsp_in 2 IRQ_TYPE_EDGE_RISING>,
+					      <&smp2p_adsp_in 3 IRQ_TYPE_EDGE_RISING>;
+			interrupt-names = "wdog", "fatal", "ready",
+					  "handover", "stop-ack";
+			clocks = <&xo_board>;
+			clock-names = "xo";
+
+			power-domains = <&rpmpd MSM8953_VDDCX>;
+			power-domain-names = "cx";
+
+			memory-region = <&adsp_fw_mem>;
+
+			qcom,smem-states = <&smp2p_adsp_out 0>;
+			qcom,smem-state-names = "stop";
+
+			smd-edge {
+				interrupts = <GIC_SPI 289 IRQ_TYPE_EDGE_RISING>;
+
+				label = "lpass";
+				mboxes = <&apcs 8>;
+				qcom,smd-edge = <1>;
+				qcom,remote-pid = <2>;
+				#address-cells = <1>;
+				#size-cells = <0>;
+
+				apr {
+					compatible = "qcom,apr-v2";
+					qcom,smd-channels = "apr_audio_svc";
+					qcom,apr-domain = <APR_DOMAIN_ADSP>;
+					#address-cells = <1>;
+					#size-cells = <0>;
+
+					q6core {
+						reg = <APR_SVC_ADSP_CORE>;
+						compatible = "qcom,q6core";
+					};
+
+					q6afe: q6afe {
+						compatible = "qcom,q6afe";
+						reg = <APR_SVC_AFE>;
+						q6afedai: dais {
+							compatible = "qcom,q6afe-dais";
+							#address-cells = <1>;
+							#size-cells = <0>;
+							#sound-dai-cells = <1>;
+
+							dai@16 {
+								reg = <PRIMARY_MI2S_RX>;
+								qcom,sd-lines = <0 1>;
+							};
+
+							dai@21 {
+								reg = <TERTIARY_MI2S_TX>;
+								qcom,sd-lines = <0 1>;
+							};
+						};
+						q6afecc: clock-controller {
+							compatible = "qcom,q6afe-clocks";
+							#clock-cells = <2>;
+						};
+					};
+
+					q6asm: q6asm {
+						compatible = "qcom,q6asm";
+						reg = <APR_SVC_ASM>;
+						q6asmdai: dais {
+							compatible = "qcom,q6asm-dais";
+							#address-cells = <1>;
+							#size-cells = <0>;
+							#sound-dai-cells = <1>;
+
+							dai@0 {
+								reg = <MSM_FRONTEND_DAI_MULTIMEDIA1>;
+							};
+
+							dai@1 {
+								reg = <MSM_FRONTEND_DAI_MULTIMEDIA2>;
+							};
+
+							dai@2 {
+								reg = <MSM_FRONTEND_DAI_MULTIMEDIA3>;
+							};
+
+							dai@3 {
+								reg = <MSM_FRONTEND_DAI_MULTIMEDIA4>;
+								is-compress-dai;
+							};
+						};
+					};
+
+					q6adm: q6adm {
+						compatible = "qcom,q6adm";
+						reg = <APR_SVC_ADM>;
+						q6routing: routing {
+							compatible = "qcom,q6adm-routing";
+							#sound-dai-cells = <0>;
+						};
+					};
+				};
+			};
+
+		};
+
 		timer@b120000 {
 			compatible = "arm,armv7-timer-mem";
 			reg = <0xb120000 0x1000>;
-- 
2.36.0


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

* Re: [PATCH 1/9] remoteproc: qcom: pas: Add MSM8953 ADSP PIL support
  2022-05-11 16:15 ` [PATCH 1/9] remoteproc: qcom: pas: Add MSM8953 ADSP PIL support Sireesh Kodali
@ 2022-05-11 16:49   ` Dmitry Baryshkov
  2022-05-11 16:51   ` Dmitry Baryshkov
  1 sibling, 0 replies; 35+ messages in thread
From: Dmitry Baryshkov @ 2022-05-11 16:49 UTC (permalink / raw)
  To: Sireesh Kodali, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier

On 11/05/2022 19:15, Sireesh Kodali wrote:
> Add support for the Audio DSP PIL found on the Qualcomm MSM8953
> platform. The same configuration is used on all SoCs based on the
> MSM8953 platform (SDM450, SDA450, SDM625, SDM632, APQ8053).
> 
> Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> ---
>   drivers/remoteproc/qcom_q6v5_pas.c | 31 ++++++++++++++++++++++++++++++
>   1 file changed, 31 insertions(+)
> 
> diff --git a/drivers/remoteproc/qcom_q6v5_pas.c b/drivers/remoteproc/qcom_q6v5_pas.c
> index 1ae47cc153e5..4dcb714a1468 100644
> --- a/drivers/remoteproc/qcom_q6v5_pas.c
> +++ b/drivers/remoteproc/qcom_q6v5_pas.c
> @@ -617,7 +617,37 @@ static const struct adsp_data sm8350_adsp_resource = {
>   	.ssctl_id = 0x14,
>   };
>   
> +static const struct adsp_data msm8953_adsp_resource = {
> +	.crash_reason_smem = 423,
> +	.firmware_name = "adsp.mdt",
> +	.pas_id = 1,
> +	.has_aggre2_clk = false,
> +	.auto_boot = true,
> +	.proxy_pd_names = (char*[]){
> +		"cx",
> +		NULL,
> +	},
> +	.ssr_name = "lpass",
> +	.sysmon_name = "adsp",
> +	.ssctl_id = 0x14,
> +};
> +
>   static const struct adsp_data msm8996_adsp_resource = {
> +	.crash_reason_smem = 423,
> +	.firmware_name = "adsp.mdt",
> +	.pas_id = 1,
> +	.has_aggre2_clk = false,
> +	.auto_boot = true,
> +	.proxy_pd_names = (char*[]){
> +		"cx",
> +		NULL,
> +	},
> +	.ssr_name = "lpass",
> +	.sysmon_name = "adsp",
> +	.ssctl_id = 0x14,
> +};
> +
> +static const struct adsp_data msm8998_adsp_resource = {

This was dropped in 9ae45035ba2be4117edb8fd3952c3c5b84a0b820. Please 
take care when rebasing your patches.

>   		.crash_reason_smem = 423,
>   		.firmware_name = "adsp.mdt",
>   		.pas_id = 1,
> @@ -850,6 +880,7 @@ static const struct adsp_data sdx55_mpss_resource = {
>   static const struct of_device_id adsp_of_match[] = {
>   	{ .compatible = "qcom,msm8974-adsp-pil", .data = &adsp_resource_init},
>   	{ .compatible = "qcom,msm8996-adsp-pil", .data = &msm8996_adsp_resource},
> +	{ .compatible = "qcom,msm8953-adsp-pil", .data = &msm8953_adsp_resource},
>   	{ .compatible = "qcom,msm8996-slpi-pil", .data = &slpi_resource_init},
>   	{ .compatible = "qcom,msm8998-adsp-pas", .data = &msm8996_adsp_resource},
>   	{ .compatible = "qcom,msm8998-slpi-pas", .data = &slpi_resource_init},


-- 
With best wishes
Dmitry

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

* Re: [PATCH 1/9] remoteproc: qcom: pas: Add MSM8953 ADSP PIL support
  2022-05-11 16:15 ` [PATCH 1/9] remoteproc: qcom: pas: Add MSM8953 ADSP PIL support Sireesh Kodali
  2022-05-11 16:49   ` Dmitry Baryshkov
@ 2022-05-11 16:51   ` Dmitry Baryshkov
  2022-05-12 10:39     ` Sireesh Kodali
  1 sibling, 1 reply; 35+ messages in thread
From: Dmitry Baryshkov @ 2022-05-11 16:51 UTC (permalink / raw)
  To: Sireesh Kodali, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier

On 11/05/2022 19:15, Sireesh Kodali wrote:
> Add support for the Audio DSP PIL found on the Qualcomm MSM8953
> platform. The same configuration is used on all SoCs based on the
> MSM8953 platform (SDM450, SDA450, SDM625, SDM632, APQ8053).
> 
> Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> ---
>   drivers/remoteproc/qcom_q6v5_pas.c | 31 ++++++++++++++++++++++++++++++
>   1 file changed, 31 insertions(+)
> 
> diff --git a/drivers/remoteproc/qcom_q6v5_pas.c b/drivers/remoteproc/qcom_q6v5_pas.c
> index 1ae47cc153e5..4dcb714a1468 100644
> --- a/drivers/remoteproc/qcom_q6v5_pas.c
> +++ b/drivers/remoteproc/qcom_q6v5_pas.c
> @@ -617,7 +617,37 @@ static const struct adsp_data sm8350_adsp_resource = {
>   	.ssctl_id = 0x14,
>   };
>   
> +static const struct adsp_data msm8953_adsp_resource = {
> +	.crash_reason_smem = 423,
> +	.firmware_name = "adsp.mdt",
> +	.pas_id = 1,
> +	.has_aggre2_clk = false,
> +	.auto_boot = true,
> +	.proxy_pd_names = (char*[]){
> +		"cx",
> +		NULL,
> +	},
> +	.ssr_name = "lpass",
> +	.sysmon_name = "adsp",
> +	.ssctl_id = 0x14,
> +};
> +

Also it looks like this item is identical to msm8996_adsp_resources. So 
you can existing structure instead.

>   static const struct adsp_data msm8996_adsp_resource = {
> +	.crash_reason_smem = 423,
> +	.firmware_name = "adsp.mdt",
> +	.pas_id = 1,
> +	.has_aggre2_clk = false,
> +	.auto_boot = true,
> +	.proxy_pd_names = (char*[]){
> +		"cx",
> +		NULL,
> +	},
> +	.ssr_name = "lpass",
> +	.sysmon_name = "adsp",
> +	.ssctl_id = 0x14,
> +};
> +
> +static const struct adsp_data msm8998_adsp_resource = {
>   		.crash_reason_smem = 423,
>   		.firmware_name = "adsp.mdt",
>   		.pas_id = 1,
> @@ -850,6 +880,7 @@ static const struct adsp_data sdx55_mpss_resource = {
>   static const struct of_device_id adsp_of_match[] = {
>   	{ .compatible = "qcom,msm8974-adsp-pil", .data = &adsp_resource_init},
>   	{ .compatible = "qcom,msm8996-adsp-pil", .data = &msm8996_adsp_resource},
> +	{ .compatible = "qcom,msm8953-adsp-pil", .data = &msm8953_adsp_resource},
>   	{ .compatible = "qcom,msm8996-slpi-pil", .data = &slpi_resource_init},
>   	{ .compatible = "qcom,msm8998-adsp-pas", .data = &msm8996_adsp_resource},
>   	{ .compatible = "qcom,msm8998-slpi-pas", .data = &slpi_resource_init},


-- 
With best wishes
Dmitry

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

* Re: [PATCH 2/9] remoteproc: qcom: q6v5-mss: Add modem support on MSM8953
  2022-05-11 16:15 ` [PATCH 2/9] remoteproc: qcom: q6v5-mss: Add modem support on MSM8953 Sireesh Kodali
@ 2022-05-11 16:54   ` Dmitry Baryshkov
  2022-05-12  5:16     ` Sireesh Kodali
  2022-05-12 10:38     ` Sireesh Kodali
  0 siblings, 2 replies; 35+ messages in thread
From: Dmitry Baryshkov @ 2022-05-11 16:54 UTC (permalink / raw)
  To: Sireesh Kodali, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier

On 11/05/2022 19:15, Sireesh Kodali wrote:
> The modem on the MSM8953 platform is similar to the modem on the MSM8996
> platform in terms of set up. It differs primarily in the way it needs SCM
> to bless the MPSS firmware region.
> 
> Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> ---
>   drivers/remoteproc/qcom_q6v5_mss.c | 64 +++++++++++++++++++++++++++---
>   1 file changed, 58 insertions(+), 6 deletions(-)
> 
> diff --git a/drivers/remoteproc/qcom_q6v5_mss.c b/drivers/remoteproc/qcom_q6v5_mss.c
> index af217de75e4d..a73fdcddeda4 100644
> --- a/drivers/remoteproc/qcom_q6v5_mss.c
> +++ b/drivers/remoteproc/qcom_q6v5_mss.c
> @@ -234,6 +234,7 @@ struct q6v5 {
>   
>   enum {
>   	MSS_MSM8916,
> +	MSS_MSM8953,
>   	MSS_MSM8974,
>   	MSS_MSM8996,
>   	MSS_MSM8998,
> @@ -687,12 +688,14 @@ static int q6v5proc_reset(struct q6v5 *qproc)
>   		}
>   		goto pbl_wait;
>   	} else if (qproc->version == MSS_MSM8996 ||
> -		   qproc->version == MSS_MSM8998) {
> +		   qproc->version == MSS_MSM8998 ||
> +		   qproc->version == MSS_MSM8953) {
>   		int mem_pwr_ctl;
>   
>   		/* Override the ACC value if required */
> -		writel(QDSP6SS_ACC_OVERRIDE_VAL,
> -		       qproc->reg_base + QDSP6SS_STRAP_ACC);
> +		if (qproc->version != MSS_MSM8953)
> +			writel(QDSP6SS_ACC_OVERRIDE_VAL,
> +					qproc->reg_base + QDSP6SS_STRAP_ACC);
>   
>   		/* Assert resets, stop core */
>   		val = readl(qproc->reg_base + QDSP6SS_RESET_REG);
> @@ -734,7 +737,8 @@ static int q6v5proc_reset(struct q6v5 *qproc)
>   		writel(val, qproc->reg_base + QDSP6SS_PWR_CTL_REG);
>   
>   		/* Turn on L1, L2, ETB and JU memories 1 at a time */
> -		if (qproc->version == MSS_MSM8996) {
> +		if (qproc->version == MSS_MSM8996 ||
> +			qproc->version == MSS_MSM8953) {
>   			mem_pwr_ctl = QDSP6SS_MEM_PWR_CTL;
>   			i = 19;
>   		} else {
> @@ -1314,7 +1318,16 @@ static int q6v5_mpss_load(struct q6v5 *qproc)
>   			max_addr = ALIGN(phdr->p_paddr + phdr->p_memsz, SZ_4K);
>   	}
>   
> -	/*
> +	if (qproc->version == MSS_MSM8953) {
> +		ret = qcom_scm_pas_mem_setup(5, qproc->mpss_phys, qproc->mpss_size);
> +		if (ret) {
> +			dev_err(qproc->dev,
> +					"setting up mpss memory failed: %d\n", ret);
> +			goto release_firmware;
> +		}
> +	}
> +
> +	/**

Single star please

>   	 * In case of a modem subsystem restart on secure devices, the modem
>   	 * memory can be reclaimed only after MBA is loaded.
>   	 */
> @@ -1413,7 +1426,6 @@ static int q6v5_mpss_load(struct q6v5 *qproc)
>   			writel(RMB_CMD_LOAD_READY, qproc->rmb_base + RMB_MBA_COMMAND_REG);
>   		}
>   		writel(size, qproc->rmb_base + RMB_PMI_CODE_LENGTH_REG);
> -
>   		ret = readl(qproc->rmb_base + RMB_MBA_STATUS_REG);
>   		if (ret < 0) {
>   			dev_err(qproc->dev, "MPSS authentication failed: %d\n",
> @@ -1422,6 +1434,7 @@ static int q6v5_mpss_load(struct q6v5 *qproc)
>   		}
>   	}
>   
> +

Unnecessary


>   	/* Transfer ownership of modem ddr region to q6 */
>   	ret = q6v5_xfer_mem_ownership(qproc, &qproc->mpss_perm, false, true,
>   				      qproc->mpss_phys, qproc->mpss_size);
> @@ -2198,6 +2211,44 @@ static const struct rproc_hexagon_res msm8996_mss = {
>   	.version = MSS_MSM8996,
>   };
>   
> +static const struct rproc_hexagon_res msm8953_mss = {
> +	.hexagon_mba_image = "mba.mbn",
> +	.proxy_supply = (struct qcom_mss_reg_res[]) {
> +		{
> +			.supply = "pll",
> +			.uA = 100000,
> +		},
> +		{}
> +	},
> +	.proxy_pd_names = (char*[]) {
> +			"cx",
> +			"mx",
> +			NULL
> +	},
> +	.active_supply = (struct qcom_mss_reg_res[]) {
> +		{
> +			.supply = "mss",
> +			.uV = 1050000,
> +			.uA = 100000,
> +		},
> +		{}
> +	},
> +	.proxy_clk_names = (char*[]){
> +			"xo",
> +			NULL
> +	},
> +	.active_clk_names = (char*[]){
> +			"iface",
> +			"bus",
> +			"mem",
> +			NULL
> +	},
> +	.need_mem_protection = false,
> +	.has_alt_reset = false,
> +	.has_spare_reg = false,


Please follow the custom  and define the rest of fields here.

> +	.version = MSS_MSM8953,
> +};
> +
>   static const struct rproc_hexagon_res msm8916_mss = {
>   	.hexagon_mba_image = "mba.mbn",
>   	.proxy_supply = (struct qcom_mss_reg_res[]) {
> @@ -2301,6 +2352,7 @@ static const struct of_device_id q6v5_of_match[] = {
>   	{ .compatible = "qcom,msm8916-mss-pil", .data = &msm8916_mss},
>   	{ .compatible = "qcom,msm8974-mss-pil", .data = &msm8974_mss},
>   	{ .compatible = "qcom,msm8996-mss-pil", .data = &msm8996_mss},
> +	{ .compatible = "qcom,msm8953-mss-pil", .data = &msm8953_mss},
>   	{ .compatible = "qcom,msm8998-mss-pil", .data = &msm8998_mss},
>   	{ .compatible = "qcom,sc7180-mss-pil", .data = &sc7180_mss},
>   	{ .compatible = "qcom,sc7280-mss-pil", .data = &sc7280_mss},


-- 
With best wishes
Dmitry

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

* Re: [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML
  2022-05-11 16:15 ` [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML Sireesh Kodali
@ 2022-05-11 17:15   ` Krzysztof Kozlowski
  2022-05-12  6:50     ` Sireesh Kodali
  2022-05-12 13:49   ` Rob Herring
  2022-12-01 13:22   ` Krzysztof Kozlowski
  2 siblings, 1 reply; 35+ messages in thread
From: Krzysztof Kozlowski @ 2022-05-11 17:15 UTC (permalink / raw)
  To: Sireesh Kodali, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier, Rob Herring, Krzysztof Kozlowski

On 11/05/2022 18:15, Sireesh Kodali wrote:
> Convert the dt-bindings from txt to YAML. This is in preparation for
> including the relevant bindings for the MSM8953 platform's wcnss pil.
> 
> Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>

Thank you for your patch. There is something to discuss/improve.

Please use existing bindings or example-schema as a starting point. Half
of my review could be skipped if you just followed what we already have
in the tree.

Some of these qcom specific properties already exist but you decided to
write them differently... please don't, rather reuse the code.

(...)

> +
> +maintainers:
> +  - Bjorn Andersson <bjorn.andersson@linaro.org>
> +
> +description:
> +  This document defines the binding for a component that loads and boots
> +  firmware on the Qualcomm WCNSS core.
> +
> +properties:
> +  compatible:
> +    oneOf:
> +      - items:
> +          - enum:
> +              - qcom,pronto-v2-pil
> +          - enum:
> +              - qcom,pronto

This does not look correct. The fallback compatible should not change.
What is more, it was not documented in original binding, so this should
be done in separate patch.

> +      - items:

No need for items, it's just one item.

> +          - enum:
> +              - qcom,riva-pil
> +              - qcom,pronto-v1-pil
> +              - qcom,pronto-v2-pil
> +
> +  reg:
> +    description: must specify the base address and size of the CCU, DXE and PMU
> +      register blocks

New line after "decription:", drop "must specify" and start with capital
letter.

You need maxItems: 3


> +
> +  reg-names:
> +    items:
> +      - const: ccu
> +      - const: dxe
> +      - const: pmu
> +
> +  interrupts-extended:
> +    description:
> +      Interrupt lines

Skip description, it's obvious.

It should be only "interrupts", not extended.

> +    minItems: 2
> +    maxItems: 5
> +
> +  interrupt-names:
> +    minItems: 2
> +    maxItems: 5

Names should be clearly defined. They were BTW defined in original
bindings, so you should not remove them. This makes me wonder what else
did you remove from original bindings...

Please document all deviations from pure conversion in the commit msg.
It's a second "hidden" difference.

> +
> +  firmware-name:
> +    $ref: /schemas/types.yaml#/definitions/string
> +    description: Relative firmware image path for the WCNSS core. Defaults to
> +      "wcnss.mdt".


Blank line after "description:". This applies to other places as well.

Remove "Defailts to ..." and just add "default" schema.

> +
> +  vddpx-supply:
> +    description: Reference to the PX regulator to be held on behalf of the
> +      booting of the WCNSS core
> +
> +  vddmx-supply:
> +    description: Reference to the MX regulator to be held on behalf of the
> +      booting of the WCNSS core.
> +
> +  vddcx-supply:
> +    description: Reference to the CX regulator to be held on behalf of the
> +      booting of the WCNSS core.

s/Reference to the//

> +
> +  power-domains:
> +    $ref: /schemas/types.yaml#/definitions/phandle-array
> +    description: References to the power domains that need to be held on
> +      behalf of the booting WCNSS core

1. Ditto.
2. No need for ref
3. maxItems

> +
> +  power-domain-names:
> +    $ref: /schemas/types.yaml#/definitions/string-array

No need for ref, skip description.

> +    description: Names of the power domains
> +    items:
> +      - const: cx
> +      - const: mx
> +
> +  qcom,smem-states:
> +    $ref: /schemas/types.yaml#/definitions/phandle-array
> +    description: States used by the AP to signal the WCNSS core that it should
> +      shutdown
> +    items:
> +      - description: Stop the modem
> +
> +  qcom,smem-state-names:
> +    $ref: /schemas/types.yaml#/definitions/string-array

No need for ref. Really, it does not appear in any of existing bindings
for smem-state-names, so how did you get it?

> +    description: The names of the state bits used for SMP2P output
> +    items:
> +      - const: stop
> +
> +  memory-region:
> +    maxItems: 1
> +    description: Reference to the reserved-memory for the WCNSS core
> +
> +  smd-edge:
> +    type: object
> +    description:
> +      Qualcomm Shared Memory subnode which represents communication edge,
> +      channels and devices related to the ADSP.

You should reference /schemas/soc/qcom/qcom,smd.yaml

> +
> +  iris:

Generic node name... what is "iris"?

> +    type: object
> +    description:
> +      The iris subnode of the WCNSS PIL is used to describe the attached rf module

s/rf/RF/

> +      and its resource dependencies.
> +
> +    properties:
> +      compatible:
> +        enum:
> +          - qcom,wcn3620
> +          - qcom,wcn3660
> +          - qcom,wcn3660b
> +          - qcom,wcn3680
> +
> +      clocks:
> +        description: XO clock
> +
> +      clock-names:
> +        items:
> +          - const: xo
> +
> +    required:
> +      - compatible

clocks and clock-names were required.
Missing supplies, which were btw as well required.

> +
> +required:
> +  - compatible
> +  - reg
> +  - reg-names
> +  - interrupts-extended
> +  - interrupt-names
> +  - vddpx-supply
> +  - memory-region
> +  - smd-edge
> +  - iris
> +
> +additionalProperties: false
> +
> +if:

Within allOf, please.



Best regards,
Krzysztof

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

* Re: [PATCH 6/9] dt-bindings: remoteproc: qcom: mss: Convert bindings to YAML
  2022-05-11 16:15 ` [PATCH 6/9] dt-bindings: remoteproc: qcom: mss: Convert bindings to YAML Sireesh Kodali
@ 2022-05-11 17:50   ` Krzysztof Kozlowski
  2022-05-12  9:50     ` Sireesh Kodali
  2022-05-12 13:49   ` Rob Herring
  1 sibling, 1 reply; 35+ messages in thread
From: Krzysztof Kozlowski @ 2022-05-11 17:50 UTC (permalink / raw)
  To: Sireesh Kodali, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier, Rob Herring, Krzysztof Kozlowski

On 11/05/2022 18:15, Sireesh Kodali wrote:
> Convert the bindings to YAML from txt. The bindings follow a similar
> schema to `qcom,adsp.yaml`.
> 
> Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> ---
>  .../bindings/remoteproc/qcom,q6v5.txt         | 302 --------
>  .../bindings/remoteproc/qcom,q6v5.yaml        | 702 ++++++++++++++++++
>  2 files changed, 702 insertions(+), 302 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,q6v5.txt
>  create mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,q6v5.yaml

Same comments as for patch 4 apply here. Some of them seems fixed so it
makes me wonder - why you wrote two bindings in entirely different way?

> +  This document defines the binding for a component that loads and boots firmware
> +  on the Qualcomm Hexagon core.
> +
> +properties:
> +  compatible:
> +    # Special case, because older platforms like MSM8916 use both compatibles together
> +    minItems: 1
> +    maxItems: 2
> +    oneOf:
> +      - items:
> +          - enum:
> +              - qcom,msm8916-mss-pil
> +          - enum:
> +              - qcom,q6v5-pil

Everywhere - same comments as in patch 4.

> +      - items:
> +          - enum:
> +              - qcom,q6v5-pil
> +              - qcom,ipq8074-wcss-pil
> +              - qcom,qcs404-wcss-pil
> +              - qcom,msm8916-mss-pil
> +              - qcom,msm8974-mss-pil
> +              - qcom,msm8996-mss-pil
> +              - qcom,msm8998-mss-pil
> +              - qcom,sc7180-mss-pil
> +              - qcom,sc7280-mss-pil
> +              - qcom,sdm845-mss-pil
> +
> +  reg:
> +    description: must specify the base address and size of the qdsp6 and rmb
> +      register blocks
> +    maxItems: 2
> +
> +  reg-names:
> +    items:
> +      - const: qdsp6
> +      - const: rmb
> +
> +  interrupts-extended:
> +    minItems: 5
> +    maxItems: 6
> +
> +  interrupt-names:
> +    minItems: 5
> +    maxItems: 6
> +
> +  firmware-name:
> +    $ref: /schemas/types.yaml#/definitions/string-array
> +    description: List the relative firmware image paths for the mba and
> +      modem. They are used for booting and authenticating the Hexagon core.
> +    maxItems: 2
> +
> +  clocks:
> +    minItems: 4
> +    maxItems: 10
> +
> +  clock-names:
> +    minItems: 4
> +    maxItems: 10
> +
> +  resets:
> +    description: Reference to the reset-controllwer for the modem subsystem
> +    minItems: 1
> +    maxItems: 3
> +
> +  reset-names:
> +    minItems: 1
> +    maxItems: 3
> +
> +  memory-region:
> +    maxItems: 1
> +    description: Reference to the reserved-memory for the mba region followed
> +      by the mpss region. Required if the mba and mpss sub-nodes are not
> +      specified.
> +
> +  cx-supply:
> +    description: Phandle to the CX regulator
> +
> +  mx-supply:
> +    description: Phandle to the MX regulator
> +
> +  pll-supply:
> +    description: Phandle to the PLL regulator, to be held on behalf of the
> +      booting Hexagon core
> +
> +  mss-supply:
> +    description: Phandle to the mss regulator, to be held on behalf of the
> +      booting Hexagon core

s/Phandle to//, everywhere.

> +
> +  power-domains:
> +    minItems: 1
> +    maxItems: 4
> +
> +  power-domain-names:
> +    minItems: 1
> +    maxItems: 4
> +
> +  qcom,qmp:
> +    $ref: /schemas/types.yaml#/definitions/phandle
> +    description: Reference to the AOSS side-channel message RAM.
> +
> +  qcom,smem-states:
> +    $ref: /schemas/types.yaml#/definitions/phandle-array
> +    description: States used by the AP to signal the Hexagon core
> +    items:
> +      - description: Stop the modem
> +
> +  qcom,smem-state-names:
> +    $ref: /schemas/types.yaml#/definitions/string-array
> +    description: The names of the state bits used for SMP2P output
> +    items:
> +      - const: stop
> +
> +  qcom,halt-regs:
> +    $ref: /schemas/types.yaml#/definitions/phandle-array
> +    description:
> +      Phandle reference to a syscon representing TCSR followed by the
> +      three offsets within syscon for q6, modem and nc halt registers.
> +
> +  qcom,spare-regs:
> +    $ref: /schemas/types.yaml#/definitions/phandle-array
> +    description:
> +      A phandle reference to a syscon representing TCSR followed by the
> +      offset within syscon for conn_box_spare0 register used by the modem
> +      sub-system running on SC7180 SoC.
> +
> +  qcom,ext-regs:
> +    $ref: /schemas/types.yaml#/definitions/phandle-array
> +    description:
> +      Two phandle references to syscons representing TCSR_REG and TCSR
> +      register space followed by the two offsets within the syscon to
> +      force_clk_en/rscc_disable and axim1_clk_off/crypto_clk_off registers
> +      respectively.
> +
> +  qcom,qaccept-regs:
> +    $ref: /schemas/types.yaml#/definitions/phandle-array
> +    description:
> +      A phandle reference to a syscon representing TCSR followed by the three
> +      offsets within syscon for mdm, cx and axi qaccept registers used by the
> +      modem sub-system running on SC7280 SoC.
> +
> +  iommus:
> +    description:
> +      Only required on platforms that do not have TrustZone.
> +
> +  smd-edge:
> +    type: object
> +    description:
> +      Qualcomm Shared Memory subnode which represents communication edge,
> +      channels and devices related to the ADSP.
> +
> +  glink-edge:
> +    type: object
> +    description:
> +      Qualcomm G-Link subnode which represents communication edge, channels
> +      and devices related to the ADSP.
> +
> +  mba:
> +    type: object

description needed.

> +    properties:
> +      memory-region:
> +        maxItems: 1
> +
> +    required:
> +      - memory-region
> +
> +  mpss:

description needed.

> +    type: object
> +    properties:
> +      memory-region:
> +        maxItems: 1
> +
> +    required:
> +      - memory-region
> +
> +required:
> +  - compatible
> +  - clocks
> +  - clock-names
> +  - interrupts-extended
> +  - interrupt-names
> +  - qcom,smem-states
> +  - qcom,smem-state-names
> +
> +additionalProperties: false
> +
> +allOf:
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,ipq8074-wcss-pil
> +    then:
> +      properties:
> +        clocks: false
> +        clock-names: false
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,qcs404-wcss-pil
> +    then:
> +      properties:
> +        clocks:
> +          items:
> +            - description: GCC_AHBS_CBCR clock
> +            - description: GCC_AXIM_CBCR clock
> +            - description: LCC_AHBFABRIC_CBC clock
> +            - description: TCSR_LCC_CBC clock
> +            - description: LCC_AHBS_CBC clock
> +            - description: LCC_TCM_SLAVE_CBC clock
> +            - description: LCC_ABHM_CBC clock
> +            - description: LCC_AXIM_CBC clock
> +            - description: LCC_BCR_SLEEP clock
> +            - description: XO clock
> +        clock-names:
> +          items:
> +            - const: gcc_ahbs_cbcr
> +            - const: gcc_axim_cbcr
> +            - const: lcc_ahbfabric_cbc
> +            - const: tcsr_lcc_cbc
> +            - const: lcc_abhs_cbc
> +            - const: lcc_tcm_slave_cbc
> +            - const: lcc_abhm_cbc
> +            - const: lcc_axim_cbc
> +            - const: lcc_bcr_sleep
> +            - const: xo
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,q6v5-pil
> +              - qcom,msm8916-mss-pil
> +              - qcom,msm8974-mss-pil
> +    then:
> +      properties:
> +        clocks:
> +          items:
> +            - description: Interface clock
> +            - description: Bus clock
> +            - description: Memory clock
> +            - description: XO clock
> +        clock-names:
> +          items:
> +            - const: iface
> +            - const: bus
> +            - const: mem
> +            - const: xo
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,msm8996-mss-pil
> +    then:
> +      properties:
> +        clocks:
> +          items:
> +            - description: Interface clock
> +            - description: Bus clock
> +            - description: Memory clock
> +            - description: GPLL0_MSS clock
> +            - description: SNOC_AXI clock
> +            - description: MNOC_AXI clock
> +            - description: PNOC clock
> +            - description: QDSS clock
> +            - description: XO clock
> +        clock-names:
> +          items:
> +            - const: iface
> +            - const: bus
> +            - const: mem
> +            - const: gpll0_mss
> +            - const: snoc_axi
> +            - const: mnoc_axi
> +            - const: pnoc
> +            - const: qdss
> +            - const: xo
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,msm8998-mss-pil
> +    then:
> +      properties:
> +        clocks:
> +          items:
> +            - description: Interface clock
> +            - description: Bus clock
> +            - description: Memory clock
> +            - description: GPLL0_MSS clock
> +            - description: SNOC_AXI clock
> +            - description: MNOC_AXI clock
> +            - description: QDSS clock
> +            - description: XO clock
> +        clock-names:
> +          items:
> +            - const: iface
> +            - const: bus
> +            - const: mem
> +            - const: gpll0_mss
> +            - const: snoc_axi
> +            - const: mnoc_axi
> +            - const: qdss
> +            - const: xo
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,sc7180-mss-pil
> +    then:
> +      properties:
> +        clocks:
> +          items:
> +            - description: Interface clock
> +            - description: Bus clock
> +            - description: NAV clock
> +            - description: SNOC_AXI clock
> +            - description: MNOC_AXI clock
> +            - description: XO clock
> +        clock-names:
> +          items:
> +            - const: iface
> +            - const: bus
> +            - const: nav
> +            - const: snoc_axi
> +            - const: mnoc_axi
> +            - const: xo
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,sc7280-mss-pil
> +    then:
> +      properties:
> +        clocks:
> +          items:
> +            - description: Interface clock
> +            - description: Offline clock
> +            - description: SNOC_AXI clock
> +            - description: PKA clock
> +            - description: XO clock
> +        clock-names:
> +          items:
> +            - const: iface
> +            - const: offline
> +            - const: snoc_axi
> +            - const: pka
> +            - const: xo
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,sdm845-mss-pil
> +    then:
> +      properties:
> +        clocks:
> +          items:
> +            - description: Interface clock
> +            - description: Bus clock
> +            - description: Memory clock
> +            - description: GPLL0_MSS clock
> +            - description: SNOC_AXI clock
> +            - description: MNOC_AXI clock
> +            - description: PRNG clock
> +            - description: XO clock
> +        clock-names:
> +          items:
> +            - const: iface
> +            - const: bus
> +            - const: mem
> +            - const: gpll0_mss
> +            - const: snoc_axi
> +            - const: mnoc_axi
> +            - const: prng
> +            - const: xo
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,q6v5-pil
> +              - qcom,ipq8074-wcss-pil
> +              - qcom,qcs404-wcss-pil
> +              - qcom,msm8916-mss-pil
> +              - qcom,msm8974-mss-pil
> +    then:
> +      properties:
> +        interrupts-extended:

No extended.

> +          items:
> +            - description: Watchdog interrupt
> +            - description: Fatal interrupt
> +            - description: Ready interrupt
> +            - description: Handover interrupt
> +            - description: Stop acknowledge interrupt
> +        interrupt-names:
> +          items:
> +            - const: wdog
> +            - const: fatal
> +            - const: ready
> +            - const: handover
> +            - const: stop-ack
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,msm8996-mss-pil
> +              - qcom,msm8998-mss-pil
> +              - qcom,sc7180-mss-pil
> +              - qcom,sc7280-mss-pil
> +              - qcom,sdm845-mss-pil
> +    then:
> +      properties:
> +        interrupts-extended:
> +          items:
> +            - description: Watchdog interrupt
> +            - description: Fatal interrupt
> +            - description: Ready interrupt
> +            - description: Handover interrupt
> +            - description: Stop acknowledge interrupt
> +            - description: Shutdown acknowledge interrupt
> +        interrupt-names:
> +          items:
> +            - const: wdog
> +            - const: fatal
> +            - const: ready
> +            - const: handover
> +            - const: stop-ack
> +            - const: shutdown-ack

Both ifs should be written differently. Move the bigger list to
properties with minItems: 5. For qcom,q6v5-pil you set maxItems:5. For
qcom,msm8996-mss-pil you set minItems:6.

> +
> +  - if:
> +      properties:
> +        compatible:
> +          enum:
> +            - const: qcom,q6v5-pil
> +            - const: qcom,msm8916-mss-pil
> +            - const: qcom,msm8974-mss-pil
> +    then:
> +      properties:
> +        cx-supply:
> +          deprecated: true
> +        mx-supply:
> +          deprecated: true
> +
> +      required:
> +        - pll-supply
> +
> +  - if:
> +      properties:
> +        compatible:
> +          enum:
> +            - qcom,msm8916-mss-pil
> +            - qcom,msm8974-mss-pil
> +            - qcom,msm8996-mss-pil
> +            - qcom,msm8998-mss-pil
> +    then:
> +      properties:
> +        power-domains:
> +          items:
> +            - description: CX power domain
> +            - description: MX power domain
> +        power-domain-names:
> +          items:
> +            - const: cx
> +            - const: mx
> +
> +      required:
> +        - power-domains
> +        - power-domain-names
> +
> +  - if:
> +      properties:
> +        compatible:
> +          enum:
> +            - const: qcom,msm8996-mss-pil
> +    then:
> +      properties:
> +        cx-supply: false
> +        mx-supply: false
> +
> +      required:
> +        - pll-supply
> +
> +  - if:
> +      properties:
> +        compatible:
> +          enum:
> +            - const: qcom,qcs404-wcss-pil
> +    then:
> +      required:
> +        - cx-supply
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,sdm845-mss-pil
> +              - qcom,sc7180-mss-pil
> +    then:
> +      properties:
> +        power-domains:
> +          items:
> +            - description: CX power domain
> +            - description: MX power domain
> +            - description: MSS power domain
> +        power-domain-names:
> +          items:
> +            - const: cx
> +            - const: mx
> +            - const: mss
> +
> +      required:
> +        - power-domains
> +        - power-domain-names
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,sc7280-mss-pil
> +    then:
> +      properties:
> +        power-domains:
> +          items:
> +            - description: CX power domain
> +            - description: MSS power domain
> +        power-domain-names:
> +          items:
> +            - const: cx
> +            - const: mss
> +
> +      required:
> +        - power-domains
> +        - power-domain-names
> +        - qcom,ext-regs
> +        - qcom,qaccept-regs
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,q6v5-pil
> +              - qcom,msm8916-mss-pil
> +              - qcom,msm8974-mss-pil
> +              - qcom,msm8996-mss-pil
> +              - qcom,msm8998-mss-pil
> +    then:
> +      properties:
> +        resets:
> +          items:
> +            - description: MSS reset
> +        reset-names:
> +          items:
> +            - const: mss_restart
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,ipq8074-wcss-pil
> +              - qcom,qcs404-wcss-pil
> +    then:
> +      properties:
> +        resets:
> +          items:
> +            - description: WCSS Always On restart
> +            - description: WCSS reset
> +            - description: WCSS Q6 reset
> +        reset-names:
> +          items:
> +            - const: wcss_aon_restart
> +            - const: wcss_reset
> +            - const: wcss_q6_reset
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,sc7180-mss-pil
> +              - qcom,sc7280-mss-pil
> +              - qcom,sdm845-mss-pil
> +    then:
> +      properties:
> +        resets:
> +          items:
> +            - description: MSS restart
> +            - description: PDC reset
> +        reset-names:
> +          items:
> +            - const: mss_restart
> +            - const: pdc_reset
> +
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - qcom,q6v5-pil
> +              - qcom,ipq8074-wcss-pil
> +              - qcom,qcs404-wcss-pil
> +              - qcom,msm8916-mss-pil
> +              - qcom,msm8974-mss-pil
> +              - qcom,msm8996-mss-pil
> +              - qcom,msm8998-mss-pil
> +    then:
> +      properties:
> +        qcom,qmp: false
> +        iommus: false
> +
> +examples:
> +  - |
> +    #include <dt-bindings/clock/qcom,rpmcc.h>
> +    #include <dt-bindings/interrupt-controller/irq.h>
> +    #include <dt-bindings/clock/qcom,gcc-msm8974.h>
> +    #include <dt-bindings/reset/qcom,gcc-msm8974.h>
> +    #include <dt-bindings/interrupt-controller/arm-gic.h>
> +    modem-rproc@fc880000 {

Generic node name, so "remoteproc"

> +        compatible = "qcom,q6v5-pil";
> +        reg = <0xfc880000 0x100>,
> +              <0xfc820000 0x020>;
> +        reg-names = "qdsp6", "rmb";
> +
> +        interrupts-extended = <&intc GIC_SPI 24 IRQ_TYPE_EDGE_RISING>,
> +                              <&modem_smp2p_in 0 IRQ_TYPE_EDGE_RISING>,
> +                              <&modem_smp2p_in 1 IRQ_TYPE_EDGE_RISING>,
> +                              <&modem_smp2p_in 2 IRQ_TYPE_EDGE_RISING>,
> +                              <&modem_smp2p_in 3 IRQ_TYPE_EDGE_RISING>;
> +        interrupt-names = "wdog",
> +                          "fatal",
> +                          "ready",
> +                          "handover",
> +                          "stop-ack";
> +
> +        clocks = <&gcc GCC_MSS_Q6_BIMC_AXI_CLK>,
> +                 <&gcc GCC_MSS_CFG_AHB_CLK>,
> +                 <&gcc GCC_BOOT_ROM_AHB_CLK>,
> +                 <&xo_board>;
> +        clock-names = "iface", "bus", "mem", "xo";
> +
> +        qcom,halt-regs = <&tcsr_mutex_block 0x1180 0x1200 0x1280>;

Does this pass the tests? Did you test the bindings?

> +
> +        resets = <&gcc GCC_MSS_RESTART>;
> +        reset-names = "mss_restart";
> +
> +        cx-supply = <&pm8841_s2>;
> +        mss-supply = <&pm8841_s3>;
> +        mx-supply = <&pm8841_s1>;
> +        pll-supply = <&pm8941_l12>;
> +
> +        qcom,smem-states = <&modem_smp2p_out 0>;
> +        qcom,smem-state-names = "stop";
> +
> +        mba {
> +                memory-region = <&mba_region>;

Wrong indentation.

> +        };
> +
> +        mpss {
> +                memory-region = <&mpss_region>;
> +        };
> +
> +        smd-edge {
> +                interrupts = <GIC_SPI 25 IRQ_TYPE_EDGE_RISING>;
> +
> +                qcom,ipc = <&apcs 8 12>;
> +                qcom,smd-edge = <0>;
> +
> +                label = "modem";
> +        };
> +    };


Best regards,
Krzysztof

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

* Re: [PATCH 9/9] arm64: dts: qcom: msm8953: Add remote processor nodes
  2022-05-11 16:16 ` [PATCH 9/9] arm64: dts: qcom: msm8953: Add remote processor nodes Sireesh Kodali
@ 2022-05-11 17:55   ` Krzysztof Kozlowski
  2022-05-12  9:19     ` Sireesh Kodali
  0 siblings, 1 reply; 35+ messages in thread
From: Krzysztof Kozlowski @ 2022-05-11 17:55 UTC (permalink / raw)
  To: Sireesh Kodali, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross, Rob Herring,
	Krzysztof Kozlowski

On 11/05/2022 18:16, Sireesh Kodali wrote:
> This commit adds the modem (q6v5_mss), WiFi (wcnss-pil) and audio DSP
> (q6v5_pas) remote processor nodes for the MSM8953 platform. It also adds
> the coresponding SMP2P, SMSM and pinctrl nodes that are needed by these
> remote processors.
> 
> Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> +			};
> +
> +			wcnss_sleep: wcnss-sleep-pins {
> +				wcss_wlan2 {

No underscores in node names, unless something needs it?

> +					pins = "gpio76";
> +					function = "wcss_wlan2";
> +				};
> +				wcss_wlan1 {
> +					pins = "gpio77";
> +					function = "wcss_wlan1";
> +				};
> +				wcss_wlan0 {
> +					pins = "gpio78";
> +					function = "wcss_wlan0";
> +				};
> +				wcss_wlan {
> +					pins = "gpio79", "gpio80";
> +					function = "wcss_wlan";
> +				};
> +
> +				pinconf {
> +					pins = "gpio76", "gpio77",
> +					     "gpio78", "gpio79",
> +					     "gpio80";
> +					drive-strength = <2>;
> +					bias-pull-down;
> +				};
> +			};
>  		};
>  
>  		gcc: clock-controller@1800000 {
> @@ -745,6 +892,59 @@ spmi_bus: spmi@200f000 {
>  			#size-cells = <0>;
>  		};
>  
> +		modem: remoteproc@4080000 {
> +			compatible = "qcom,msm8953-mss-pil";
> +			reg = <0x4080000 0x100>,
> +			    <0x4020000 0x040>;
> +
> +			reg-names = "qdsp6", "rmb";
> +
> +			interrupts-extended = <&intc 0 24 1>,
> +					      <&modem_smp2p_in 0 0>,
> +					      <&modem_smp2p_in 1 0>,
> +					      <&modem_smp2p_in 2 0>,
> +					      <&modem_smp2p_in 3 0>;
> +			interrupt-names = "wdog", "fatal", "ready",
> +					  "handover", "stop-ack";
> +
> +			clocks = <&gcc GCC_MSS_CFG_AHB_CLK>,
> +				 <&gcc GCC_MSS_Q6_BIMC_AXI_CLK>,
> +				 <&gcc GCC_BOOT_ROM_AHB_CLK>,
> +				 <&xo_board>;
> +			clock-names = "iface", "bus", "mem", "xo";
> +
> +			power-domains = <&rpmpd MSM8953_VDDCX>, <&rpmpd MSM8953_VDDMX>;
> +			power-domain-names = "cx", "mx";
> +
> +			qcom,smem-states = <&modem_smp2p_out 0>;
> +			qcom,smem-state-names = "stop";
> +
> +			resets = <&gcc GCC_MSS_BCR>;
> +			reset-names = "mss_restart";
> +
> +			qcom,halt-regs = <&tcsr 0x18000 0x19000 0x1a000>;
> +
> +			status = "okay";

No need for okay.

> +
> +			mba {
> +				memory-region = <&mba_mem>;
> +			};
> +
> +			mpss {
> +				memory-region = <&mpss_mem>;
> +			};
> +
> +			smd-edge {
> +				interrupts = <GIC_SPI 25 IRQ_TYPE_EDGE_RISING>;
> +
> +				qcom,smd-edge = <0>;
> +				qcom,ipc = <&apcs 8 12>;
> +				qcom,remote-pid = <1>;
> +
> +				label = "modem";
> +			};
> +		};
> +
>  		usb3: usb@70f8800 {
>  			compatible = "qcom,msm8953-dwc3", "qcom,dwc3";
>  			reg = <0x70f8800 0x400>;
> @@ -1057,6 +1257,74 @@ i2c_8: i2c@7af8000 {
>  			status = "disabled";
>  		};
>  
> +		pronto: remoteproc@a21b000 {
> +			compatible = "qcom,pronto-v3-pil", "qcom,pronto";
> +			reg = <0xa204000 0x2000>,
> +			      <0xa202000 0x1000>,
> +			      <0xa21b000 0x3000>;
> +			reg-names = "ccu", "dxe", "pmu";
> +
> +			memory-region = <&wcnss_fw_mem>;
> +
> +			interrupts-extended = <&intc 0 149 IRQ_TYPE_EDGE_RISING>,
> +					      <&wcnss_smp2p_in 0 IRQ_TYPE_EDGE_RISING>,
> +					      <&wcnss_smp2p_in 1 IRQ_TYPE_EDGE_RISING>,
> +					      <&wcnss_smp2p_in 2 IRQ_TYPE_EDGE_RISING>,
> +					      <&wcnss_smp2p_in 3 IRQ_TYPE_EDGE_RISING>;
> +			interrupt-names = "wdog", "fatal", "ready", "handover", "stop-ack";
> +
> +			power-domains = <&rpmpd MSM8953_VDDCX>, <&rpmpd MSM8953_VDDMX>;
> +			power-domain-names = "cx", "mx";
> +
> +			qcom,state = <&wcnss_smp2p_out 0>;
> +			qcom,state-names = "stop";
> +
> +			pinctrl-names = "default", "sleep";
> +			pinctrl-0 = <&wcnss_default>;
> +			pinctrl-1 = <&wcnss_sleep>;
> +
> +			status = "okay";

No need for status.

> +
> +			iris: iris {
> +				compatible = "qcom,wcn3660b";
> +
> +				clocks = <&rpmcc RPM_SMD_RF_CLK2>;
> +				clock-names = "xo";
> +			};
> +
> +			smd-edge {
> +				interrupts = <GIC_SPI 142 IRQ_TYPE_EDGE_RISING>;
> +
> +				qcom,ipc = <&apcs 8 17>;
> +				qcom,smd-edge = <6>;
> +				qcom,remote-pid = <4>;
> +
> +				label = "pronto";
> +
> +				wcnss {
> +					compatible = "qcom,wcnss";
> +					qcom,smd-channels = "WCNSS_CTRL";
> +
> +					qcom,mmio = <&pronto>;
> +
> +					bt {
> +						compatible = "qcom,wcnss-bt";
> +					};
> +
> +					wifi {
> +						compatible = "qcom,wcnss-wlan";
> +
> +						interrupts = <GIC_SPI 145 IRQ_TYPE_LEVEL_HIGH>,
> +							     <GIC_SPI 146 IRQ_TYPE_LEVEL_HIGH>;
> +						interrupt-names = "tx", "rx";
> +
> +						qcom,smem-states = <&apps_smsm 10>, <&apps_smsm 9>;
> +						qcom,smem-state-names = "tx-enable", "tx-rings-empty";
> +					};
> +				};
> +			};
> +		};
> +
>  		intc: interrupt-controller@b000000 {
>  			compatible = "qcom,msm-qgic2";
>  			interrupt-controller;
> @@ -1070,6 +1338,116 @@ apcs: mailbox@b011000 {
>  			#mbox-cells = <1>;
>  		};
>  
> +		lpass: remoteproc@c200000 {
> +			compatible = "qcom,msm8953-adsp-pil";
> +			reg = <0xc200000 0x100>;
> +
> +			interrupts-extended = <&intc 0 293 IRQ_TYPE_EDGE_RISING>,
> +					      <&smp2p_adsp_in 0 IRQ_TYPE_EDGE_RISING>,
> +					      <&smp2p_adsp_in 1 IRQ_TYPE_EDGE_RISING>,
> +					      <&smp2p_adsp_in 2 IRQ_TYPE_EDGE_RISING>,
> +					      <&smp2p_adsp_in 3 IRQ_TYPE_EDGE_RISING>;
> +			interrupt-names = "wdog", "fatal", "ready",
> +					  "handover", "stop-ack";
> +			clocks = <&xo_board>;
> +			clock-names = "xo";
> +
> +			power-domains = <&rpmpd MSM8953_VDDCX>;
> +			power-domain-names = "cx";
> +
> +			memory-region = <&adsp_fw_mem>;
> +
> +			qcom,smem-states = <&smp2p_adsp_out 0>;
> +			qcom,smem-state-names = "stop";
> +
> +			smd-edge {
> +				interrupts = <GIC_SPI 289 IRQ_TYPE_EDGE_RISING>;
> +
> +				label = "lpass";
> +				mboxes = <&apcs 8>;
> +				qcom,smd-edge = <1>;
> +				qcom,remote-pid = <2>;
> +				#address-cells = <1>;
> +				#size-cells = <0>;
> +
> +				apr {
> +					compatible = "qcom,apr-v2";
> +					qcom,smd-channels = "apr_audio_svc";
> +					qcom,apr-domain = <APR_DOMAIN_ADSP>;
> +					#address-cells = <1>;
> +					#size-cells = <0>;
> +
> +					q6core {
> +						reg = <APR_SVC_ADSP_CORE>;
> +						compatible = "qcom,q6core";
> +					};
> +
> +					q6afe: q6afe {
> +						compatible = "qcom,q6afe";
> +						reg = <APR_SVC_AFE>;
> +						q6afedai: dais {
> +							compatible = "qcom,q6afe-dais";
> +							#address-cells = <1>;
> +							#size-cells = <0>;
> +							#sound-dai-cells = <1>;
> +
> +							dai@16 {
> +								reg = <PRIMARY_MI2S_RX>;
> +								qcom,sd-lines = <0 1>;
> +							};
> +
> +							dai@21 {
> +								reg = <TERTIARY_MI2S_TX>;
> +								qcom,sd-lines = <0 1>;
> +							};
> +						};
> +						q6afecc: clock-controller {
> +							compatible = "qcom,q6afe-clocks";
> +							#clock-cells = <2>;
> +						};
> +					};
> +
> +					q6asm: q6asm {
> +						compatible = "qcom,q6asm";
> +						reg = <APR_SVC_ASM>;
> +						q6asmdai: dais {
> +							compatible = "qcom,q6asm-dais";
> +							#address-cells = <1>;
> +							#size-cells = <0>;
> +							#sound-dai-cells = <1>;
> +
> +							dai@0 {
> +								reg = <MSM_FRONTEND_DAI_MULTIMEDIA1>;
> +							};
> +
> +							dai@1 {
> +								reg = <MSM_FRONTEND_DAI_MULTIMEDIA2>;
> +							};
> +
> +							dai@2 {
> +								reg = <MSM_FRONTEND_DAI_MULTIMEDIA3>;
> +							};
> +
> +							dai@3 {
> +								reg = <MSM_FRONTEND_DAI_MULTIMEDIA4>;
> +								is-compress-dai;
> +							};
> +						};
> +					};
> +
> +					q6adm: q6adm {
> +						compatible = "qcom,q6adm";
> +						reg = <APR_SVC_ADM>;
> +						q6routing: routing {
> +							compatible = "qcom,q6adm-routing";
> +							#sound-dai-cells = <0>;
> +						};
> +					};
> +				};
> +			};
> +

Remove unneeded blank lines.

> +		};
> +
>  		timer@b120000 {
>  			compatible = "arm,armv7-timer-mem";
>  			reg = <0xb120000 0x1000>;


Best regards,
Krzysztof

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

* Re: [PATCH 2/9] remoteproc: qcom: q6v5-mss: Add modem support on MSM8953
  2022-05-11 16:54   ` Dmitry Baryshkov
@ 2022-05-12  5:16     ` Sireesh Kodali
  2022-05-12 10:38     ` Sireesh Kodali
  1 sibling, 0 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-12  5:16 UTC (permalink / raw)
  To: Dmitry Baryshkov, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier

On Wed May 11, 2022 at 10:24 PM IST, Dmitry Baryshkov wrote:
> On 11/05/2022 19:15, Sireesh Kodali wrote:
> > The modem on the MSM8953 platform is similar to the modem on the MSM8996
> > platform in terms of set up. It differs primarily in the way it needs SCM
> > to bless the MPSS firmware region.
> > 
> > Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> > ---
> >   drivers/remoteproc/qcom_q6v5_mss.c | 64 +++++++++++++++++++++++++++---
> >   1 file changed, 58 insertions(+), 6 deletions(-)
> > 
> > diff --git a/drivers/remoteproc/qcom_q6v5_mss.c b/drivers/remoteproc/qcom_q6v5_mss.c
> > index af217de75e4d..a73fdcddeda4 100644
> > --- a/drivers/remoteproc/qcom_q6v5_mss.c
> > +++ b/drivers/remoteproc/qcom_q6v5_mss.c
> > @@ -234,6 +234,7 @@ struct q6v5 {
> >   
> >   enum {
> >   	MSS_MSM8916,
> > +	MSS_MSM8953,
> >   	MSS_MSM8974,
> >   	MSS_MSM8996,
> >   	MSS_MSM8998,
> > @@ -687,12 +688,14 @@ static int q6v5proc_reset(struct q6v5 *qproc)
> >   		}
> >   		goto pbl_wait;
> >   	} else if (qproc->version == MSS_MSM8996 ||
> > -		   qproc->version == MSS_MSM8998) {
> > +		   qproc->version == MSS_MSM8998 ||
> > +		   qproc->version == MSS_MSM8953) {
> >   		int mem_pwr_ctl;
> >   
> >   		/* Override the ACC value if required */
> > -		writel(QDSP6SS_ACC_OVERRIDE_VAL,
> > -		       qproc->reg_base + QDSP6SS_STRAP_ACC);
> > +		if (qproc->version != MSS_MSM8953)
> > +			writel(QDSP6SS_ACC_OVERRIDE_VAL,
> > +					qproc->reg_base + QDSP6SS_STRAP_ACC);
> >   
> >   		/* Assert resets, stop core */
> >   		val = readl(qproc->reg_base + QDSP6SS_RESET_REG);
> > @@ -734,7 +737,8 @@ static int q6v5proc_reset(struct q6v5 *qproc)
> >   		writel(val, qproc->reg_base + QDSP6SS_PWR_CTL_REG);
> >   
> >   		/* Turn on L1, L2, ETB and JU memories 1 at a time */
> > -		if (qproc->version == MSS_MSM8996) {
> > +		if (qproc->version == MSS_MSM8996 ||
> > +			qproc->version == MSS_MSM8953) {
> >   			mem_pwr_ctl = QDSP6SS_MEM_PWR_CTL;
> >   			i = 19;
> >   		} else {
> > @@ -1314,7 +1318,16 @@ static int q6v5_mpss_load(struct q6v5 *qproc)
> >   			max_addr = ALIGN(phdr->p_paddr + phdr->p_memsz, SZ_4K);
> >   	}
> >   
> > -	/*
> > +	if (qproc->version == MSS_MSM8953) {
> > +		ret = qcom_scm_pas_mem_setup(5, qproc->mpss_phys, qproc->mpss_size);
> > +		if (ret) {
> > +			dev_err(qproc->dev,
> > +					"setting up mpss memory failed: %d\n", ret);
> > +			goto release_firmware;
> > +		}
> > +	}
> > +
> > +	/**
>
> Single star please
>
> >   	 * In case of a modem subsystem restart on secure devices, the modem
> >   	 * memory can be reclaimed only after MBA is loaded.
> >   	 */
> > @@ -1413,7 +1426,6 @@ static int q6v5_mpss_load(struct q6v5 *qproc)
> >   			writel(RMB_CMD_LOAD_READY, qproc->rmb_base + RMB_MBA_COMMAND_REG);
> >   		}
> >   		writel(size, qproc->rmb_base + RMB_PMI_CODE_LENGTH_REG);
> > -
> >   		ret = readl(qproc->rmb_base + RMB_MBA_STATUS_REG);
> >   		if (ret < 0) {
> >   			dev_err(qproc->dev, "MPSS authentication failed: %d\n",
> > @@ -1422,6 +1434,7 @@ static int q6v5_mpss_load(struct q6v5 *qproc)
> >   		}
> >   	}
> >   
> > +
>
> Unnecessary
>

oops

> >   	/* Transfer ownership of modem ddr region to q6 */
> >   	ret = q6v5_xfer_mem_ownership(qproc, &qproc->mpss_perm, false, true,
> >   				      qproc->mpss_phys, qproc->mpss_size);
> > @@ -2198,6 +2211,44 @@ static const struct rproc_hexagon_res msm8996_mss = {
> >   	.version = MSS_MSM8996,
> >   };
> >   
> > +static const struct rproc_hexagon_res msm8953_mss = {
> > +	.hexagon_mba_image = "mba.mbn",
> > +	.proxy_supply = (struct qcom_mss_reg_res[]) {
> > +		{
> > +			.supply = "pll",
> > +			.uA = 100000,
> > +		},
> > +		{}
> > +	},
> > +	.proxy_pd_names = (char*[]) {
> > +			"cx",
> > +			"mx",
> > +			NULL
> > +	},
> > +	.active_supply = (struct qcom_mss_reg_res[]) {
> > +		{
> > +			.supply = "mss",
> > +			.uV = 1050000,
> > +			.uA = 100000,
> > +		},
> > +		{}
> > +	},
> > +	.proxy_clk_names = (char*[]){
> > +			"xo",
> > +			NULL
> > +	},
> > +	.active_clk_names = (char*[]){
> > +			"iface",
> > +			"bus",
> > +			"mem",
> > +			NULL
> > +	},
> > +	.need_mem_protection = false,
> > +	.has_alt_reset = false,
> > +	.has_spare_reg = false,
>
>
> Please follow the custom  and define the rest of fields here.
>

I missed these in the rebase, I'll add them in v2

> > +	.version = MSS_MSM8953,
> > +};
> > +
> >   static const struct rproc_hexagon_res msm8916_mss = {
> >   	.hexagon_mba_image = "mba.mbn",
> >   	.proxy_supply = (struct qcom_mss_reg_res[]) {
> > @@ -2301,6 +2352,7 @@ static const struct of_device_id q6v5_of_match[] = {
> >   	{ .compatible = "qcom,msm8916-mss-pil", .data = &msm8916_mss},
> >   	{ .compatible = "qcom,msm8974-mss-pil", .data = &msm8974_mss},
> >   	{ .compatible = "qcom,msm8996-mss-pil", .data = &msm8996_mss},
> > +	{ .compatible = "qcom,msm8953-mss-pil", .data = &msm8953_mss},
> >   	{ .compatible = "qcom,msm8998-mss-pil", .data = &msm8998_mss},
> >   	{ .compatible = "qcom,sc7180-mss-pil", .data = &sc7180_mss},
> >   	{ .compatible = "qcom,sc7280-mss-pil", .data = &sc7280_mss},
>
>
> -- 
> With best wishes
> Dmitry

Thank you for the review, I'll make the changes in v2 of this patch.

Thanks,
Sireesh

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

* Re: [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML
  2022-05-11 17:15   ` Krzysztof Kozlowski
@ 2022-05-12  6:50     ` Sireesh Kodali
  2022-05-12  8:14       ` Krzysztof Kozlowski
  2022-05-12  8:36       ` Krzysztof Kozlowski
  0 siblings, 2 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-12  6:50 UTC (permalink / raw)
  To: Krzysztof Kozlowski, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier, Rob Herring, Krzysztof Kozlowski

On Wed May 11, 2022 at 10:45 PM IST, Krzysztof Kozlowski wrote:
> On 11/05/2022 18:15, Sireesh Kodali wrote:
> > Convert the dt-bindings from txt to YAML. This is in preparation for
> > including the relevant bindings for the MSM8953 platform's wcnss pil.
> > 
> > Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
>
> Thank you for your patch. There is something to discuss/improve.
>
> Please use existing bindings or example-schema as a starting point. Half
> of my review could be skipped if you just followed what we already have
> in the tree.
>
> Some of these qcom specific properties already exist but you decided to
> write them differently... please don't, rather reuse the code.
>

Thank you for your review, I will make the chnages as appropriate in v2.
> (...)
>
> > +
> > +maintainers:
> > +  - Bjorn Andersson <bjorn.andersson@linaro.org>
> > +
> > +description:
> > +  This document defines the binding for a component that loads and boots
> > +  firmware on the Qualcomm WCNSS core.
> > +
> > +properties:
> > +  compatible:
> > +    oneOf:
> > +      - items:
> > +          - enum:
> > +              - qcom,pronto-v2-pil
> > +          - enum:
> > +              - qcom,pronto
>
> This does not look correct. The fallback compatible should not change.
> What is more, it was not documented in original binding, so this should
> be done in separate patch.
>

This was not a change to the fallback compatible. msm8916.dtsi's wcnss
node has "qcom,pronto" as the compatible string, which is why this was
added. It is however not documented in the txt file. Is it sufficient to
add a note in the commit message, or should it be split into a separate
commit?

> > +      - items:
>
> No need for items, it's just one item.
>
> > +          - enum:
> > +              - qcom,riva-pil
> > +              - qcom,pronto-v1-pil
> > +              - qcom,pronto-v2-pil
> > +
> > +  reg:
> > +    description: must specify the base address and size of the CCU, DXE and PMU
> > +      register blocks
>
> New line after "decription:", drop "must specify" and start with capital
> letter.
>
> You need maxItems: 3
>

Will fix in v2
>
> > +
> > +  reg-names:
> > +    items:
> > +      - const: ccu
> > +      - const: dxe
> > +      - const: pmu
> > +
> > +  interrupts-extended:
> > +    description:
> > +      Interrupt lines
>
> Skip description, it's obvious.
>
> It should be only "interrupts", not extended.
>
> > +    minItems: 2
> > +    maxItems: 5
> > +
> > +  interrupt-names:
> > +    minItems: 2
> > +    maxItems: 5
>
> Names should be clearly defined. They were BTW defined in original
> bindings, so you should not remove them. This makes me wonder what else
> did you remove from original bindings...
>
> Please document all deviations from pure conversion in the commit msg.
> It's a second "hidden" difference.
>

Sorry, this was meant to be a pure txt->YAML conversion. The missing
interrupt names was accidental, and will be fixed in v2.
> > +
> > +  firmware-name:
> > +    $ref: /schemas/types.yaml#/definitions/string
> > +    description: Relative firmware image path for the WCNSS core. Defaults to
> > +      "wcnss.mdt".
>
>
> Blank line after "description:". This applies to other places as well.
>
> Remove "Defailts to ..." and just add "default" schema.
>

Will be fixed in v2
> > +
> > +  vddpx-supply:
> > +    description: Reference to the PX regulator to be held on behalf of the
> > +      booting of the WCNSS core
> > +
> > +  vddmx-supply:
> > +    description: Reference to the MX regulator to be held on behalf of the
> > +      booting of the WCNSS core.
> > +
> > +  vddcx-supply:
> > +    description: Reference to the CX regulator to be held on behalf of the
> > +      booting of the WCNSS core.
>
> s/Reference to the//
>
> > +
> > +  power-domains:
> > +    $ref: /schemas/types.yaml#/definitions/phandle-array
> > +    description: References to the power domains that need to be held on
> > +      behalf of the booting WCNSS core
>
> 1. Ditto.
> 2. No need for ref
> 3. maxItems
>
> > +
> > +  power-domain-names:
> > +    $ref: /schemas/types.yaml#/definitions/string-array
>
> No need for ref, skip description.
>
> > +    description: Names of the power domains
> > +    items:
> > +      - const: cx
> > +      - const: mx
> > +
> > +  qcom,smem-states:
> > +    $ref: /schemas/types.yaml#/definitions/phandle-array
> > +    description: States used by the AP to signal the WCNSS core that it should
> > +      shutdown
> > +    items:
> > +      - description: Stop the modem
> > +
> > +  qcom,smem-state-names:
> > +    $ref: /schemas/types.yaml#/definitions/string-array
>
> No need for ref. Really, it does not appear in any of existing bindings
> for smem-state-names, so how did you get it?
>

The smem nodes were copied from /remoteproc/qcom,sdm845-adsp-pil.yaml

> > +    description: The names of the state bits used for SMP2P output
> > +    items:
> > +      - const: stop
> > +
> > +  memory-region:
> > +    maxItems: 1
> > +    description: Reference to the reserved-memory for the WCNSS core
> > +
> > +  smd-edge:
> > +    type: object
> > +    description:
> > +      Qualcomm Shared Memory subnode which represents communication edge,
> > +      channels and devices related to the ADSP.
>
> You should reference /schemas/soc/qcom/qcom,smd.yaml

Will be done in v2
>
> > +
> > +  iris:
>
> Generic node name... what is "iris"?
>
Iris is the RF module, I'll make the description better

> > +    type: object
> > +    description:
> > +      The iris subnode of the WCNSS PIL is used to describe the attached rf module
>
> s/rf/RF/
>
> > +      and its resource dependencies.
> > +
> > +    properties:
> > +      compatible:
> > +        enum:
> > +          - qcom,wcn3620
> > +          - qcom,wcn3660
> > +          - qcom,wcn3660b
> > +          - qcom,wcn3680
> > +
> > +      clocks:
> > +        description: XO clock
> > +
> > +      clock-names:
> > +        items:
> > +          - const: xo
> > +
> > +    required:
> > +      - compatible
>
> clocks and clock-names were required.
> Missing supplies, which were btw as well required.
>
This was unintentional, it will be fixed in v2.

> > +
> > +required:
> > +  - compatible
> > +  - reg
> > +  - reg-names
> > +  - interrupts-extended
> > +  - interrupt-names
> > +  - vddpx-supply
> > +  - memory-region
> > +  - smd-edge
> > +  - iris
> > +
> > +additionalProperties: false
> > +
> > +if:
>
> Within allOf, please.
>

Will be fixed in v2
>
>
> Best regards,
> Krzysztof

Thanks again for the review,
Sireesh

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

* Re: [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML
  2022-05-12  6:50     ` Sireesh Kodali
@ 2022-05-12  8:14       ` Krzysztof Kozlowski
  2022-05-12  9:32         ` Sireesh Kodali
  2022-05-12  8:36       ` Krzysztof Kozlowski
  1 sibling, 1 reply; 35+ messages in thread
From: Krzysztof Kozlowski @ 2022-05-12  8:14 UTC (permalink / raw)
  To: Sireesh Kodali, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier, Rob Herring, Krzysztof Kozlowski

On 12/05/2022 08:50, Sireesh Kodali wrote:
> On Wed May 11, 2022 at 10:45 PM IST, Krzysztof Kozlowski wrote:
>> On 11/05/2022 18:15, Sireesh Kodali wrote:
>>> Convert the dt-bindings from txt to YAML. This is in preparation for
>>> including the relevant bindings for the MSM8953 platform's wcnss pil.
>>>
>>> Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
>>
>> Thank you for your patch. There is something to discuss/improve.
>>
>> Please use existing bindings or example-schema as a starting point. Half
>> of my review could be skipped if you just followed what we already have
>> in the tree.
>>
>> Some of these qcom specific properties already exist but you decided to
>> write them differently... please don't, rather reuse the code.
>>
> 
> Thank you for your review, I will make the chnages as appropriate in v2.
>> (...)
>>
>>> +
>>> +maintainers:
>>> +  - Bjorn Andersson <bjorn.andersson@linaro.org>
>>> +
>>> +description:
>>> +  This document defines the binding for a component that loads and boots
>>> +  firmware on the Qualcomm WCNSS core.
>>> +
>>> +properties:
>>> +  compatible:
>>> +    oneOf:
>>> +      - items:
>>> +          - enum:
>>> +              - qcom,pronto-v2-pil
>>> +          - enum:
>>> +              - qcom,pronto
>>
>> This does not look correct. The fallback compatible should not change.
>> What is more, it was not documented in original binding, so this should
>> be done in separate patch.
>>
> 
> This was not a change to the fallback compatible. 

You made it an enum, so you expect it to use different fallback for
different cases.

> msm8916.dtsi's wcnss
> node has "qcom,pronto" as the compatible string, which is why this was
> added. It is however not documented in the txt file. Is it sufficient to
> add a note in the commit message, or should it be split into a separate
> commit?

Please split it, assuming that fallback is correct. Maybe the fallback
is wrong?

> 
>>> +      - items:
>>
>> No need for items, it's just one item.
>>
>>> +          - enum:
>>> +              - qcom,riva-pil
>>> +              - qcom,pronto-v1-pil
>>> +              - qcom,pronto-v2-pil
>>> +
>>> +  reg:
>>> +    description: must specify the base address and size of the CCU, DXE and PMU
>>> +      register blocks
>>
>> New line after "decription:", drop "must specify" and start with capital
>> letter.
>>
>> You need maxItems: 3
>>
> 
> Will fix in v2
>>
>>> +
>>> +  reg-names:
>>> +    items:
>>> +      - const: ccu
>>> +      - const: dxe
>>> +      - const: pmu
>>> +
>>> +  interrupts-extended:
>>> +    description:
>>> +      Interrupt lines
>>
>> Skip description, it's obvious.
>>
>> It should be only "interrupts", not extended.
>>
>>> +    minItems: 2
>>> +    maxItems: 5
>>> +
>>> +  interrupt-names:
>>> +    minItems: 2
>>> +    maxItems: 5
>>
>> Names should be clearly defined. They were BTW defined in original
>> bindings, so you should not remove them. This makes me wonder what else
>> did you remove from original bindings...
>>
>> Please document all deviations from pure conversion in the commit msg.
>> It's a second "hidden" difference.
>>
> 
> Sorry, this was meant to be a pure txt->YAML conversion. The missing
> interrupt names was accidental, and will be fixed in v2.
>>> +
>>> +  firmware-name:
>>> +    $ref: /schemas/types.yaml#/definitions/string
>>> +    description: Relative firmware image path for the WCNSS core. Defaults to
>>> +      "wcnss.mdt".
>>
>>
>> Blank line after "description:". This applies to other places as well.
>>
>> Remove "Defailts to ..." and just add "default" schema.
>>
> 
> Will be fixed in v2
>>> +
>>> +  vddpx-supply:
>>> +    description: Reference to the PX regulator to be held on behalf of the
>>> +      booting of the WCNSS core
>>> +
>>> +  vddmx-supply:
>>> +    description: Reference to the MX regulator to be held on behalf of the
>>> +      booting of the WCNSS core.
>>> +
>>> +  vddcx-supply:
>>> +    description: Reference to the CX regulator to be held on behalf of the
>>> +      booting of the WCNSS core.
>>
>> s/Reference to the//
>>
>>> +
>>> +  power-domains:
>>> +    $ref: /schemas/types.yaml#/definitions/phandle-array
>>> +    description: References to the power domains that need to be held on
>>> +      behalf of the booting WCNSS core
>>
>> 1. Ditto.
>> 2. No need for ref
>> 3. maxItems
>>
>>> +
>>> +  power-domain-names:
>>> +    $ref: /schemas/types.yaml#/definitions/string-array
>>
>> No need for ref, skip description.
>>
>>> +    description: Names of the power domains
>>> +    items:
>>> +      - const: cx
>>> +      - const: mx
>>> +
>>> +  qcom,smem-states:
>>> +    $ref: /schemas/types.yaml#/definitions/phandle-array
>>> +    description: States used by the AP to signal the WCNSS core that it should
>>> +      shutdown
>>> +    items:
>>> +      - description: Stop the modem
>>> +
>>> +  qcom,smem-state-names:
>>> +    $ref: /schemas/types.yaml#/definitions/string-array
>>
>> No need for ref. Really, it does not appear in any of existing bindings
>> for smem-state-names, so how did you get it?
>>
> 
> The smem nodes were copied from /remoteproc/qcom,sdm845-adsp-pil.yaml

Hm, indeed, you're right. There are few files having here ref. I'll fix
these.

> 
>>> +    description: The names of the state bits used for SMP2P output
>>> +    items:
>>> +      - const: stop
>>> +
>>> +  memory-region:
>>> +    maxItems: 1
>>> +    description: Reference to the reserved-memory for the WCNSS core
>>> +
>>> +  smd-edge:
>>> +    type: object
>>> +    description:
>>> +      Qualcomm Shared Memory subnode which represents communication edge,
>>> +      channels and devices related to the ADSP.
>>
>> You should reference /schemas/soc/qcom/qcom,smd.yaml
> 
> Will be done in v2
>>
>>> +
>>> +  iris:
>>
>> Generic node name... what is "iris"?
>>
> Iris is the RF module, I'll make the description better

RF like wifi? Then the property name should be "wifi".



Best regards,
Krzysztof

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

* Re: [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML
  2022-05-12  6:50     ` Sireesh Kodali
  2022-05-12  8:14       ` Krzysztof Kozlowski
@ 2022-05-12  8:36       ` Krzysztof Kozlowski
  2022-05-12 10:01         ` Sireesh Kodali
  1 sibling, 1 reply; 35+ messages in thread
From: Krzysztof Kozlowski @ 2022-05-12  8:36 UTC (permalink / raw)
  To: Sireesh Kodali, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier, Rob Herring, Krzysztof Kozlowski

On 12/05/2022 08:50, Sireesh Kodali wrote:
>>> +    description: The names of the state bits used for SMP2P output
>>> +    items:
>>> +      - const: stop
>>> +
>>> +  memory-region:
>>> +    maxItems: 1
>>> +    description: Reference to the reserved-memory for the WCNSS core
>>> +
>>> +  smd-edge:
>>> +    type: object
>>> +    description:
>>> +      Qualcomm Shared Memory subnode which represents communication edge,
>>> +      channels and devices related to the ADSP.
>>
>> You should reference /schemas/soc/qcom/qcom,smd.yaml

It seems it is not a SMD driver so above reference is not correct. This
should be probably described in its own schema, I just need to
understand what's this...


Best regards,
Krzysztof

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

* Re: [PATCH 9/9] arm64: dts: qcom: msm8953: Add remote processor nodes
  2022-05-11 17:55   ` Krzysztof Kozlowski
@ 2022-05-12  9:19     ` Sireesh Kodali
  2022-05-12 14:37       ` Krzysztof Kozlowski
  0 siblings, 1 reply; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-12  9:19 UTC (permalink / raw)
  To: Krzysztof Kozlowski, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross, Rob Herring,
	Krzysztof Kozlowski

On Wed May 11, 2022 at 11:25 PM IST, Krzysztof Kozlowski wrote:
> On 11/05/2022 18:16, Sireesh Kodali wrote:
> > This commit adds the modem (q6v5_mss), WiFi (wcnss-pil) and audio DSP
> > (q6v5_pas) remote processor nodes for the MSM8953 platform. It also adds
> > the coresponding SMP2P, SMSM and pinctrl nodes that are needed by these
> > remote processors.
> > 
> > Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> > +			};
> > +
> > +			wcnss_sleep: wcnss-sleep-pins {
> > +				wcss_wlan2 {
>
> No underscores in node names, unless something needs it?
>

wcnss_sleep is used by the pronto node defined below

> > +					pins = "gpio76";
> > +					function = "wcss_wlan2";
> > +				};
> > +				wcss_wlan1 {
> > +					pins = "gpio77";
> > +					function = "wcss_wlan1";
> > +				};
> > +				wcss_wlan0 {
> > +					pins = "gpio78";
> > +					function = "wcss_wlan0";
> > +				};
> > +				wcss_wlan {
> > +					pins = "gpio79", "gpio80";
> > +					function = "wcss_wlan";
> > +				};
> > +
> > +				pinconf {
> > +					pins = "gpio76", "gpio77",
> > +					     "gpio78", "gpio79",
> > +					     "gpio80";
> > +					drive-strength = <2>;
> > +					bias-pull-down;
> > +				};
> > +			};
> >  		};
> >  
> >  		gcc: clock-controller@1800000 {
> > @@ -745,6 +892,59 @@ spmi_bus: spmi@200f000 {
> >  			#size-cells = <0>;
> >  		};
> >  
> > +		modem: remoteproc@4080000 {
> > +			compatible = "qcom,msm8953-mss-pil";
> > +			reg = <0x4080000 0x100>,
> > +			    <0x4020000 0x040>;
> > +
> > +			reg-names = "qdsp6", "rmb";
> > +
> > +			interrupts-extended = <&intc 0 24 1>,
> > +					      <&modem_smp2p_in 0 0>,
> > +					      <&modem_smp2p_in 1 0>,
> > +					      <&modem_smp2p_in 2 0>,
> > +					      <&modem_smp2p_in 3 0>;
> > +			interrupt-names = "wdog", "fatal", "ready",
> > +					  "handover", "stop-ack";
> > +
> > +			clocks = <&gcc GCC_MSS_CFG_AHB_CLK>,
> > +				 <&gcc GCC_MSS_Q6_BIMC_AXI_CLK>,
> > +				 <&gcc GCC_BOOT_ROM_AHB_CLK>,
> > +				 <&xo_board>;
> > +			clock-names = "iface", "bus", "mem", "xo";
> > +
> > +			power-domains = <&rpmpd MSM8953_VDDCX>, <&rpmpd MSM8953_VDDMX>;
> > +			power-domain-names = "cx", "mx";
> > +
> > +			qcom,smem-states = <&modem_smp2p_out 0>;
> > +			qcom,smem-state-names = "stop";
> > +
> > +			resets = <&gcc GCC_MSS_BCR>;
> > +			reset-names = "mss_restart";
> > +
> > +			qcom,halt-regs = <&tcsr 0x18000 0x19000 0x1a000>;
> > +
> > +			status = "okay";
>
> No need for okay.

I'll drop it in v2
>
> > +
> > +			mba {
> > +				memory-region = <&mba_mem>;
> > +			};
> > +
> > +			mpss {
> > +				memory-region = <&mpss_mem>;
> > +			};
> > +
> > +			smd-edge {
> > +				interrupts = <GIC_SPI 25 IRQ_TYPE_EDGE_RISING>;
> > +
> > +				qcom,smd-edge = <0>;
> > +				qcom,ipc = <&apcs 8 12>;
> > +				qcom,remote-pid = <1>;
> > +
> > +				label = "modem";
> > +			};
> > +		};
> > +
> >  		usb3: usb@70f8800 {
> >  			compatible = "qcom,msm8953-dwc3", "qcom,dwc3";
> >  			reg = <0x70f8800 0x400>;
> > @@ -1057,6 +1257,74 @@ i2c_8: i2c@7af8000 {
> >  			status = "disabled";
> >  		};
> >  
> > +		pronto: remoteproc@a21b000 {
> > +			compatible = "qcom,pronto-v3-pil", "qcom,pronto";
> > +			reg = <0xa204000 0x2000>,
> > +			      <0xa202000 0x1000>,
> > +			      <0xa21b000 0x3000>;
> > +			reg-names = "ccu", "dxe", "pmu";
> > +
> > +			memory-region = <&wcnss_fw_mem>;
> > +
> > +			interrupts-extended = <&intc 0 149 IRQ_TYPE_EDGE_RISING>,
> > +					      <&wcnss_smp2p_in 0 IRQ_TYPE_EDGE_RISING>,
> > +					      <&wcnss_smp2p_in 1 IRQ_TYPE_EDGE_RISING>,
> > +					      <&wcnss_smp2p_in 2 IRQ_TYPE_EDGE_RISING>,
> > +					      <&wcnss_smp2p_in 3 IRQ_TYPE_EDGE_RISING>;
> > +			interrupt-names = "wdog", "fatal", "ready", "handover", "stop-ack";
> > +
> > +			power-domains = <&rpmpd MSM8953_VDDCX>, <&rpmpd MSM8953_VDDMX>;
> > +			power-domain-names = "cx", "mx";
> > +
> > +			qcom,state = <&wcnss_smp2p_out 0>;
> > +			qcom,state-names = "stop";
> > +
> > +			pinctrl-names = "default", "sleep";
> > +			pinctrl-0 = <&wcnss_default>;
> > +			pinctrl-1 = <&wcnss_sleep>;
> > +
> > +			status = "okay";
>
> No need for status.

Will be dropped in v2
>
> > +
> > +			iris: iris {
> > +				compatible = "qcom,wcn3660b";
> > +
> > +				clocks = <&rpmcc RPM_SMD_RF_CLK2>;
> > +				clock-names = "xo";
> > +			};
> > +
> > +			smd-edge {
> > +				interrupts = <GIC_SPI 142 IRQ_TYPE_EDGE_RISING>;
> > +
> > +				qcom,ipc = <&apcs 8 17>;
> > +				qcom,smd-edge = <6>;
> > +				qcom,remote-pid = <4>;
> > +
> > +				label = "pronto";
> > +
> > +				wcnss {
> > +					compatible = "qcom,wcnss";
> > +					qcom,smd-channels = "WCNSS_CTRL";
> > +
> > +					qcom,mmio = <&pronto>;
> > +
> > +					bt {
> > +						compatible = "qcom,wcnss-bt";
> > +					};
> > +
> > +					wifi {
> > +						compatible = "qcom,wcnss-wlan";
> > +
> > +						interrupts = <GIC_SPI 145 IRQ_TYPE_LEVEL_HIGH>,
> > +							     <GIC_SPI 146 IRQ_TYPE_LEVEL_HIGH>;
> > +						interrupt-names = "tx", "rx";
> > +
> > +						qcom,smem-states = <&apps_smsm 10>, <&apps_smsm 9>;
> > +						qcom,smem-state-names = "tx-enable", "tx-rings-empty";
> > +					};
> > +				};
> > +			};
> > +		};
> > +
> >  		intc: interrupt-controller@b000000 {
> >  			compatible = "qcom,msm-qgic2";
> >  			interrupt-controller;
> > @@ -1070,6 +1338,116 @@ apcs: mailbox@b011000 {
> >  			#mbox-cells = <1>;
> >  		};
> >  
> > +		lpass: remoteproc@c200000 {
> > +			compatible = "qcom,msm8953-adsp-pil";
> > +			reg = <0xc200000 0x100>;
> > +
> > +			interrupts-extended = <&intc 0 293 IRQ_TYPE_EDGE_RISING>,
> > +					      <&smp2p_adsp_in 0 IRQ_TYPE_EDGE_RISING>,
> > +					      <&smp2p_adsp_in 1 IRQ_TYPE_EDGE_RISING>,
> > +					      <&smp2p_adsp_in 2 IRQ_TYPE_EDGE_RISING>,
> > +					      <&smp2p_adsp_in 3 IRQ_TYPE_EDGE_RISING>;
> > +			interrupt-names = "wdog", "fatal", "ready",
> > +					  "handover", "stop-ack";
> > +			clocks = <&xo_board>;
> > +			clock-names = "xo";
> > +
> > +			power-domains = <&rpmpd MSM8953_VDDCX>;
> > +			power-domain-names = "cx";
> > +
> > +			memory-region = <&adsp_fw_mem>;
> > +
> > +			qcom,smem-states = <&smp2p_adsp_out 0>;
> > +			qcom,smem-state-names = "stop";
> > +
> > +			smd-edge {
> > +				interrupts = <GIC_SPI 289 IRQ_TYPE_EDGE_RISING>;
> > +
> > +				label = "lpass";
> > +				mboxes = <&apcs 8>;
> > +				qcom,smd-edge = <1>;
> > +				qcom,remote-pid = <2>;
> > +				#address-cells = <1>;
> > +				#size-cells = <0>;
> > +
> > +				apr {
> > +					compatible = "qcom,apr-v2";
> > +					qcom,smd-channels = "apr_audio_svc";
> > +					qcom,apr-domain = <APR_DOMAIN_ADSP>;
> > +					#address-cells = <1>;
> > +					#size-cells = <0>;
> > +
> > +					q6core {
> > +						reg = <APR_SVC_ADSP_CORE>;
> > +						compatible = "qcom,q6core";
> > +					};
> > +
> > +					q6afe: q6afe {
> > +						compatible = "qcom,q6afe";
> > +						reg = <APR_SVC_AFE>;
> > +						q6afedai: dais {
> > +							compatible = "qcom,q6afe-dais";
> > +							#address-cells = <1>;
> > +							#size-cells = <0>;
> > +							#sound-dai-cells = <1>;
> > +
> > +							dai@16 {
> > +								reg = <PRIMARY_MI2S_RX>;
> > +								qcom,sd-lines = <0 1>;
> > +							};
> > +
> > +							dai@21 {
> > +								reg = <TERTIARY_MI2S_TX>;
> > +								qcom,sd-lines = <0 1>;
> > +							};
> > +						};
> > +						q6afecc: clock-controller {
> > +							compatible = "qcom,q6afe-clocks";
> > +							#clock-cells = <2>;
> > +						};
> > +					};
> > +
> > +					q6asm: q6asm {
> > +						compatible = "qcom,q6asm";
> > +						reg = <APR_SVC_ASM>;
> > +						q6asmdai: dais {
> > +							compatible = "qcom,q6asm-dais";
> > +							#address-cells = <1>;
> > +							#size-cells = <0>;
> > +							#sound-dai-cells = <1>;
> > +
> > +							dai@0 {
> > +								reg = <MSM_FRONTEND_DAI_MULTIMEDIA1>;
> > +							};
> > +
> > +							dai@1 {
> > +								reg = <MSM_FRONTEND_DAI_MULTIMEDIA2>;
> > +							};
> > +
> > +							dai@2 {
> > +								reg = <MSM_FRONTEND_DAI_MULTIMEDIA3>;
> > +							};
> > +
> > +							dai@3 {
> > +								reg = <MSM_FRONTEND_DAI_MULTIMEDIA4>;
> > +								is-compress-dai;
> > +							};
> > +						};
> > +					};
> > +
> > +					q6adm: q6adm {
> > +						compatible = "qcom,q6adm";
> > +						reg = <APR_SVC_ADM>;
> > +						q6routing: routing {
> > +							compatible = "qcom,q6adm-routing";
> > +							#sound-dai-cells = <0>;
> > +						};
> > +					};
> > +				};
> > +			};
> > +
>
> Remove unneeded blank lines.

Will be fixed in v2
>
> > +		};
> > +
> >  		timer@b120000 {
> >  			compatible = "arm,armv7-timer-mem";
> >  			reg = <0xb120000 0x1000>;
>
>
> Best regards,
> Krzysztof

Thanks,
Sireesh Kodali

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

* Re: [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML
  2022-05-12  8:14       ` Krzysztof Kozlowski
@ 2022-05-12  9:32         ` Sireesh Kodali
  2022-05-12 11:02           ` Krzysztof Kozlowski
  0 siblings, 1 reply; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-12  9:32 UTC (permalink / raw)
  To: Krzysztof Kozlowski, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier, Rob Herring, Krzysztof Kozlowski

On Thu May 12, 2022 at 1:44 PM IST, Krzysztof Kozlowski wrote:
> On 12/05/2022 08:50, Sireesh Kodali wrote:
> > On Wed May 11, 2022 at 10:45 PM IST, Krzysztof Kozlowski wrote:
> >> On 11/05/2022 18:15, Sireesh Kodali wrote:
> >>> Convert the dt-bindings from txt to YAML. This is in preparation for
> >>> including the relevant bindings for the MSM8953 platform's wcnss pil.
> >>>
> >>> Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> >>
> >> Thank you for your patch. There is something to discuss/improve.
> >>
> >> Please use existing bindings or example-schema as a starting point. Half
> >> of my review could be skipped if you just followed what we already have
> >> in the tree.
> >>
> >> Some of these qcom specific properties already exist but you decided to
> >> write them differently... please don't, rather reuse the code.
> >>
> > 
> > Thank you for your review, I will make the chnages as appropriate in v2.
> >> (...)
> >>
> >>> +
> >>> +maintainers:
> >>> +  - Bjorn Andersson <bjorn.andersson@linaro.org>
> >>> +
> >>> +description:
> >>> +  This document defines the binding for a component that loads and boots
> >>> +  firmware on the Qualcomm WCNSS core.
> >>> +
> >>> +properties:
> >>> +  compatible:
> >>> +    oneOf:
> >>> +      - items:
> >>> +          - enum:
> >>> +              - qcom,pronto-v2-pil
> >>> +          - enum:
> >>> +              - qcom,pronto
> >>
> >> This does not look correct. The fallback compatible should not change.
> >> What is more, it was not documented in original binding, so this should
> >> be done in separate patch.
> >>
> > 
> > This was not a change to the fallback compatible. 
>
> You made it an enum, so you expect it to use different fallback for
> different cases.
>
> > msm8916.dtsi's wcnss
> > node has "qcom,pronto" as the compatible string, which is why this was
> > added. It is however not documented in the txt file. Is it sufficient to
> > add a note in the commit message, or should it be split into a separate
> > commit?
>
> Please split it, assuming that fallback is correct. Maybe the fallback
> is wrong?

The code doesn't recognize "qcom,pronto", so perhaps the best solution
is to just remove that compatible from msm8916.dtsi?
>
> > 
> >>> +      - items:
> >>
> >> No need for items, it's just one item.
> >>
> >>> +          - enum:
> >>> +              - qcom,riva-pil
> >>> +              - qcom,pronto-v1-pil
> >>> +              - qcom,pronto-v2-pil
> >>> +
> >>> +  reg:
> >>> +    description: must specify the base address and size of the CCU, DXE and PMU
> >>> +      register blocks
> >>
> >> New line after "decription:", drop "must specify" and start with capital
> >> letter.
> >>
> >> You need maxItems: 3
> >>
> > 
> > Will fix in v2
> >>
> >>> +
> >>> +  reg-names:
> >>> +    items:
> >>> +      - const: ccu
> >>> +      - const: dxe
> >>> +      - const: pmu
> >>> +
> >>> +  interrupts-extended:
> >>> +    description:
> >>> +      Interrupt lines
> >>
> >> Skip description, it's obvious.
> >>
> >> It should be only "interrupts", not extended.
> >>
> >>> +    minItems: 2
> >>> +    maxItems: 5
> >>> +
> >>> +  interrupt-names:
> >>> +    minItems: 2
> >>> +    maxItems: 5
> >>
> >> Names should be clearly defined. They were BTW defined in original
> >> bindings, so you should not remove them. This makes me wonder what else
> >> did you remove from original bindings...
> >>
> >> Please document all deviations from pure conversion in the commit msg.
> >> It's a second "hidden" difference.
> >>
> > 
> > Sorry, this was meant to be a pure txt->YAML conversion. The missing
> > interrupt names was accidental, and will be fixed in v2.
> >>> +
> >>> +  firmware-name:
> >>> +    $ref: /schemas/types.yaml#/definitions/string
> >>> +    description: Relative firmware image path for the WCNSS core. Defaults to
> >>> +      "wcnss.mdt".
> >>
> >>
> >> Blank line after "description:". This applies to other places as well.
> >>
> >> Remove "Defailts to ..." and just add "default" schema.
> >>
> > 
> > Will be fixed in v2
> >>> +
> >>> +  vddpx-supply:
> >>> +    description: Reference to the PX regulator to be held on behalf of the
> >>> +      booting of the WCNSS core
> >>> +
> >>> +  vddmx-supply:
> >>> +    description: Reference to the MX regulator to be held on behalf of the
> >>> +      booting of the WCNSS core.
> >>> +
> >>> +  vddcx-supply:
> >>> +    description: Reference to the CX regulator to be held on behalf of the
> >>> +      booting of the WCNSS core.
> >>
> >> s/Reference to the//
> >>
> >>> +
> >>> +  power-domains:
> >>> +    $ref: /schemas/types.yaml#/definitions/phandle-array
> >>> +    description: References to the power domains that need to be held on
> >>> +      behalf of the booting WCNSS core
> >>
> >> 1. Ditto.
> >> 2. No need for ref
> >> 3. maxItems
> >>
> >>> +
> >>> +  power-domain-names:
> >>> +    $ref: /schemas/types.yaml#/definitions/string-array
> >>
> >> No need for ref, skip description.
> >>
> >>> +    description: Names of the power domains
> >>> +    items:
> >>> +      - const: cx
> >>> +      - const: mx
> >>> +
> >>> +  qcom,smem-states:
> >>> +    $ref: /schemas/types.yaml#/definitions/phandle-array
> >>> +    description: States used by the AP to signal the WCNSS core that it should
> >>> +      shutdown
> >>> +    items:
> >>> +      - description: Stop the modem
> >>> +
> >>> +  qcom,smem-state-names:
> >>> +    $ref: /schemas/types.yaml#/definitions/string-array
> >>
> >> No need for ref. Really, it does not appear in any of existing bindings
> >> for smem-state-names, so how did you get it?
> >>
> > 
> > The smem nodes were copied from /remoteproc/qcom,sdm845-adsp-pil.yaml
>
> Hm, indeed, you're right. There are few files having here ref. I'll fix
> these.
>
> > 
> >>> +    description: The names of the state bits used for SMP2P output
> >>> +    items:
> >>> +      - const: stop
> >>> +
> >>> +  memory-region:
> >>> +    maxItems: 1
> >>> +    description: Reference to the reserved-memory for the WCNSS core
> >>> +
> >>> +  smd-edge:
> >>> +    type: object
> >>> +    description:
> >>> +      Qualcomm Shared Memory subnode which represents communication edge,
> >>> +      channels and devices related to the ADSP.
> >>
> >> You should reference /schemas/soc/qcom/qcom,smd.yaml
> > 
> > Will be done in v2
> >>
> >>> +
> >>> +  iris:
> >>
> >> Generic node name... what is "iris"?
> >>
> > Iris is the RF module, I'll make the description better
>
> RF like wifi? Then the property name should be "wifi".

RF like wifi and bluetooth. However there are wifi and bt subnodes in
the smd-edge subnode. Iris is just the antenna hardware if I understand
correctly. Also this is just a documentation of the existing nodes that
are present in msm8916.dtsi, but for whatever reason their documentation
was missing in the txt file. Without adding this node in the YAML
dtb_check fails.

>
>
> Best regards,
> Krzysztof


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

* Re: [PATCH 6/9] dt-bindings: remoteproc: qcom: mss: Convert bindings to YAML
  2022-05-11 17:50   ` Krzysztof Kozlowski
@ 2022-05-12  9:50     ` Sireesh Kodali
  0 siblings, 0 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-12  9:50 UTC (permalink / raw)
  To: Krzysztof Kozlowski, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier, Rob Herring, Krzysztof Kozlowski

On Wed May 11, 2022 at 11:20 PM IST, Krzysztof Kozlowski wrote:
> On 11/05/2022 18:15, Sireesh Kodali wrote:
> > Convert the bindings to YAML from txt. The bindings follow a similar
> > schema to `qcom,adsp.yaml`.
> > 
> > Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> > ---
> >  .../bindings/remoteproc/qcom,q6v5.txt         | 302 --------
> >  .../bindings/remoteproc/qcom,q6v5.yaml        | 702 ++++++++++++++++++
> >  2 files changed, 702 insertions(+), 302 deletions(-)
> >  delete mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,q6v5.txt
> >  create mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,q6v5.yaml
>
> Same comments as for patch 4 apply here. Some of them seems fixed so it
> makes me wonder - why you wrote two bindings in entirely different way?
>

This was largely based on the existing qcom,adsp.yaml. That's probably
why there are less mistakes.
> > +  This document defines the binding for a component that loads and boots firmware
> > +  on the Qualcomm Hexagon core.
> > +
> > +properties:
> > +  compatible:
> > +    # Special case, because older platforms like MSM8916 use both compatibles together
> > +    minItems: 1
> > +    maxItems: 2
> > +    oneOf:
> > +      - items:
> > +          - enum:
> > +              - qcom,msm8916-mss-pil
> > +          - enum:
> > +              - qcom,q6v5-pil
>
> Everywhere - same comments as in patch 4.
>
Will be fixed in v2.
> > +      - items:
> > +          - enum:
> > +              - qcom,q6v5-pil
> > +              - qcom,ipq8074-wcss-pil
> > +              - qcom,qcs404-wcss-pil
> > +              - qcom,msm8916-mss-pil
> > +              - qcom,msm8974-mss-pil
> > +              - qcom,msm8996-mss-pil
> > +              - qcom,msm8998-mss-pil
> > +              - qcom,sc7180-mss-pil
> > +              - qcom,sc7280-mss-pil
> > +              - qcom,sdm845-mss-pil
> > +
> > +  reg:
> > +    description: must specify the base address and size of the qdsp6 and rmb
> > +      register blocks
> > +    maxItems: 2
> > +
> > +  reg-names:
> > +    items:
> > +      - const: qdsp6
> > +      - const: rmb
> > +
> > +  interrupts-extended:
> > +    minItems: 5
> > +    maxItems: 6
> > +
> > +  interrupt-names:
> > +    minItems: 5
> > +    maxItems: 6
> > +
> > +  firmware-name:
> > +    $ref: /schemas/types.yaml#/definitions/string-array
> > +    description: List the relative firmware image paths for the mba and
> > +      modem. They are used for booting and authenticating the Hexagon core.
> > +    maxItems: 2
> > +
> > +  clocks:
> > +    minItems: 4
> > +    maxItems: 10
> > +
> > +  clock-names:
> > +    minItems: 4
> > +    maxItems: 10
> > +
> > +  resets:
> > +    description: Reference to the reset-controllwer for the modem subsystem
> > +    minItems: 1
> > +    maxItems: 3
> > +
> > +  reset-names:
> > +    minItems: 1
> > +    maxItems: 3
> > +
> > +  memory-region:
> > +    maxItems: 1
> > +    description: Reference to the reserved-memory for the mba region followed
> > +      by the mpss region. Required if the mba and mpss sub-nodes are not
> > +      specified.
> > +
> > +  cx-supply:
> > +    description: Phandle to the CX regulator
> > +
> > +  mx-supply:
> > +    description: Phandle to the MX regulator
> > +
> > +  pll-supply:
> > +    description: Phandle to the PLL regulator, to be held on behalf of the
> > +      booting Hexagon core
> > +
> > +  mss-supply:
> > +    description: Phandle to the mss regulator, to be held on behalf of the
> > +      booting Hexagon core
>
> s/Phandle to//, everywhere.
>
> > +
> > +  power-domains:
> > +    minItems: 1
> > +    maxItems: 4
> > +
> > +  power-domain-names:
> > +    minItems: 1
> > +    maxItems: 4
> > +
> > +  qcom,qmp:
> > +    $ref: /schemas/types.yaml#/definitions/phandle
> > +    description: Reference to the AOSS side-channel message RAM.
> > +
> > +  qcom,smem-states:
> > +    $ref: /schemas/types.yaml#/definitions/phandle-array
> > +    description: States used by the AP to signal the Hexagon core
> > +    items:
> > +      - description: Stop the modem
> > +
> > +  qcom,smem-state-names:
> > +    $ref: /schemas/types.yaml#/definitions/string-array
> > +    description: The names of the state bits used for SMP2P output
> > +    items:
> > +      - const: stop
> > +
> > +  qcom,halt-regs:
> > +    $ref: /schemas/types.yaml#/definitions/phandle-array
> > +    description:
> > +      Phandle reference to a syscon representing TCSR followed by the
> > +      three offsets within syscon for q6, modem and nc halt registers.
> > +
> > +  qcom,spare-regs:
> > +    $ref: /schemas/types.yaml#/definitions/phandle-array
> > +    description:
> > +      A phandle reference to a syscon representing TCSR followed by the
> > +      offset within syscon for conn_box_spare0 register used by the modem
> > +      sub-system running on SC7180 SoC.
> > +
> > +  qcom,ext-regs:
> > +    $ref: /schemas/types.yaml#/definitions/phandle-array
> > +    description:
> > +      Two phandle references to syscons representing TCSR_REG and TCSR
> > +      register space followed by the two offsets within the syscon to
> > +      force_clk_en/rscc_disable and axim1_clk_off/crypto_clk_off registers
> > +      respectively.
> > +
> > +  qcom,qaccept-regs:
> > +    $ref: /schemas/types.yaml#/definitions/phandle-array
> > +    description:
> > +      A phandle reference to a syscon representing TCSR followed by the three
> > +      offsets within syscon for mdm, cx and axi qaccept registers used by the
> > +      modem sub-system running on SC7280 SoC.
> > +
> > +  iommus:
> > +    description:
> > +      Only required on platforms that do not have TrustZone.
> > +
> > +  smd-edge:
> > +    type: object
> > +    description:
> > +      Qualcomm Shared Memory subnode which represents communication edge,
> > +      channels and devices related to the ADSP.
> > +
> > +  glink-edge:
> > +    type: object
> > +    description:
> > +      Qualcomm G-Link subnode which represents communication edge, channels
> > +      and devices related to the ADSP.
> > +
> > +  mba:
> > +    type: object
>
> description needed.
>
> > +    properties:
> > +      memory-region:
> > +        maxItems: 1
> > +
> > +    required:
> > +      - memory-region
> > +
> > +  mpss:
>
> description needed.
>
> > +    type: object
> > +    properties:
> > +      memory-region:
> > +        maxItems: 1
> > +
> > +    required:
> > +      - memory-region
> > +
> > +required:
> > +  - compatible
> > +  - clocks
> > +  - clock-names
> > +  - interrupts-extended
> > +  - interrupt-names
> > +  - qcom,smem-states
> > +  - qcom,smem-state-names
> > +
> > +additionalProperties: false
> > +
> > +allOf:
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,ipq8074-wcss-pil
> > +    then:
> > +      properties:
> > +        clocks: false
> > +        clock-names: false
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,qcs404-wcss-pil
> > +    then:
> > +      properties:
> > +        clocks:
> > +          items:
> > +            - description: GCC_AHBS_CBCR clock
> > +            - description: GCC_AXIM_CBCR clock
> > +            - description: LCC_AHBFABRIC_CBC clock
> > +            - description: TCSR_LCC_CBC clock
> > +            - description: LCC_AHBS_CBC clock
> > +            - description: LCC_TCM_SLAVE_CBC clock
> > +            - description: LCC_ABHM_CBC clock
> > +            - description: LCC_AXIM_CBC clock
> > +            - description: LCC_BCR_SLEEP clock
> > +            - description: XO clock
> > +        clock-names:
> > +          items:
> > +            - const: gcc_ahbs_cbcr
> > +            - const: gcc_axim_cbcr
> > +            - const: lcc_ahbfabric_cbc
> > +            - const: tcsr_lcc_cbc
> > +            - const: lcc_abhs_cbc
> > +            - const: lcc_tcm_slave_cbc
> > +            - const: lcc_abhm_cbc
> > +            - const: lcc_axim_cbc
> > +            - const: lcc_bcr_sleep
> > +            - const: xo
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,q6v5-pil
> > +              - qcom,msm8916-mss-pil
> > +              - qcom,msm8974-mss-pil
> > +    then:
> > +      properties:
> > +        clocks:
> > +          items:
> > +            - description: Interface clock
> > +            - description: Bus clock
> > +            - description: Memory clock
> > +            - description: XO clock
> > +        clock-names:
> > +          items:
> > +            - const: iface
> > +            - const: bus
> > +            - const: mem
> > +            - const: xo
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,msm8996-mss-pil
> > +    then:
> > +      properties:
> > +        clocks:
> > +          items:
> > +            - description: Interface clock
> > +            - description: Bus clock
> > +            - description: Memory clock
> > +            - description: GPLL0_MSS clock
> > +            - description: SNOC_AXI clock
> > +            - description: MNOC_AXI clock
> > +            - description: PNOC clock
> > +            - description: QDSS clock
> > +            - description: XO clock
> > +        clock-names:
> > +          items:
> > +            - const: iface
> > +            - const: bus
> > +            - const: mem
> > +            - const: gpll0_mss
> > +            - const: snoc_axi
> > +            - const: mnoc_axi
> > +            - const: pnoc
> > +            - const: qdss
> > +            - const: xo
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,msm8998-mss-pil
> > +    then:
> > +      properties:
> > +        clocks:
> > +          items:
> > +            - description: Interface clock
> > +            - description: Bus clock
> > +            - description: Memory clock
> > +            - description: GPLL0_MSS clock
> > +            - description: SNOC_AXI clock
> > +            - description: MNOC_AXI clock
> > +            - description: QDSS clock
> > +            - description: XO clock
> > +        clock-names:
> > +          items:
> > +            - const: iface
> > +            - const: bus
> > +            - const: mem
> > +            - const: gpll0_mss
> > +            - const: snoc_axi
> > +            - const: mnoc_axi
> > +            - const: qdss
> > +            - const: xo
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,sc7180-mss-pil
> > +    then:
> > +      properties:
> > +        clocks:
> > +          items:
> > +            - description: Interface clock
> > +            - description: Bus clock
> > +            - description: NAV clock
> > +            - description: SNOC_AXI clock
> > +            - description: MNOC_AXI clock
> > +            - description: XO clock
> > +        clock-names:
> > +          items:
> > +            - const: iface
> > +            - const: bus
> > +            - const: nav
> > +            - const: snoc_axi
> > +            - const: mnoc_axi
> > +            - const: xo
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,sc7280-mss-pil
> > +    then:
> > +      properties:
> > +        clocks:
> > +          items:
> > +            - description: Interface clock
> > +            - description: Offline clock
> > +            - description: SNOC_AXI clock
> > +            - description: PKA clock
> > +            - description: XO clock
> > +        clock-names:
> > +          items:
> > +            - const: iface
> > +            - const: offline
> > +            - const: snoc_axi
> > +            - const: pka
> > +            - const: xo
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,sdm845-mss-pil
> > +    then:
> > +      properties:
> > +        clocks:
> > +          items:
> > +            - description: Interface clock
> > +            - description: Bus clock
> > +            - description: Memory clock
> > +            - description: GPLL0_MSS clock
> > +            - description: SNOC_AXI clock
> > +            - description: MNOC_AXI clock
> > +            - description: PRNG clock
> > +            - description: XO clock
> > +        clock-names:
> > +          items:
> > +            - const: iface
> > +            - const: bus
> > +            - const: mem
> > +            - const: gpll0_mss
> > +            - const: snoc_axi
> > +            - const: mnoc_axi
> > +            - const: prng
> > +            - const: xo
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,q6v5-pil
> > +              - qcom,ipq8074-wcss-pil
> > +              - qcom,qcs404-wcss-pil
> > +              - qcom,msm8916-mss-pil
> > +              - qcom,msm8974-mss-pil
> > +    then:
> > +      properties:
> > +        interrupts-extended:
>
> No extended.
>
> > +          items:
> > +            - description: Watchdog interrupt
> > +            - description: Fatal interrupt
> > +            - description: Ready interrupt
> > +            - description: Handover interrupt
> > +            - description: Stop acknowledge interrupt
> > +        interrupt-names:
> > +          items:
> > +            - const: wdog
> > +            - const: fatal
> > +            - const: ready
> > +            - const: handover
> > +            - const: stop-ack
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,msm8996-mss-pil
> > +              - qcom,msm8998-mss-pil
> > +              - qcom,sc7180-mss-pil
> > +              - qcom,sc7280-mss-pil
> > +              - qcom,sdm845-mss-pil
> > +    then:
> > +      properties:
> > +        interrupts-extended:
> > +          items:
> > +            - description: Watchdog interrupt
> > +            - description: Fatal interrupt
> > +            - description: Ready interrupt
> > +            - description: Handover interrupt
> > +            - description: Stop acknowledge interrupt
> > +            - description: Shutdown acknowledge interrupt
> > +        interrupt-names:
> > +          items:
> > +            - const: wdog
> > +            - const: fatal
> > +            - const: ready
> > +            - const: handover
> > +            - const: stop-ack
> > +            - const: shutdown-ack
>
> Both ifs should be written differently. Move the bigger list to
> properties with minItems: 5. For qcom,q6v5-pil you set maxItems:5. For
> qcom,msm8996-mss-pil you set minItems:6.
>
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          enum:
> > +            - const: qcom,q6v5-pil
> > +            - const: qcom,msm8916-mss-pil
> > +            - const: qcom,msm8974-mss-pil
> > +    then:
> > +      properties:
> > +        cx-supply:
> > +          deprecated: true
> > +        mx-supply:
> > +          deprecated: true
> > +
> > +      required:
> > +        - pll-supply
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          enum:
> > +            - qcom,msm8916-mss-pil
> > +            - qcom,msm8974-mss-pil
> > +            - qcom,msm8996-mss-pil
> > +            - qcom,msm8998-mss-pil
> > +    then:
> > +      properties:
> > +        power-domains:
> > +          items:
> > +            - description: CX power domain
> > +            - description: MX power domain
> > +        power-domain-names:
> > +          items:
> > +            - const: cx
> > +            - const: mx
> > +
> > +      required:
> > +        - power-domains
> > +        - power-domain-names
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          enum:
> > +            - const: qcom,msm8996-mss-pil
> > +    then:
> > +      properties:
> > +        cx-supply: false
> > +        mx-supply: false
> > +
> > +      required:
> > +        - pll-supply
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          enum:
> > +            - const: qcom,qcs404-wcss-pil
> > +    then:
> > +      required:
> > +        - cx-supply
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,sdm845-mss-pil
> > +              - qcom,sc7180-mss-pil
> > +    then:
> > +      properties:
> > +        power-domains:
> > +          items:
> > +            - description: CX power domain
> > +            - description: MX power domain
> > +            - description: MSS power domain
> > +        power-domain-names:
> > +          items:
> > +            - const: cx
> > +            - const: mx
> > +            - const: mss
> > +
> > +      required:
> > +        - power-domains
> > +        - power-domain-names
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,sc7280-mss-pil
> > +    then:
> > +      properties:
> > +        power-domains:
> > +          items:
> > +            - description: CX power domain
> > +            - description: MSS power domain
> > +        power-domain-names:
> > +          items:
> > +            - const: cx
> > +            - const: mss
> > +
> > +      required:
> > +        - power-domains
> > +        - power-domain-names
> > +        - qcom,ext-regs
> > +        - qcom,qaccept-regs
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,q6v5-pil
> > +              - qcom,msm8916-mss-pil
> > +              - qcom,msm8974-mss-pil
> > +              - qcom,msm8996-mss-pil
> > +              - qcom,msm8998-mss-pil
> > +    then:
> > +      properties:
> > +        resets:
> > +          items:
> > +            - description: MSS reset
> > +        reset-names:
> > +          items:
> > +            - const: mss_restart
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,ipq8074-wcss-pil
> > +              - qcom,qcs404-wcss-pil
> > +    then:
> > +      properties:
> > +        resets:
> > +          items:
> > +            - description: WCSS Always On restart
> > +            - description: WCSS reset
> > +            - description: WCSS Q6 reset
> > +        reset-names:
> > +          items:
> > +            - const: wcss_aon_restart
> > +            - const: wcss_reset
> > +            - const: wcss_q6_reset
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,sc7180-mss-pil
> > +              - qcom,sc7280-mss-pil
> > +              - qcom,sdm845-mss-pil
> > +    then:
> > +      properties:
> > +        resets:
> > +          items:
> > +            - description: MSS restart
> > +            - description: PDC reset
> > +        reset-names:
> > +          items:
> > +            - const: mss_restart
> > +            - const: pdc_reset
> > +
> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - qcom,q6v5-pil
> > +              - qcom,ipq8074-wcss-pil
> > +              - qcom,qcs404-wcss-pil
> > +              - qcom,msm8916-mss-pil
> > +              - qcom,msm8974-mss-pil
> > +              - qcom,msm8996-mss-pil
> > +              - qcom,msm8998-mss-pil
> > +    then:
> > +      properties:
> > +        qcom,qmp: false
> > +        iommus: false
> > +
> > +examples:
> > +  - |
> > +    #include <dt-bindings/clock/qcom,rpmcc.h>
> > +    #include <dt-bindings/interrupt-controller/irq.h>
> > +    #include <dt-bindings/clock/qcom,gcc-msm8974.h>
> > +    #include <dt-bindings/reset/qcom,gcc-msm8974.h>
> > +    #include <dt-bindings/interrupt-controller/arm-gic.h>
> > +    modem-rproc@fc880000 {
>
> Generic node name, so "remoteproc"

Will fix in v2

>
> > +        compatible = "qcom,q6v5-pil";
> > +        reg = <0xfc880000 0x100>,
> > +              <0xfc820000 0x020>;
> > +        reg-names = "qdsp6", "rmb";
> > +
> > +        interrupts-extended = <&intc GIC_SPI 24 IRQ_TYPE_EDGE_RISING>,
> > +                              <&modem_smp2p_in 0 IRQ_TYPE_EDGE_RISING>,
> > +                              <&modem_smp2p_in 1 IRQ_TYPE_EDGE_RISING>,
> > +                              <&modem_smp2p_in 2 IRQ_TYPE_EDGE_RISING>,
> > +                              <&modem_smp2p_in 3 IRQ_TYPE_EDGE_RISING>;
> > +        interrupt-names = "wdog",
> > +                          "fatal",
> > +                          "ready",
> > +                          "handover",
> > +                          "stop-ack";
> > +
> > +        clocks = <&gcc GCC_MSS_Q6_BIMC_AXI_CLK>,
> > +                 <&gcc GCC_MSS_CFG_AHB_CLK>,
> > +                 <&gcc GCC_BOOT_ROM_AHB_CLK>,
> > +                 <&xo_board>;
> > +        clock-names = "iface", "bus", "mem", "xo";
> > +
> > +        qcom,halt-regs = <&tcsr_mutex_block 0x1180 0x1200 0x1280>;
>
> Does this pass the tests? Did you test the bindings?
Yes, both dtbs_check and dt_binding_check
>
> > +
> > +        resets = <&gcc GCC_MSS_RESTART>;
> > +        reset-names = "mss_restart";
> > +
> > +        cx-supply = <&pm8841_s2>;
> > +        mss-supply = <&pm8841_s3>;
> > +        mx-supply = <&pm8841_s1>;
> > +        pll-supply = <&pm8941_l12>;
> > +
> > +        qcom,smem-states = <&modem_smp2p_out 0>;
> > +        qcom,smem-state-names = "stop";
> > +
> > +        mba {
> > +                memory-region = <&mba_region>;
>
> Wrong indentation.
>
Will fix in v2
> > +        };
> > +
> > +        mpss {
> > +                memory-region = <&mpss_region>;
> > +        };
> > +
> > +        smd-edge {
> > +                interrupts = <GIC_SPI 25 IRQ_TYPE_EDGE_RISING>;
> > +
> > +                qcom,ipc = <&apcs 8 12>;
> > +                qcom,smd-edge = <0>;
> > +
> > +                label = "modem";
> > +        };
> > +    };
>
>
> Best regards,
> Krzysztof

Thanks,
Sireesh Kodali

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

* Re: [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML
  2022-05-12  8:36       ` Krzysztof Kozlowski
@ 2022-05-12 10:01         ` Sireesh Kodali
  0 siblings, 0 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-12 10:01 UTC (permalink / raw)
  To: Krzysztof Kozlowski, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier, Rob Herring, Krzysztof Kozlowski

On Thu May 12, 2022 at 2:06 PM IST, Krzysztof Kozlowski wrote:
> On 12/05/2022 08:50, Sireesh Kodali wrote:
> >>> +    description: The names of the state bits used for SMP2P output
> >>> +    items:
> >>> +      - const: stop
> >>> +
> >>> +  memory-region:
> >>> +    maxItems: 1
> >>> +    description: Reference to the reserved-memory for the WCNSS core
> >>> +
> >>> +  smd-edge:
> >>> +    type: object
> >>> +    description:
> >>> +      Qualcomm Shared Memory subnode which represents communication edge,
> >>> +      channels and devices related to the ADSP.
> >>
> >> You should reference /schemas/soc/qcom/qcom,smd.yaml
>
> It seems it is not a SMD driver so above reference is not correct. This
> should be probably described in its own schema, I just need to
> understand what's this...
>
The smd-edge node describes the smd channels used to communicate with
the remote processor. For wcnss that would be the remote proc id, and
the channels for bt and wifi (both separate). There's a similar node for
adsp and q6v5.
>
> Best regards,
> Krzysztof


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

* Re: [PATCH 2/9] remoteproc: qcom: q6v5-mss: Add modem support on MSM8953
  2022-05-11 16:54   ` Dmitry Baryshkov
  2022-05-12  5:16     ` Sireesh Kodali
@ 2022-05-12 10:38     ` Sireesh Kodali
  1 sibling, 0 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-12 10:38 UTC (permalink / raw)
  To: Dmitry Baryshkov, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier

On Wed May 11, 2022 at 10:24 PM IST, Dmitry Baryshkov wrote:
> On 11/05/2022 19:15, Sireesh Kodali wrote:
> > The modem on the MSM8953 platform is similar to the modem on the MSM8996
> > platform in terms of set up. It differs primarily in the way it needs SCM
> > to bless the MPSS firmware region.
> > 
> > Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> > ---
> >   drivers/remoteproc/qcom_q6v5_mss.c | 64 +++++++++++++++++++++++++++---
> >   1 file changed, 58 insertions(+), 6 deletions(-)
> > 
> > diff --git a/drivers/remoteproc/qcom_q6v5_mss.c b/drivers/remoteproc/qcom_q6v5_mss.c
> > index af217de75e4d..a73fdcddeda4 100644
> > --- a/drivers/remoteproc/qcom_q6v5_mss.c
> > +++ b/drivers/remoteproc/qcom_q6v5_mss.c
> > @@ -234,6 +234,7 @@ struct q6v5 {
> >   
> >   enum {
> >   	MSS_MSM8916,
> > +	MSS_MSM8953,
> >   	MSS_MSM8974,
> >   	MSS_MSM8996,
> >   	MSS_MSM8998,
> > @@ -687,12 +688,14 @@ static int q6v5proc_reset(struct q6v5 *qproc)
> >   		}
> >   		goto pbl_wait;
> >   	} else if (qproc->version == MSS_MSM8996 ||
> > -		   qproc->version == MSS_MSM8998) {
> > +		   qproc->version == MSS_MSM8998 ||
> > +		   qproc->version == MSS_MSM8953) {
> >   		int mem_pwr_ctl;
> >   
> >   		/* Override the ACC value if required */
> > -		writel(QDSP6SS_ACC_OVERRIDE_VAL,
> > -		       qproc->reg_base + QDSP6SS_STRAP_ACC);
> > +		if (qproc->version != MSS_MSM8953)
> > +			writel(QDSP6SS_ACC_OVERRIDE_VAL,
> > +					qproc->reg_base + QDSP6SS_STRAP_ACC);
> >   
> >   		/* Assert resets, stop core */
> >   		val = readl(qproc->reg_base + QDSP6SS_RESET_REG);
> > @@ -734,7 +737,8 @@ static int q6v5proc_reset(struct q6v5 *qproc)
> >   		writel(val, qproc->reg_base + QDSP6SS_PWR_CTL_REG);
> >   
> >   		/* Turn on L1, L2, ETB and JU memories 1 at a time */
> > -		if (qproc->version == MSS_MSM8996) {
> > +		if (qproc->version == MSS_MSM8996 ||
> > +			qproc->version == MSS_MSM8953) {
> >   			mem_pwr_ctl = QDSP6SS_MEM_PWR_CTL;
> >   			i = 19;
> >   		} else {
> > @@ -1314,7 +1318,16 @@ static int q6v5_mpss_load(struct q6v5 *qproc)
> >   			max_addr = ALIGN(phdr->p_paddr + phdr->p_memsz, SZ_4K);
> >   	}
> >   
> > -	/*
> > +	if (qproc->version == MSS_MSM8953) {
> > +		ret = qcom_scm_pas_mem_setup(5, qproc->mpss_phys, qproc->mpss_size);
> > +		if (ret) {
> > +			dev_err(qproc->dev,
> > +					"setting up mpss memory failed: %d\n", ret);
> > +			goto release_firmware;
> > +		}
> > +	}
> > +
> > +	/**
>
> Single star please

Will fix in v2

>
> >   	 * In case of a modem subsystem restart on secure devices, the modem
> >   	 * memory can be reclaimed only after MBA is loaded.
> >   	 */
> > @@ -1413,7 +1426,6 @@ static int q6v5_mpss_load(struct q6v5 *qproc)
> >   			writel(RMB_CMD_LOAD_READY, qproc->rmb_base + RMB_MBA_COMMAND_REG);
> >   		}
> >   		writel(size, qproc->rmb_base + RMB_PMI_CODE_LENGTH_REG);
> > -
> >   		ret = readl(qproc->rmb_base + RMB_MBA_STATUS_REG);
> >   		if (ret < 0) {
> >   			dev_err(qproc->dev, "MPSS authentication failed: %d\n",
> > @@ -1422,6 +1434,7 @@ static int q6v5_mpss_load(struct q6v5 *qproc)
> >   		}
> >   	}
> >   
> > +
>
> Unnecessary

Will fix in v2
>
>
> >   	/* Transfer ownership of modem ddr region to q6 */
> >   	ret = q6v5_xfer_mem_ownership(qproc, &qproc->mpss_perm, false, true,
> >   				      qproc->mpss_phys, qproc->mpss_size);
> > @@ -2198,6 +2211,44 @@ static const struct rproc_hexagon_res msm8996_mss = {
> >   	.version = MSS_MSM8996,
> >   };
> >   
> > +static const struct rproc_hexagon_res msm8953_mss = {
> > +	.hexagon_mba_image = "mba.mbn",
> > +	.proxy_supply = (struct qcom_mss_reg_res[]) {
> > +		{
> > +			.supply = "pll",
> > +			.uA = 100000,
> > +		},
> > +		{}
> > +	},
> > +	.proxy_pd_names = (char*[]) {
> > +			"cx",
> > +			"mx",
> > +			NULL
> > +	},
> > +	.active_supply = (struct qcom_mss_reg_res[]) {
> > +		{
> > +			.supply = "mss",
> > +			.uV = 1050000,
> > +			.uA = 100000,
> > +		},
> > +		{}
> > +	},
> > +	.proxy_clk_names = (char*[]){
> > +			"xo",
> > +			NULL
> > +	},
> > +	.active_clk_names = (char*[]){
> > +			"iface",
> > +			"bus",
> > +			"mem",
> > +			NULL
> > +	},
> > +	.need_mem_protection = false,
> > +	.has_alt_reset = false,
> > +	.has_spare_reg = false,
>
>
> Please follow the custom  and define the rest of fields here.

Will fix in v2
>
> > +	.version = MSS_MSM8953,
> > +};
> > +
> >   static const struct rproc_hexagon_res msm8916_mss = {
> >   	.hexagon_mba_image = "mba.mbn",
> >   	.proxy_supply = (struct qcom_mss_reg_res[]) {
> > @@ -2301,6 +2352,7 @@ static const struct of_device_id q6v5_of_match[] = {
> >   	{ .compatible = "qcom,msm8916-mss-pil", .data = &msm8916_mss},
> >   	{ .compatible = "qcom,msm8974-mss-pil", .data = &msm8974_mss},
> >   	{ .compatible = "qcom,msm8996-mss-pil", .data = &msm8996_mss},
> > +	{ .compatible = "qcom,msm8953-mss-pil", .data = &msm8953_mss},
> >   	{ .compatible = "qcom,msm8998-mss-pil", .data = &msm8998_mss},
> >   	{ .compatible = "qcom,sc7180-mss-pil", .data = &sc7180_mss},
> >   	{ .compatible = "qcom,sc7280-mss-pil", .data = &sc7280_mss},
>
>
> -- 
> With best wishes
> Dmitry

Thanks,
Sireesh

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

* Re: [PATCH 1/9] remoteproc: qcom: pas: Add MSM8953 ADSP PIL support
  2022-05-11 16:51   ` Dmitry Baryshkov
@ 2022-05-12 10:39     ` Sireesh Kodali
  0 siblings, 0 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-12 10:39 UTC (permalink / raw)
  To: Dmitry Baryshkov, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier

On Wed May 11, 2022 at 10:21 PM IST, Dmitry Baryshkov wrote:
> On 11/05/2022 19:15, Sireesh Kodali wrote:
> > Add support for the Audio DSP PIL found on the Qualcomm MSM8953
> > platform. The same configuration is used on all SoCs based on the
> > MSM8953 platform (SDM450, SDA450, SDM625, SDM632, APQ8053).
> > 
> > Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> > ---
> >   drivers/remoteproc/qcom_q6v5_pas.c | 31 ++++++++++++++++++++++++++++++
> >   1 file changed, 31 insertions(+)
> > 
> > diff --git a/drivers/remoteproc/qcom_q6v5_pas.c b/drivers/remoteproc/qcom_q6v5_pas.c
> > index 1ae47cc153e5..4dcb714a1468 100644
> > --- a/drivers/remoteproc/qcom_q6v5_pas.c
> > +++ b/drivers/remoteproc/qcom_q6v5_pas.c
> > @@ -617,7 +617,37 @@ static const struct adsp_data sm8350_adsp_resource = {
> >   	.ssctl_id = 0x14,
> >   };
> >   
> > +static const struct adsp_data msm8953_adsp_resource = {
> > +	.crash_reason_smem = 423,
> > +	.firmware_name = "adsp.mdt",
> > +	.pas_id = 1,
> > +	.has_aggre2_clk = false,
> > +	.auto_boot = true,
> > +	.proxy_pd_names = (char*[]){
> > +		"cx",
> > +		NULL,
> > +	},
> > +	.ssr_name = "lpass",
> > +	.sysmon_name = "adsp",
> > +	.ssctl_id = 0x14,
> > +};
> > +
>
> Also it looks like this item is identical to msm8996_adsp_resources. So 
> you can existing structure instead.
>


Yes, the msm8953 item is identical to the msm8996_adsp_resource. I
wasn't aware that we could re-use structs like this, I will do that in
v2 of this patch

> >   static const struct adsp_data msm8996_adsp_resource = {
> > +	.crash_reason_smem = 423,
> > +	.firmware_name = "adsp.mdt",
> > +	.pas_id = 1,
> > +	.has_aggre2_clk = false,
> > +	.auto_boot = true,
> > +	.proxy_pd_names = (char*[]){
> > +		"cx",
> > +		NULL,
> > +	},
> > +	.ssr_name = "lpass",
> > +	.sysmon_name = "adsp",
> > +	.ssctl_id = 0x14,
> > +};
> > +
> > +static const struct adsp_data msm8998_adsp_resource = {
> >   		.crash_reason_smem = 423,
> >   		.firmware_name = "adsp.mdt",
> >   		.pas_id = 1,
> > @@ -850,6 +880,7 @@ static const struct adsp_data sdx55_mpss_resource = {
> >   static const struct of_device_id adsp_of_match[] = {
> >   	{ .compatible = "qcom,msm8974-adsp-pil", .data = &adsp_resource_init},
> >   	{ .compatible = "qcom,msm8996-adsp-pil", .data = &msm8996_adsp_resource},
> > +	{ .compatible = "qcom,msm8953-adsp-pil", .data = &msm8953_adsp_resource},
> >   	{ .compatible = "qcom,msm8996-slpi-pil", .data = &slpi_resource_init},
> >   	{ .compatible = "qcom,msm8998-adsp-pas", .data = &msm8996_adsp_resource},
> >   	{ .compatible = "qcom,msm8998-slpi-pas", .data = &slpi_resource_init},
>
>
> -- 
> With best wishes
> Dmitry

Thanks,
Sireesh

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

* Re: [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML
  2022-05-12  9:32         ` Sireesh Kodali
@ 2022-05-12 11:02           ` Krzysztof Kozlowski
  2022-05-12 13:42             ` Sireesh Kodali
  0 siblings, 1 reply; 35+ messages in thread
From: Krzysztof Kozlowski @ 2022-05-12 11:02 UTC (permalink / raw)
  To: Sireesh Kodali, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier, Rob Herring, Krzysztof Kozlowski, Loic Poulain

On 12/05/2022 11:32, Sireesh Kodali wrote:
>>>>> +          - enum:
>>>>> +              - qcom,pronto-v2-pil
>>>>> +          - enum:
>>>>> +              - qcom,pronto
>>>>
>>>> This does not look correct. The fallback compatible should not change.
>>>> What is more, it was not documented in original binding, so this should
>>>> be done in separate patch.
>>>>
>>>
>>> This was not a change to the fallback compatible. 
>>
>> You made it an enum, so you expect it to use different fallback for
>> different cases.
>>
>>> msm8916.dtsi's wcnss
>>> node has "qcom,pronto" as the compatible string, which is why this was
>>> added. It is however not documented in the txt file. Is it sufficient to
>>> add a note in the commit message, or should it be split into a separate
>>> commit?
>>
>> Please split it, assuming that fallback is correct. Maybe the fallback
>> is wrong?
> 
> The code doesn't recognize "qcom,pronto", so perhaps the best solution
> is to just remove that compatible from msm8916.dtsi?

Eh, I don't know. You need to check, maybe also in downstream sources.

(...)

>>>>
>>>>> +
>>>>> +  iris:
>>>>
>>>> Generic node name... what is "iris"?
>>>>
>>> Iris is the RF module, I'll make the description better
>>
>> RF like wifi? Then the property name should be "wifi".
> 
> RF like wifi and bluetooth. However there are wifi and bt subnodes in
> the smd-edge subnode. Iris is just the antenna hardware if I understand
> correctly. Also this is just a documentation of the existing nodes that
> are present in msm8916.dtsi, but for whatever reason their documentation
> was missing in the txt file. Without adding this node in the YAML
> dtb_check fails.

It seems commit fd52bdae9ab0 ("wcn36xx: Disable 5GHz for wcn3620")
 added usage of "iris" property but did not document it in the bindings.

You can fix it by documenting (separate patch) existing practice or
document with changing the node name. I am not sure if it is worth the
effort, so just new patch please.

Best regards,
Krzysztof

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

* Re: [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML
  2022-05-12 11:02           ` Krzysztof Kozlowski
@ 2022-05-12 13:42             ` Sireesh Kodali
  0 siblings, 0 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-12 13:42 UTC (permalink / raw)
  To: Krzysztof Kozlowski, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier, Rob Herring, Krzysztof Kozlowski, Loic Poulain

On Thu May 12, 2022 at 4:32 PM IST, Krzysztof Kozlowski wrote:
> On 12/05/2022 11:32, Sireesh Kodali wrote:
> >>>>> +          - enum:
> >>>>> +              - qcom,pronto-v2-pil
> >>>>> +          - enum:
> >>>>> +              - qcom,pronto
> >>>>
> >>>> This does not look correct. The fallback compatible should not change.
> >>>> What is more, it was not documented in original binding, so this should
> >>>> be done in separate patch.
> >>>>
> >>>
> >>> This was not a change to the fallback compatible. 
> >>
> >> You made it an enum, so you expect it to use different fallback for
> >> different cases.
> >>
> >>> msm8916.dtsi's wcnss
> >>> node has "qcom,pronto" as the compatible string, which is why this was
> >>> added. It is however not documented in the txt file. Is it sufficient to
> >>> add a note in the commit message, or should it be split into a separate
> >>> commit?
> >>
> >> Please split it, assuming that fallback is correct. Maybe the fallback
> >> is wrong?
> > 
> > The code doesn't recognize "qcom,pronto", so perhaps the best solution
> > is to just remove that compatible from msm8916.dtsi?
>
> Eh, I don't know. You need to check, maybe also in downstream sources.
>

I just checked, it seems "qcom,pronto" is used by the wcnss driver in
/net. So both "qcom,pronto-v2-pil" and "qcom,pronto" need to be present,
but the latter wasn't documented.

> (...)
>
> >>>>
> >>>>> +
> >>>>> +  iris:
> >>>>
> >>>> Generic node name... what is "iris"?
> >>>>
> >>> Iris is the RF module, I'll make the description better
> >>
> >> RF like wifi? Then the property name should be "wifi".
> > 
> > RF like wifi and bluetooth. However there are wifi and bt subnodes in
> > the smd-edge subnode. Iris is just the antenna hardware if I understand
> > correctly. Also this is just a documentation of the existing nodes that
> > are present in msm8916.dtsi, but for whatever reason their documentation
> > was missing in the txt file. Without adding this node in the YAML
> > dtb_check fails.
>
> It seems commit fd52bdae9ab0 ("wcn36xx: Disable 5GHz for wcn3620")
>  added usage of "iris" property but did not document it in the bindings.
>
> You can fix it by documenting (separate patch) existing practice or
> document with changing the node name. I am not sure if it is worth the
> effort, so just new patch please.
>

I'll make a 2 separate patches, documenting the extra "qcom,pronto"
compatible, and the iris subnode.

Thanks,
Sireesh

> Best regards,
> Krzysztof


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

* Re: [PATCH 6/9] dt-bindings: remoteproc: qcom: mss: Convert bindings to YAML
  2022-05-11 16:15 ` [PATCH 6/9] dt-bindings: remoteproc: qcom: mss: Convert bindings to YAML Sireesh Kodali
  2022-05-11 17:50   ` Krzysztof Kozlowski
@ 2022-05-12 13:49   ` Rob Herring
  1 sibling, 0 replies; 35+ messages in thread
From: Rob Herring @ 2022-05-12 13:49 UTC (permalink / raw)
  To: Sireesh Kodali
  Cc: devicetree, Rob Herring, phone-devel, bjorn.andersson,
	Andy Gross, linux-arm-msm, linux-remoteproc, Krzysztof Kozlowski,
	Mathieu Poirier, linux-kernel, ~postmarketos/upstreaming

On Wed, 11 May 2022 21:45:59 +0530, Sireesh Kodali wrote:
> Convert the bindings to YAML from txt. The bindings follow a similar
> schema to `qcom,adsp.yaml`.
> 
> Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> ---
>  .../bindings/remoteproc/qcom,q6v5.txt         | 302 --------
>  .../bindings/remoteproc/qcom,q6v5.yaml        | 702 ++++++++++++++++++
>  2 files changed, 702 insertions(+), 302 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,q6v5.txt
>  create mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,q6v5.yaml
> 

Running 'make dtbs_check' with the schema in this patch gives the
following warnings. Consider if they are expected or the schema is
incorrect. These may not be new warnings.

Note that it is not yet a requirement to have 0 warnings for dtbs_check.
This will change in the future.

Full log is available here: https://patchwork.ozlabs.org/patch/


remoteproc@4080000: memory-region: [[123], [124]] is too long
	arch/arm64/boot/dts/qcom/sc7180-trogdor-coachz-r1.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-coachz-r1-lte.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-coachz-r3.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-coachz-r3-lte.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-limozeen-nots-r9.dtb

remoteproc@4080000: memory-region: [[124], [125]] is too long
	arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-limozeen-nots-r4.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-limozeen-nots-r5.dtb

remoteproc@4080000: memory-region: [[125], [126]] is too long
	arch/arm64/boot/dts/qcom/sc7180-trogdor-homestar-r2.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-homestar-r4.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-limozeen-r9.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-r9.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-r9-kb.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-r9-lte.dtb

remoteproc@4080000: memory-region: [[126], [127]] is too long
	arch/arm64/boot/dts/qcom/sc7180-trogdor-homestar-r3.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-limozeen-r4.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-r0.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-r1.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-r1-kb.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-r1-lte.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-r3.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-r3-kb.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor-r3-lte.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-pompom-r1.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-pompom-r1-lte.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-pompom-r2.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-pompom-r2-lte.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-pompom-r3.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-pompom-r3-lte.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-r1.dtb
	arch/arm64/boot/dts/qcom/sc7180-trogdor-r1-lte.dtb

remoteproc@4080000: memory-region: [[193], [194]] is too long
	arch/arm64/boot/dts/qcom/sc7280-herobrine-herobrine-r0.dtb

remoteproc@4080000: memory-region: [[200], [201]] is too long
	arch/arm64/boot/dts/qcom/sc7280-idp.dtb

remoteproc@4080000: memory-region: [[205], [206]] is too long
	arch/arm64/boot/dts/qcom/sc7280-idp2.dtb

remoteproc@4080000: memory-region: [[208], [209]] is too long
	arch/arm64/boot/dts/qcom/sc7280-crd.dtb

remoteproc@4080000: memory-region: [[213], [214]] is too long
	arch/arm64/boot/dts/qcom/sc7280-herobrine-herobrine-r1.dtb

remoteproc@4080000: memory-region: [[98], [99]] is too long
	arch/arm64/boot/dts/qcom/sc7180-idp.dtb

remoteproc@fc880000: 'power-domain-names' is a required property
	arch/arm/boot/dts/qcom-apq8074-dragonboard.dtb
	arch/arm/boot/dts/qcom-msm8974-fairphone-fp2.dtb
	arch/arm/boot/dts/qcom-msm8974-lge-nexus5-hammerhead.dtb
	arch/arm/boot/dts/qcom-msm8974-samsung-klte.dtb
	arch/arm/boot/dts/qcom-msm8974-sony-xperia-amami.dtb
	arch/arm/boot/dts/qcom-msm8974-sony-xperia-castor.dtb
	arch/arm/boot/dts/qcom-msm8974-sony-xperia-honami.dtb

remoteproc@fc880000: 'power-domains' is a required property
	arch/arm/boot/dts/qcom-apq8074-dragonboard.dtb
	arch/arm/boot/dts/qcom-msm8974-fairphone-fp2.dtb
	arch/arm/boot/dts/qcom-msm8974-lge-nexus5-hammerhead.dtb
	arch/arm/boot/dts/qcom-msm8974-samsung-klte.dtb
	arch/arm/boot/dts/qcom-msm8974-sony-xperia-amami.dtb
	arch/arm/boot/dts/qcom-msm8974-sony-xperia-castor.dtb
	arch/arm/boot/dts/qcom-msm8974-sony-xperia-honami.dtb


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

* Re: [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML
  2022-05-11 16:15 ` [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML Sireesh Kodali
  2022-05-11 17:15   ` Krzysztof Kozlowski
@ 2022-05-12 13:49   ` Rob Herring
  2022-12-01 13:22   ` Krzysztof Kozlowski
  2 siblings, 0 replies; 35+ messages in thread
From: Rob Herring @ 2022-05-12 13:49 UTC (permalink / raw)
  To: Sireesh Kodali
  Cc: devicetree, Andy Gross, linux-kernel, Rob Herring,
	bjorn.andersson, Krzysztof Kozlowski, linux-arm-msm,
	Mathieu Poirier, linux-remoteproc, phone-devel,
	~postmarketos/upstreaming

On Wed, 11 May 2022 21:45:57 +0530, Sireesh Kodali wrote:
> Convert the dt-bindings from txt to YAML. This is in preparation for
> including the relevant bindings for the MSM8953 platform's wcnss pil.
> 
> Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> ---
>  .../bindings/remoteproc/qcom,wcnss-pil.txt    | 177 --------------
>  .../bindings/remoteproc/qcom,wcnss-pil.yaml   | 228 ++++++++++++++++++
>  2 files changed, 228 insertions(+), 177 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.txt
>  create mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.yaml
> 

Running 'make dtbs_check' with the schema in this patch gives the
following warnings. Consider if they are expected or the schema is
incorrect. These may not be new warnings.

Note that it is not yet a requirement to have 0 warnings for dtbs_check.
This will change in the future.

Full log is available here: https://patchwork.ozlabs.org/patch/


remoteproc@a21b000: 'qcom,state', 'qcom,state-names' do not match any of the regexes: 'pinctrl-[0-9]+'
	arch/arm64/boot/dts/qcom/apq8016-sbc.dtb
	arch/arm64/boot/dts/qcom/msm8916-alcatel-idol347.dtb
	arch/arm64/boot/dts/qcom/msm8916-asus-z00l.dtb
	arch/arm64/boot/dts/qcom/msm8916-huawei-g7.dtb
	arch/arm64/boot/dts/qcom/msm8916-longcheer-l8150.dtb
	arch/arm64/boot/dts/qcom/msm8916-longcheer-l8910.dtb
	arch/arm64/boot/dts/qcom/msm8916-mtp.dtb
	arch/arm64/boot/dts/qcom/msm8916-samsung-a3u-eur.dtb
	arch/arm64/boot/dts/qcom/msm8916-samsung-a5u-eur.dtb
	arch/arm64/boot/dts/qcom/msm8916-samsung-j5.dtb
	arch/arm64/boot/dts/qcom/msm8916-samsung-serranove.dtb
	arch/arm64/boot/dts/qcom/msm8916-wingtech-wt88047.dtb
	arch/arm/boot/dts/qcom-apq8016-sbc.dtb
	arch/arm/boot/dts/qcom-msm8916-samsung-serranove.dtb

remoteproc@fb21b000: 'power-domain-names' is a required property
	arch/arm/boot/dts/qcom-msm8974-fairphone-fp2.dtb

remoteproc@fb21b000: 'power-domains' is a required property
	arch/arm/boot/dts/qcom-msm8974-fairphone-fp2.dtb


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

* Re: [PATCH 9/9] arm64: dts: qcom: msm8953: Add remote processor nodes
  2022-05-12  9:19     ` Sireesh Kodali
@ 2022-05-12 14:37       ` Krzysztof Kozlowski
  2022-05-12 15:15         ` Sireesh Kodali
  0 siblings, 1 reply; 35+ messages in thread
From: Krzysztof Kozlowski @ 2022-05-12 14:37 UTC (permalink / raw)
  To: Sireesh Kodali, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross, Rob Herring,
	Krzysztof Kozlowski

On 12/05/2022 11:19, Sireesh Kodali wrote:
> On Wed May 11, 2022 at 11:25 PM IST, Krzysztof Kozlowski wrote:
>> On 11/05/2022 18:16, Sireesh Kodali wrote:
>>> This commit adds the modem (q6v5_mss), WiFi (wcnss-pil) and audio DSP
>>> (q6v5_pas) remote processor nodes for the MSM8953 platform. It also adds
>>> the coresponding SMP2P, SMSM and pinctrl nodes that are needed by these
>>> remote processors.
>>>
>>> Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
>>> +			};
>>> +
>>> +			wcnss_sleep: wcnss-sleep-pins {
>>> +				wcss_wlan2 {
>>
>> No underscores in node names, unless something needs it?
>>
> 
> wcnss_sleep is used by the pronto node defined below

wcnss_sleep is not a node name and it is not in the line where I commented.

Best regards,
Krzysztof

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

* Re: [PATCH 9/9] arm64: dts: qcom: msm8953: Add remote processor nodes
  2022-05-12 14:37       ` Krzysztof Kozlowski
@ 2022-05-12 15:15         ` Sireesh Kodali
  0 siblings, 0 replies; 35+ messages in thread
From: Sireesh Kodali @ 2022-05-12 15:15 UTC (permalink / raw)
  To: Krzysztof Kozlowski, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross, Rob Herring,
	Krzysztof Kozlowski

On Thu May 12, 2022 at 8:07 PM IST, Krzysztof Kozlowski wrote:
> On 12/05/2022 11:19, Sireesh Kodali wrote:
> > On Wed May 11, 2022 at 11:25 PM IST, Krzysztof Kozlowski wrote:
> >> On 11/05/2022 18:16, Sireesh Kodali wrote:
> >>> This commit adds the modem (q6v5_mss), WiFi (wcnss-pil) and audio DSP
> >>> (q6v5_pas) remote processor nodes for the MSM8953 platform. It also adds
> >>> the coresponding SMP2P, SMSM and pinctrl nodes that are needed by these
> >>> remote processors.
> >>>
> >>> Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> >>> +			};
> >>> +
> >>> +			wcnss_sleep: wcnss-sleep-pins {
> >>> +				wcss_wlan2 {
> >>
> >> No underscores in node names, unless something needs it?
> >>
> > 
> > wcnss_sleep is used by the pronto node defined below
>
> wcnss_sleep is not a node name and it is not in the line where I commented.
>
Sorry, I'll fix it in v2
> Best regards,
> Krzysztof

Thanks,
Sireesh

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

* Re: [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML
  2022-05-11 16:15 ` [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML Sireesh Kodali
  2022-05-11 17:15   ` Krzysztof Kozlowski
  2022-05-12 13:49   ` Rob Herring
@ 2022-12-01 13:22   ` Krzysztof Kozlowski
  2022-12-01 16:17     ` Sireesh Kodali
  2 siblings, 1 reply; 35+ messages in thread
From: Krzysztof Kozlowski @ 2022-12-01 13:22 UTC (permalink / raw)
  To: Sireesh Kodali, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier, Rob Herring, Krzysztof Kozlowski

On 11/05/2022 18:15, Sireesh Kodali wrote:
> Convert the dt-bindings from txt to YAML. This is in preparation for
> including the relevant bindings for the MSM8953 platform's wcnss pil.
> 
> Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> ---
>  .../bindings/remoteproc/qcom,wcnss-pil.txt    | 177 --------------
>  .../bindings/remoteproc/qcom,wcnss-pil.yaml   | 228 ++++++++++++++++++
>  2 files changed, 228 insertions(+), 177 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.txt
>  create mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.yaml
> 

Half year passed, so I wonder if these series are abandoned or shall we
expect v2?

Best regards,
Krzysztof


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

* Re: [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML
  2022-12-01 13:22   ` Krzysztof Kozlowski
@ 2022-12-01 16:17     ` Sireesh Kodali
  2022-12-01 16:24       ` Krzysztof Kozlowski
  0 siblings, 1 reply; 35+ messages in thread
From: Sireesh Kodali @ 2022-12-01 16:17 UTC (permalink / raw)
  To: Krzysztof Kozlowski, linux-remoteproc
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier, Rob Herring, Krzysztof Kozlowski

On Thu Dec 1, 2022 at 6:52 PM IST, Krzysztof Kozlowski wrote:
> On 11/05/2022 18:15, Sireesh Kodali wrote:
> > Convert the dt-bindings from txt to YAML. This is in preparation for
> > including the relevant bindings for the MSM8953 platform's wcnss pil.
> > 
> > Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
> > ---
> >  .../bindings/remoteproc/qcom,wcnss-pil.txt    | 177 --------------
> >  .../bindings/remoteproc/qcom,wcnss-pil.yaml   | 228 ++++++++++++++++++
> >  2 files changed, 228 insertions(+), 177 deletions(-)
> >  delete mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.txt
> >  create mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.yaml
> > 
>
> Half year passed, so I wonder if these series are abandoned or shall we
> expect v2?
>

This series was split into sub-series to make upstreaming easier. Links
to the sub-series:
WCNSS: https://lkml.org/lkml/2022/9/30/1502
ADSP: https://lkml.org/lkml/2022/10/13/5

Regards,
Sireesh
> Best regards,
> Krzysztof


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

* Re: [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML
  2022-12-01 16:17     ` Sireesh Kodali
@ 2022-12-01 16:24       ` Krzysztof Kozlowski
  0 siblings, 0 replies; 35+ messages in thread
From: Krzysztof Kozlowski @ 2022-12-01 16:24 UTC (permalink / raw)
  To: Sireesh Kodali, linux-remoteproc, Bjorn Andersson
  Cc: linux-arm-msm, ~postmarketos/upstreaming, bjorn.andersson,
	devicetree, phone-devel, linux-kernel, Andy Gross,
	Mathieu Poirier, Rob Herring, Krzysztof Kozlowski

On 01/12/2022 17:17, Sireesh Kodali wrote:
> On Thu Dec 1, 2022 at 6:52 PM IST, Krzysztof Kozlowski wrote:
>> On 11/05/2022 18:15, Sireesh Kodali wrote:
>>> Convert the dt-bindings from txt to YAML. This is in preparation for
>>> including the relevant bindings for the MSM8953 platform's wcnss pil.
>>>
>>> Signed-off-by: Sireesh Kodali <sireeshkodali1@gmail.com>
>>> ---
>>>  .../bindings/remoteproc/qcom,wcnss-pil.txt    | 177 --------------
>>>  .../bindings/remoteproc/qcom,wcnss-pil.yaml   | 228 ++++++++++++++++++
>>>  2 files changed, 228 insertions(+), 177 deletions(-)
>>>  delete mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.txt
>>>  create mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,wcnss-pil.yaml
>>>
>>
>> Half year passed, so I wonder if these series are abandoned or shall we
>> expect v2?
>>
> 
> This series was split into sub-series to make upstreaming easier. Links
> to the sub-series:
> WCNSS: https://lkml.org/lkml/2022/9/30/1502
> ADSP: https://lkml.org/lkml/2022/10/13/5


I see, thanks. I wonder why they were not picked up... The ADSP was sent
more than a month ago.

Best regards,
Krzysztof


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

end of thread, other threads:[~2022-12-01 16:25 UTC | newest]

Thread overview: 35+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-11 16:15 [PATCH 0/9] Add support for remoteprocs on the MSM8953 platform Sireesh Kodali
2022-05-11 16:15 ` [PATCH 1/9] remoteproc: qcom: pas: Add MSM8953 ADSP PIL support Sireesh Kodali
2022-05-11 16:49   ` Dmitry Baryshkov
2022-05-11 16:51   ` Dmitry Baryshkov
2022-05-12 10:39     ` Sireesh Kodali
2022-05-11 16:15 ` [PATCH 2/9] remoteproc: qcom: q6v5-mss: Add modem support on MSM8953 Sireesh Kodali
2022-05-11 16:54   ` Dmitry Baryshkov
2022-05-12  5:16     ` Sireesh Kodali
2022-05-12 10:38     ` Sireesh Kodali
2022-05-11 16:15 ` [PATCH 3/9] remoteproc: qcom: qcom_wcnss: Add support for pronto-v3 Sireesh Kodali
2022-05-11 16:15 ` [PATCH 4/9] dt-bindings: remoteproc: qcom: wcnss: Convert to YAML Sireesh Kodali
2022-05-11 17:15   ` Krzysztof Kozlowski
2022-05-12  6:50     ` Sireesh Kodali
2022-05-12  8:14       ` Krzysztof Kozlowski
2022-05-12  9:32         ` Sireesh Kodali
2022-05-12 11:02           ` Krzysztof Kozlowski
2022-05-12 13:42             ` Sireesh Kodali
2022-05-12  8:36       ` Krzysztof Kozlowski
2022-05-12 10:01         ` Sireesh Kodali
2022-05-12 13:49   ` Rob Herring
2022-12-01 13:22   ` Krzysztof Kozlowski
2022-12-01 16:17     ` Sireesh Kodali
2022-12-01 16:24       ` Krzysztof Kozlowski
2022-05-11 16:15 ` [PATCH 5/9] dt-bindings: remoteproc: qcom: wcnss: Add compatible for pronto v3 Sireesh Kodali
2022-05-11 16:15 ` [PATCH 6/9] dt-bindings: remoteproc: qcom: mss: Convert bindings to YAML Sireesh Kodali
2022-05-11 17:50   ` Krzysztof Kozlowski
2022-05-12  9:50     ` Sireesh Kodali
2022-05-12 13:49   ` Rob Herring
2022-05-11 16:16 ` [PATCH 7/9] dt-bindings: remoteproc: qcom: mss: Add MSS on MSM8953 Sireesh Kodali
2022-05-11 16:16 ` [PATCH 8/9] dt-bindings: remoteproc: qcom: adsp: Add ADSP " Sireesh Kodali
2022-05-11 16:16 ` [PATCH 9/9] arm64: dts: qcom: msm8953: Add remote processor nodes Sireesh Kodali
2022-05-11 17:55   ` Krzysztof Kozlowski
2022-05-12  9:19     ` Sireesh Kodali
2022-05-12 14:37       ` Krzysztof Kozlowski
2022-05-12 15:15         ` Sireesh Kodali

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.