Linux Remote Processor Subsystem development
 help / color / mirror / Atom feed
* [PATCH v3 0/4] Add RPROC support for the MX95-15x15-FRDM board
@ 2026-07-30 16:34 Laurentiu Mihalcea
  2026-07-30 16:34 ` [PATCH v3 1/4] dt-bindings: remoteproc: imx_rproc: document optional "memory-region-names" Laurentiu Mihalcea
                   ` (3 more replies)
  0 siblings, 4 replies; 11+ messages in thread
From: Laurentiu Mihalcea @ 2026-07-30 16:34 UTC (permalink / raw)
  To: Bjorn Andersson, Mathieu Poirier, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Sascha Hauer, Peng Fan,
	Frank Li, Fabio Estevam, Daniel Baluta, Francesco Dolcini
  Cc: linux-remoteproc, devicetree, imx, linux-arm-kernel, linux-kernel

From: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>

Hi folks,

As you can see from the title, this series attempts to introduce/enable
RPROC support for the MX95-15x15-FRDM board.

For a while now, the imx_rproc driver has been using the reserved memory
DT nodes as the carveout names, which would force DT writers to go against
the DT specification's recommendation and use non-generic names (e.g.
"vdev0vring0", "vdev0vring1", etc...). This series also tries to fix this
issue by introducing the "memory-region-names" property and using it in
the imx_rproc driver to figure out the carveout names. The driver will
still allow the old way of doing things (i.e. no "memory-region-names"
property) but a warning will now be printed since this should be
discouraged.

---

Changes in v3:

* kept the DT binding patch because it fixes the ABI problem pointed out
by Frank. Modified the commit message to reflect this.
* link to v2: https://lore.kernel.org/lkml/20260605113621.1479-1-laurentiumihalcea111@gmail.com/

Changes in v2:

* change commit message of binding patch to describe why it's needed
* drop restrictions on the string names passed via "memory-region-names"
* drop patch moving the CM7 node to the SoC DTSI. CM7 node is now added
in the RPMSG DT overlay
* rewrite commit message of patch removing some of the RMEM regions from
the bord DTS - previous version was a stale version from first iterations
of this series
* change "micfil" node status from "disabled" to "reserved"
* add check against rmem phandle count and string count mismatch
* include "of_reserved_mem.h" in "imx_rproc.h" to avoid having to rely on
the consumers including it

---

Laurentiu Mihalcea (4):
  dt-bindings: remoteproc: imx_rproc: document optional
    "memory-region-names"
  remoteproc: imx_rpoc: fix carveout name parsing
  arm64: dts: freescale: imx95-15x15-frdm: remove some rmem regions
  arm64: dts: freescale: add DT overlay for MX95-15x15-FRDM RPMSG usage

 .../bindings/remoteproc/fsl,imx-rproc.yaml    |  4 ++
 arch/arm64/boot/dts/freescale/Makefile        |  3 +
 .../dts/freescale/imx95-15x15-frdm-rpmsg.dtso | 67 +++++++++++++++++++
 .../boot/dts/freescale/imx95-15x15-frdm.dts   | 21 ------
 drivers/remoteproc/imx_rproc.c                | 13 +++-
 drivers/remoteproc/imx_rproc.h                | 21 ++++++
 6 files changed, 106 insertions(+), 23 deletions(-)
 create mode 100644 arch/arm64/boot/dts/freescale/imx95-15x15-frdm-rpmsg.dtso

-- 
2.53.0


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

* [PATCH v3 1/4] dt-bindings: remoteproc: imx_rproc: document optional "memory-region-names"
  2026-07-30 16:34 [PATCH v3 0/4] Add RPROC support for the MX95-15x15-FRDM board Laurentiu Mihalcea
@ 2026-07-30 16:34 ` Laurentiu Mihalcea
  2026-07-30 18:14   ` Frank Li
  2026-07-31  9:37   ` Krzysztof Kozlowski
  2026-07-30 16:34 ` [PATCH v3 2/4] remoteproc: imx_rpoc: fix carveout name parsing Laurentiu Mihalcea
                   ` (2 subsequent siblings)
  3 siblings, 2 replies; 11+ messages in thread
From: Laurentiu Mihalcea @ 2026-07-30 16:34 UTC (permalink / raw)
  To: Bjorn Andersson, Mathieu Poirier, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Sascha Hauer, Peng Fan,
	Frank Li, Fabio Estevam, Daniel Baluta, Francesco Dolcini
  Cc: linux-remoteproc, devicetree, imx, linux-arm-kernel, linux-kernel

From: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>

The carveout region names are derived based on the DT node names. Because
of this, the DT node names are ABI, which is not supposed to happen.

Fix this by documenting an additional, optional property:
"memory-region-names". This way, the software will have a way to build the
carveout region names without relying on the DT node names.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
---
 .../devicetree/bindings/remoteproc/fsl,imx-rproc.yaml         | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml b/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml
index c18f71b64889..8e3e6676a95e 100644
--- a/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml
+++ b/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml
@@ -62,6 +62,10 @@ properties:
     minItems: 1
     maxItems: 32
 
+  memory-region-names:
+    minItems: 1
+    maxItems: 32
+
   power-domains:
     minItems: 2
     maxItems: 8
-- 
2.53.0


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

* [PATCH v3 2/4] remoteproc: imx_rpoc: fix carveout name parsing
  2026-07-30 16:34 [PATCH v3 0/4] Add RPROC support for the MX95-15x15-FRDM board Laurentiu Mihalcea
  2026-07-30 16:34 ` [PATCH v3 1/4] dt-bindings: remoteproc: imx_rproc: document optional "memory-region-names" Laurentiu Mihalcea
@ 2026-07-30 16:34 ` Laurentiu Mihalcea
  2026-07-30 16:58   ` Frank Li
  2026-07-31  9:38   ` Krzysztof Kozlowski
  2026-07-30 16:34 ` [PATCH v3 3/4] arm64: dts: freescale: imx95-15x15-frdm: remove some rmem regions Laurentiu Mihalcea
  2026-07-30 16:34 ` [PATCH v3 4/4] arm64: dts: freescale: add DT overlay for MX95-15x15-FRDM RPMSG usage Laurentiu Mihalcea
  3 siblings, 2 replies; 11+ messages in thread
From: Laurentiu Mihalcea @ 2026-07-30 16:34 UTC (permalink / raw)
  To: Bjorn Andersson, Mathieu Poirier, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Sascha Hauer, Peng Fan,
	Frank Li, Fabio Estevam, Daniel Baluta, Francesco Dolcini
  Cc: linux-remoteproc, devicetree, imx, linux-arm-kernel, linux-kernel

From: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>

The imx remoteproc driver assumes that the names of the reserved memory
regions reflect their usage (e.g. "vdevbuffer", "vdev0vring0", etc.). This
conflicts with the devicetree specification's recommendation, which states
that the names of the devicetree nodes should be generic.

Therefore, instead of relying on the node names, use the names passed via
the "memory-region-names" property if present. Otherwise, keep the old
behavior.

The definition of imx_rproc_rmem_to_resource() is added to a common place
as imx_dsp_rproc.c can also use it given that it suffers from the same
aforementioned problem.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
---
 drivers/remoteproc/imx_rproc.c | 13 +++++++++++--
 drivers/remoteproc/imx_rproc.h | 21 +++++++++++++++++++++
 2 files changed, 32 insertions(+), 2 deletions(-)

diff --git a/drivers/remoteproc/imx_rproc.c b/drivers/remoteproc/imx_rproc.c
index 745ce52cd822..ce9bdfc1fa98 100644
--- a/drivers/remoteproc/imx_rproc.c
+++ b/drivers/remoteproc/imx_rproc.c
@@ -643,7 +643,7 @@ static int imx_rproc_prepare(struct rproc *rproc)
 		int err;
 		struct resource res;
 
-		err = of_reserved_mem_region_to_resource(np, i++, &res);
+		err = imx_rproc_rmem_to_resource(np, i++, &res);
 		if (err)
 			break;
 
@@ -818,11 +818,20 @@ static int imx_rproc_addr_init(struct imx_rproc *priv,
 	if (nph <= 0)
 		return 0;
 
+	if (!of_property_present(np, "memory-region-names")) {
+		dev_warn(dev, "using node names for carveouts should be avoided\n");
+	} else {
+		if (nph != of_property_count_strings(np, "memory-region-names")) {
+			dev_err(dev, "invalid reserved memory name count\n");
+			return -EINVAL;
+		}
+	}
+
 	/* remap optional addresses */
 	for (a = 0; a < nph; a++) {
 		struct resource res;
 
-		err = of_reserved_mem_region_to_resource(np, a, &res);
+		err = imx_rproc_rmem_to_resource(np, a, &res);
 		if (err) {
 			dev_err(dev, "unable to resolve memory region\n");
 			return err;
diff --git a/drivers/remoteproc/imx_rproc.h b/drivers/remoteproc/imx_rproc.h
index 0d7d48352a10..3632bc375c71 100644
--- a/drivers/remoteproc/imx_rproc.h
+++ b/drivers/remoteproc/imx_rproc.h
@@ -7,6 +7,8 @@
 #ifndef _IMX_RPROC_H
 #define _IMX_RPROC_H
 
+#include <linux/of_reserved_mem.h>
+
 /* address translation table */
 struct imx_rproc_att {
 	u32 da;	/* device address (From Cortex M4 view)*/
@@ -45,4 +47,23 @@ struct imx_rproc_dcfg {
 	u32				reset_vector_mask;
 };
 
+static inline int imx_rproc_rmem_to_resource(struct device_node *np,
+					     int index,
+					     struct resource *res)
+{
+	int ret;
+
+	ret = of_reserved_mem_region_to_resource(np, index, res);
+	if (ret)
+		return ret;
+
+	/* "memory-region-names" is optional */
+	ret = of_property_read_string_index(np, "memory-region-names",
+					    index, &res->name);
+	if (ret == -EINVAL)
+		return 0;
+
+	return ret;
+}
+
 #endif /* _IMX_RPROC_H */
-- 
2.53.0


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

* [PATCH v3 3/4] arm64: dts: freescale: imx95-15x15-frdm: remove some rmem regions
  2026-07-30 16:34 [PATCH v3 0/4] Add RPROC support for the MX95-15x15-FRDM board Laurentiu Mihalcea
  2026-07-30 16:34 ` [PATCH v3 1/4] dt-bindings: remoteproc: imx_rproc: document optional "memory-region-names" Laurentiu Mihalcea
  2026-07-30 16:34 ` [PATCH v3 2/4] remoteproc: imx_rpoc: fix carveout name parsing Laurentiu Mihalcea
@ 2026-07-30 16:34 ` Laurentiu Mihalcea
  2026-07-30 16:34 ` [PATCH v3 4/4] arm64: dts: freescale: add DT overlay for MX95-15x15-FRDM RPMSG usage Laurentiu Mihalcea
  3 siblings, 0 replies; 11+ messages in thread
From: Laurentiu Mihalcea @ 2026-07-30 16:34 UTC (permalink / raw)
  To: Bjorn Andersson, Mathieu Poirier, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Sascha Hauer, Peng Fan,
	Frank Li, Fabio Estevam, Daniel Baluta, Francesco Dolcini
  Cc: linux-remoteproc, devicetree, imx, linux-arm-kernel, linux-kernel

From: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>

Remove some of the remoteproc reserved memory regions, which are currently
not being used for anything. These will be added in the DT overlay
enabling remoteproc support for this board.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
---
 .../boot/dts/freescale/imx95-15x15-frdm.dts   | 21 -------------------
 1 file changed, 21 deletions(-)

diff --git a/arch/arm64/boot/dts/freescale/imx95-15x15-frdm.dts b/arch/arm64/boot/dts/freescale/imx95-15x15-frdm.dts
index 0f43e3be7058..f9b0e266754d 100644
--- a/arch/arm64/boot/dts/freescale/imx95-15x15-frdm.dts
+++ b/arch/arm64/boot/dts/freescale/imx95-15x15-frdm.dts
@@ -188,16 +188,6 @@ linux_cma: linux,cma {
 			linux,cma-default;
 		};
 
-		vdev0vring0: memory@88000000 {
-			reg = <0 0x88000000 0 0x8000>;
-			no-map;
-		};
-
-		vdev0vring1: memory@88008000 {
-			reg = <0 0x88008000 0 0x8000>;
-			no-map;
-		};
-
 		vdev1vring0: memory@88010000 {
 			reg = <0 0x88010000 0 0x8000>;
 			no-map;
@@ -208,17 +198,6 @@ vdev1vring1: memory@88018000 {
 			no-map;
 		};
 
-		vdevbuffer: memory@88020000 {
-			compatible = "shared-dma-pool";
-			reg = <0 0x88020000 0 0x100000>;
-			no-map;
-		};
-
-		rsc_table: memory@88220000 {
-			reg = <0 0x88220000 0 0x1000>;
-			no-map;
-		};
-
 		vpu_boot: memory@a0000000 {
 			reg = <0 0xa0000000 0 0x100000>;
 			no-map;
-- 
2.53.0


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

* [PATCH v3 4/4] arm64: dts: freescale: add DT overlay for MX95-15x15-FRDM RPMSG usage
  2026-07-30 16:34 [PATCH v3 0/4] Add RPROC support for the MX95-15x15-FRDM board Laurentiu Mihalcea
                   ` (2 preceding siblings ...)
  2026-07-30 16:34 ` [PATCH v3 3/4] arm64: dts: freescale: imx95-15x15-frdm: remove some rmem regions Laurentiu Mihalcea
@ 2026-07-30 16:34 ` Laurentiu Mihalcea
  3 siblings, 0 replies; 11+ messages in thread
From: Laurentiu Mihalcea @ 2026-07-30 16:34 UTC (permalink / raw)
  To: Bjorn Andersson, Mathieu Poirier, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Sascha Hauer, Peng Fan,
	Frank Li, Fabio Estevam, Daniel Baluta, Francesco Dolcini
  Cc: linux-remoteproc, devicetree, imx, linux-arm-kernel, linux-kernel

From: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>

Add RPMSG DT overlay for the MX95-15x15-FRDM board. This overlay is meant
to be used with the mx95evkrpmsg system manager configuration for
remoteproc and audio over rpmsg-usecases.

Reviewed-by: Daniel Baluta <daniel.baluta@nxp.com>
Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
---
 arch/arm64/boot/dts/freescale/Makefile        |  3 +
 .../dts/freescale/imx95-15x15-frdm-rpmsg.dtso | 67 +++++++++++++++++++
 2 files changed, 70 insertions(+)
 create mode 100644 arch/arm64/boot/dts/freescale/imx95-15x15-frdm-rpmsg.dtso

diff --git a/arch/arm64/boot/dts/freescale/Makefile b/arch/arm64/boot/dts/freescale/Makefile
index 95ae85ab4adf..3f98132f5a32 100644
--- a/arch/arm64/boot/dts/freescale/Makefile
+++ b/arch/arm64/boot/dts/freescale/Makefile
@@ -707,6 +707,7 @@ dtb-$(CONFIG_ARCH_MXC) += imx943-evk-sdwifi.dtb
 dtb-$(CONFIG_ARCH_MXC) += imx95-15x15-ab2.dtb
 dtb-$(CONFIG_ARCH_MXC) += imx95-15x15-evk.dtb
 dtb-$(CONFIG_ARCH_MXC) += imx95-15x15-frdm.dtb
+dtb-$(CONFIG_ARCH_MXC) += imx95-15x15-frdm-rpmsg.dtb
 dtb-$(CONFIG_ARCH_MXC) += imx95-19x19-evk.dtb
 dtb-$(CONFIG_ARCH_MXC) += imx95-19x19-evk-sof.dtb
 dtb-$(CONFIG_ARCH_MXC) += imx95-19x19-frdm-pro.dtb
@@ -729,6 +730,8 @@ dtb-$(CONFIG_ARCH_MXC) += imx95-verdin-wifi-mallow.dtb
 dtb-$(CONFIG_ARCH_MXC) += imx95-verdin-wifi-yavia.dtb
 dtb-$(CONFIG_ARCH_MXC) += imx95-verdin-wifi-zinnia.dtb
 
+imx95-15x15-frdm-rpmsg-dtbs = imx95-15x15-frdm.dtb imx95-15x15-frdm-rpmsg.dtbo
+
 imx95-15x15-evk-pcie-dtbs += imx95-15x15-evk.dtb imx-m2-pcie.dtbo
 dtb-$(CONFIG_ARCH_MXC) += imx95-15x15-evk-pcie.dtb
 
diff --git a/arch/arm64/boot/dts/freescale/imx95-15x15-frdm-rpmsg.dtso b/arch/arm64/boot/dts/freescale/imx95-15x15-frdm-rpmsg.dtso
new file mode 100644
index 000000000000..bc02864c6f88
--- /dev/null
+++ b/arch/arm64/boot/dts/freescale/imx95-15x15-frdm-rpmsg.dtso
@@ -0,0 +1,67 @@
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+/*
+ * Copyright 2026 NXP
+ *
+ * This DT overlay is meant to be used alongside the mx95evkrpmsg SM
+ * configuration for remoteproc and audio over rpmsg.
+ */
+
+/dts-v1/;
+/plugin/;
+
+&{/} {
+	remoteproc-cm7 {
+		compatible = "fsl,imx95-cm7";
+		mboxes = <&mu7 0 1>, <&mu7 1 1>, <&mu7 3 1>;
+		mbox-names = "tx", "rx", "rxdb";
+		memory-region = <&vdev0buffer>, <&vdev0vring0>,
+				<&vdev0vring1>, <&rsc_table>;
+		memory-region-names = "vdev0buffer", "vdev0vring0",
+				      "vdev0vring1", "rsc-table";
+	};
+
+	reserved-memory {
+		#address-cells = <2>;
+		#size-cells = <2>;
+
+		vdev0vring0: memory@88000000 {
+			reg = <0 0x88000000 0 0x8000>;
+			no-map;
+		};
+
+		vdev0vring1: memory@88008000 {
+			reg = <0 0x88008000 0 0x8000>;
+			no-map;
+		};
+
+		vdev0buffer: memory@88020000 {
+			compatible = "shared-dma-pool";
+			reg = <0 0x88020000 0 0x100000>;
+			no-map;
+		};
+
+		rsc_table: memory@88220000 {
+			reg = <0 0x88220000 0 0x1000>;
+			no-map;
+		};
+	};
+
+	sound-micfil {
+		status = "disabled";
+	};
+};
+
+&edma1 {
+	/* reserved for M7 */
+	dma-channel-mask = <0x40>;
+};
+
+&edma2 {
+	/* reserved for M7 and V2X */
+	dma-channel-mask = <0xf>;
+};
+
+&micfil {
+	/* reserved for M7 */
+	status = "reserved";
+};
-- 
2.53.0


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

* Re: [PATCH v3 2/4] remoteproc: imx_rpoc: fix carveout name parsing
  2026-07-30 16:34 ` [PATCH v3 2/4] remoteproc: imx_rpoc: fix carveout name parsing Laurentiu Mihalcea
@ 2026-07-30 16:58   ` Frank Li
  2026-07-31  9:38   ` Krzysztof Kozlowski
  1 sibling, 0 replies; 11+ messages in thread
From: Frank Li @ 2026-07-30 16:58 UTC (permalink / raw)
  To: Laurentiu Mihalcea
  Cc: Bjorn Andersson, Mathieu Poirier, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Sascha Hauer, Peng Fan,
	Frank Li, Fabio Estevam, Daniel Baluta, Francesco Dolcini,
	linux-remoteproc, devicetree, imx, linux-arm-kernel, linux-kernel

On Thu, Jul 30, 2026 at 09:34:10AM -0700, Laurentiu Mihalcea wrote:
> From: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
>
> The imx remoteproc driver assumes that the names of the reserved memory
> regions reflect their usage (e.g. "vdevbuffer", "vdev0vring0", etc.). This
> conflicts with the devicetree specification's recommendation, which states
> that the names of the devicetree nodes should be generic.

This relies on a hidden ABI by parsing the remote node's name, and also
bypasses the DT binding check since there is no way to restrict the node
name of a memory region.

Frank
>
> Therefore, instead of relying on the node names, use the names passed via
> the "memory-region-names" property if present. Otherwise, keep the old
> behavior.
>
> The definition of imx_rproc_rmem_to_resource() is added to a common place
> as imx_dsp_rproc.c can also use it given that it suffers from the same
> aforementioned problem.
>
> Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
> ---
>  drivers/remoteproc/imx_rproc.c | 13 +++++++++++--
>  drivers/remoteproc/imx_rproc.h | 21 +++++++++++++++++++++
>  2 files changed, 32 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/remoteproc/imx_rproc.c b/drivers/remoteproc/imx_rproc.c
> index 745ce52cd822..ce9bdfc1fa98 100644
> --- a/drivers/remoteproc/imx_rproc.c
> +++ b/drivers/remoteproc/imx_rproc.c
> @@ -643,7 +643,7 @@ static int imx_rproc_prepare(struct rproc *rproc)
>  		int err;
>  		struct resource res;
>
> -		err = of_reserved_mem_region_to_resource(np, i++, &res);
> +		err = imx_rproc_rmem_to_resource(np, i++, &res);
>  		if (err)
>  			break;
>
> @@ -818,11 +818,20 @@ static int imx_rproc_addr_init(struct imx_rproc *priv,
>  	if (nph <= 0)
>  		return 0;
>
> +	if (!of_property_present(np, "memory-region-names")) {
> +		dev_warn(dev, "using node names for carveouts should be avoided\n");
> +	} else {
> +		if (nph != of_property_count_strings(np, "memory-region-names")) {
> +			dev_err(dev, "invalid reserved memory name count\n");
> +			return -EINVAL;
> +		}
> +	}
> +
>  	/* remap optional addresses */
>  	for (a = 0; a < nph; a++) {
>  		struct resource res;
>
> -		err = of_reserved_mem_region_to_resource(np, a, &res);
> +		err = imx_rproc_rmem_to_resource(np, a, &res);
>  		if (err) {
>  			dev_err(dev, "unable to resolve memory region\n");
>  			return err;
> diff --git a/drivers/remoteproc/imx_rproc.h b/drivers/remoteproc/imx_rproc.h
> index 0d7d48352a10..3632bc375c71 100644
> --- a/drivers/remoteproc/imx_rproc.h
> +++ b/drivers/remoteproc/imx_rproc.h
> @@ -7,6 +7,8 @@
>  #ifndef _IMX_RPROC_H
>  #define _IMX_RPROC_H
>
> +#include <linux/of_reserved_mem.h>
> +
>  /* address translation table */
>  struct imx_rproc_att {
>  	u32 da;	/* device address (From Cortex M4 view)*/
> @@ -45,4 +47,23 @@ struct imx_rproc_dcfg {
>  	u32				reset_vector_mask;
>  };
>
> +static inline int imx_rproc_rmem_to_resource(struct device_node *np,
> +					     int index,
> +					     struct resource *res)
> +{
> +	int ret;
> +
> +	ret = of_reserved_mem_region_to_resource(np, index, res);
> +	if (ret)
> +		return ret;
> +
> +	/* "memory-region-names" is optional */
> +	ret = of_property_read_string_index(np, "memory-region-names",
> +					    index, &res->name);
> +	if (ret == -EINVAL)
> +		return 0;
> +
> +	return ret;
> +}
> +
>  #endif /* _IMX_RPROC_H */
> --
> 2.53.0
>

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

* Re: [PATCH v3 1/4] dt-bindings: remoteproc: imx_rproc: document optional "memory-region-names"
  2026-07-30 16:34 ` [PATCH v3 1/4] dt-bindings: remoteproc: imx_rproc: document optional "memory-region-names" Laurentiu Mihalcea
@ 2026-07-30 18:14   ` Frank Li
  2026-07-31  9:37   ` Krzysztof Kozlowski
  1 sibling, 0 replies; 11+ messages in thread
From: Frank Li @ 2026-07-30 18:14 UTC (permalink / raw)
  To: Laurentiu Mihalcea
  Cc: Bjorn Andersson, Mathieu Poirier, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Sascha Hauer, Peng Fan,
	Frank Li, Fabio Estevam, Daniel Baluta, Francesco Dolcini,
	linux-remoteproc, devicetree, imx, linux-arm-kernel, linux-kernel

On Thu, Jul 30, 2026 at 09:34:09AM -0700, Laurentiu Mihalcea wrote:
> From: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
>
> The carveout region names are derived based on the DT node names. Because
> of this, the DT node names are ABI, which is not supposed to happen.
>
> Fix this by documenting an additional, optional property:
> "memory-region-names". This way, the software will have a way to build the
> carveout region names without relying on the DT node names.

"After update all existing DT tree, this will be required.

>
> Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
> ---

Additional information to help understand why it is important.

1. at thread wrong use vdevbuffer insteand vdev0buffer as node name
https://lore.kernel.org/imx/20260705202439.3F5771F000E9@smtp.kernel.org/
2. similar case happen at
https://lore.kernel.org/imx/20260715071741.79CA81F000E9@smtp.kernel.org/

Suppose these problem should be detected by dt binding check instead of
sashkio ai.


>  .../devicetree/bindings/remoteproc/fsl,imx-rproc.yaml         | 4 ++++
>  1 file changed, 4 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml b/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml
> index c18f71b64889..8e3e6676a95e 100644
> --- a/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml
> +++ b/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml
> @@ -62,6 +62,10 @@ properties:
>      minItems: 1
>      maxItems: 32
>
> +  memory-region-names:
> +    minItems: 1
> +    maxItems: 32
> +

Need restrict names

  memory-region-names:
    description:
      Names for the memory-region phandles. Each entry must be one of the
      following recognized names. "vdev0buffer" is the shared buffer for
      virtio device 0, handled automatically by the rproc virtio framework.
      "vdev<n>ring<n>" (e.g. "vdev0vring0", "vdev0vring1") are the virtio
      vring buffers for device N, also managed by the virtio framework.
      "rsc-table" is the resource table region used to share the resource
      table between Linux and the remote processor when it is pre-loaded in
      memory. All other entries are treated as generic carveout regions that
      are mapped and made available to the remote processor.
    minItems: 1
    maxItems: 32
    items:
      anyOf:
        - const: rsc-table
        - pattern: "^vdev[0-9]+buffer$"
        - pattern: "^vdev[0-9]+vring[0-9]+$"

Frank

>    power-domains:
>      minItems: 2
>      maxItems: 8
> --
> 2.53.0
>

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

* Re: [PATCH v3 1/4] dt-bindings: remoteproc: imx_rproc: document optional "memory-region-names"
  2026-07-30 16:34 ` [PATCH v3 1/4] dt-bindings: remoteproc: imx_rproc: document optional "memory-region-names" Laurentiu Mihalcea
  2026-07-30 18:14   ` Frank Li
@ 2026-07-31  9:37   ` Krzysztof Kozlowski
  2026-07-31  9:39     ` Krzysztof Kozlowski
  1 sibling, 1 reply; 11+ messages in thread
From: Krzysztof Kozlowski @ 2026-07-31  9:37 UTC (permalink / raw)
  To: Laurentiu Mihalcea
  Cc: Bjorn Andersson, Mathieu Poirier, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Sascha Hauer, Peng Fan,
	Frank Li, Fabio Estevam, Daniel Baluta, Francesco Dolcini,
	linux-remoteproc, devicetree, imx, linux-arm-kernel, linux-kernel

On Thu, Jul 30, 2026 at 09:34:09AM -0700, Laurentiu Mihalcea wrote:
> From: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
> 
> The carveout region names are derived based on the DT node names. Because
> of this, the DT node names are ABI, which is not supposed to happen.
> 
> Fix this by documenting an additional, optional property:
> "memory-region-names". This way, the software will have a way to build the
> carveout region names without relying on the DT node names.

That's not the point of xxx-names property. It only serves as a helper
to get the resource.

> 
> Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
> ---
>  .../devicetree/bindings/remoteproc/fsl,imx-rproc.yaml         | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml b/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml
> index c18f71b64889..8e3e6676a95e 100644
> --- a/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml
> +++ b/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml
> @@ -62,6 +62,10 @@ properties:
>      minItems: 1
>      maxItems: 32
>  
> +  memory-region-names:
> +    minItems: 1
> +    maxItems: 32

This cannot be flexible and unspecific. Why "yellow submarine" would be
a correct name?

Best regards,
Krzysztof


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

* Re: [PATCH v3 2/4] remoteproc: imx_rpoc: fix carveout name parsing
  2026-07-30 16:34 ` [PATCH v3 2/4] remoteproc: imx_rpoc: fix carveout name parsing Laurentiu Mihalcea
  2026-07-30 16:58   ` Frank Li
@ 2026-07-31  9:38   ` Krzysztof Kozlowski
  1 sibling, 0 replies; 11+ messages in thread
From: Krzysztof Kozlowski @ 2026-07-31  9:38 UTC (permalink / raw)
  To: Laurentiu Mihalcea
  Cc: Bjorn Andersson, Mathieu Poirier, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Sascha Hauer, Peng Fan,
	Frank Li, Fabio Estevam, Daniel Baluta, Francesco Dolcini,
	linux-remoteproc, devicetree, imx, linux-arm-kernel, linux-kernel

On Thu, Jul 30, 2026 at 09:34:10AM -0700, Laurentiu Mihalcea wrote:
> From: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
> 
> The imx remoteproc driver assumes that the names of the reserved memory
> regions reflect their usage (e.g. "vdevbuffer", "vdev0vring0", etc.). This
> conflicts with the devicetree specification's recommendation, which states
> that the names of the devicetree nodes should be generic.

This is not true and I already told you that at v2.

Best regards,
Krzysztof


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

* Re: [PATCH v3 1/4] dt-bindings: remoteproc: imx_rproc: document optional "memory-region-names"
  2026-07-31  9:37   ` Krzysztof Kozlowski
@ 2026-07-31  9:39     ` Krzysztof Kozlowski
  2026-07-31 14:34       ` Frank Li
  0 siblings, 1 reply; 11+ messages in thread
From: Krzysztof Kozlowski @ 2026-07-31  9:39 UTC (permalink / raw)
  To: Laurentiu Mihalcea
  Cc: Bjorn Andersson, Mathieu Poirier, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Sascha Hauer, Peng Fan,
	Frank Li, Fabio Estevam, Daniel Baluta, Francesco Dolcini,
	linux-remoteproc, devicetree, imx, linux-arm-kernel, linux-kernel

On 31/07/2026 11:37, Krzysztof Kozlowski wrote:
> On Thu, Jul 30, 2026 at 09:34:09AM -0700, Laurentiu Mihalcea wrote:
>> From: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
>>
>> The carveout region names are derived based on the DT node names. Because
>> of this, the DT node names are ABI, which is not supposed to happen.
>>
>> Fix this by documenting an additional, optional property:
>> "memory-region-names". This way, the software will have a way to build the
>> carveout region names without relying on the DT node names.
> 
> That's not the point of xxx-names property. It only serves as a helper
> to get the resource.
> 
>>
>> Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
>> ---
>>  .../devicetree/bindings/remoteproc/fsl,imx-rproc.yaml         | 4 ++++
>>  1 file changed, 4 insertions(+)
>>
>> diff --git a/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml b/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml
>> index c18f71b64889..8e3e6676a95e 100644
>> --- a/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml
>> +++ b/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml
>> @@ -62,6 +62,10 @@ properties:
>>      minItems: 1
>>      maxItems: 32
>>  
>> +  memory-region-names:
>> +    minItems: 1
>> +    maxItems: 32
> 
> This cannot be flexible and unspecific. Why "yellow submarine" would be
> a correct name?
> 

And I already SAID that at v2, so you just keep pushing this without
implementing feedback.

NAK

Best regards,
Krzysztof

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

* Re: [PATCH v3 1/4] dt-bindings: remoteproc: imx_rproc: document optional "memory-region-names"
  2026-07-31  9:39     ` Krzysztof Kozlowski
@ 2026-07-31 14:34       ` Frank Li
  0 siblings, 0 replies; 11+ messages in thread
From: Frank Li @ 2026-07-31 14:34 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Laurentiu Mihalcea, Bjorn Andersson, Mathieu Poirier, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Sascha Hauer, Peng Fan,
	Frank Li, Fabio Estevam, Daniel Baluta, Francesco Dolcini,
	linux-remoteproc, devicetree, imx, linux-arm-kernel, linux-kernel

On Fri, Jul 31, 2026 at 11:39:52AM +0200, Krzysztof Kozlowski wrote:
> On 31/07/2026 11:37, Krzysztof Kozlowski wrote:
> > On Thu, Jul 30, 2026 at 09:34:09AM -0700, Laurentiu Mihalcea wrote:
> >> From: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
> >>
> >> The carveout region names are derived based on the DT node names. Because
> >> of this, the DT node names are ABI, which is not supposed to happen.
> >>
> >> Fix this by documenting an additional, optional property:
> >> "memory-region-names". This way, the software will have a way to build the
> >> carveout region names without relying on the DT node names.
> >
> > That's not the point of xxx-names property. It only serves as a helper
> > to get the resource.
> >
> >>
> >> Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
> >> ---
> >>  .../devicetree/bindings/remoteproc/fsl,imx-rproc.yaml         | 4 ++++
> >>  1 file changed, 4 insertions(+)
> >>
> >> diff --git a/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml b/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml
> >> index c18f71b64889..8e3e6676a95e 100644
> >> --- a/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml
> >> +++ b/Documentation/devicetree/bindings/remoteproc/fsl,imx-rproc.yaml
> >> @@ -62,6 +62,10 @@ properties:
> >>      minItems: 1
> >>      maxItems: 32
> >>
> >> +  memory-region-names:
> >> +    minItems: 1
> >> +    maxItems: 32
> >
> > This cannot be flexible and unspecific. Why "yellow submarine" would be
> > a correct name?
> >
>
> And I already SAID that at v2, so you just keep pushing this without
> implementing feedback.
>
> NAK

Thanks you review these patch and I already sent out suggestion, could you
wait for me check it firstly to off load your work.

Frank

>
> Best regards,
> Krzysztof
>

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

end of thread, other threads:[~2026-07-31 14:35 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-30 16:34 [PATCH v3 0/4] Add RPROC support for the MX95-15x15-FRDM board Laurentiu Mihalcea
2026-07-30 16:34 ` [PATCH v3 1/4] dt-bindings: remoteproc: imx_rproc: document optional "memory-region-names" Laurentiu Mihalcea
2026-07-30 18:14   ` Frank Li
2026-07-31  9:37   ` Krzysztof Kozlowski
2026-07-31  9:39     ` Krzysztof Kozlowski
2026-07-31 14:34       ` Frank Li
2026-07-30 16:34 ` [PATCH v3 2/4] remoteproc: imx_rpoc: fix carveout name parsing Laurentiu Mihalcea
2026-07-30 16:58   ` Frank Li
2026-07-31  9:38   ` Krzysztof Kozlowski
2026-07-30 16:34 ` [PATCH v3 3/4] arm64: dts: freescale: imx95-15x15-frdm: remove some rmem regions Laurentiu Mihalcea
2026-07-30 16:34 ` [PATCH v3 4/4] arm64: dts: freescale: add DT overlay for MX95-15x15-FRDM RPMSG usage Laurentiu Mihalcea

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox