devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/2] Rpmsg support for i.MX DSP with resource table
@ 2023-09-12 15:30 Iuliana Prodan (OSS)
  2023-09-12 15:30 ` [PATCH v2 1/2] remoteproc: imx_dsp_rproc: add mandatory find_loaded_rsc_table op Iuliana Prodan (OSS)
  2023-09-12 15:30 ` [PATCH v2 2/2] arm64: dts: imx8mp: add reserve-memory nodes for DSP Iuliana Prodan (OSS)
  0 siblings, 2 replies; 4+ messages in thread
From: Iuliana Prodan (OSS) @ 2023-09-12 15:30 UTC (permalink / raw)
  To: Mathieu Poirier, robh+dt, krzysztof.kozlowski+dt, conor+dt,
	Shawn Guo, Bjorn Andersson, Sascha Hauer, S.J. Wang,
	Fabio Estevam, devicetree, Daniel Baluta, Mpuaudiosw,
	Iuliana Prodan
  Cc: linux-imx, linux-remoteproc, linux-arm-kernel, linux-kernel,
	Pengutronix Kernel Team, LnxRevLi

From: Iuliana Prodan <iuliana.prodan@nxp.com>

These patches are needed in order to support rpmsg on DSP when a
resource table is available.

Changes since v1:
 - add missing bracket in dtsi (patch 2/2)

Iuliana Prodan (2):
  remoteproc: imx_dsp_rproc: add mandatory find_loaded_rsc_table op
  arm64: dts: imx8mp: add reserve-memory nodes for DSP

 arch/arm64/boot/dts/freescale/imx8mp.dtsi | 13 +++++++++++++
 drivers/remoteproc/imx_dsp_rproc.c        |  1 +
 2 files changed, 14 insertions(+)

-- 
2.17.1


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

* [PATCH v2 1/2] remoteproc: imx_dsp_rproc: add mandatory find_loaded_rsc_table op
  2023-09-12 15:30 [PATCH v2 0/2] Rpmsg support for i.MX DSP with resource table Iuliana Prodan (OSS)
@ 2023-09-12 15:30 ` Iuliana Prodan (OSS)
  2023-09-12 15:30 ` [PATCH v2 2/2] arm64: dts: imx8mp: add reserve-memory nodes for DSP Iuliana Prodan (OSS)
  1 sibling, 0 replies; 4+ messages in thread
From: Iuliana Prodan (OSS) @ 2023-09-12 15:30 UTC (permalink / raw)
  To: Mathieu Poirier, robh+dt, krzysztof.kozlowski+dt, conor+dt,
	Shawn Guo, Bjorn Andersson, Sascha Hauer, S.J. Wang,
	Fabio Estevam, devicetree, Daniel Baluta, Mpuaudiosw,
	Iuliana Prodan
  Cc: linux-imx, linux-remoteproc, linux-arm-kernel, linux-kernel,
	Pengutronix Kernel Team, LnxRevLi

From: Iuliana Prodan <iuliana.prodan@nxp.com>

Add the .find_loaded_rsc_table operation for i.MX DSP.
We need it for inter-process communication between DSP
and main core.

This callback is used to find the resource table (defined
in remote processor linker script) where the address of the
vrings along with the other allocated resources (carveouts etc)
are stored.
If this is not found, the vrings are not allocated and
the IPC between cores will not work.

Signed-off-by: Iuliana Prodan <iuliana.prodan@nxp.com>
Reviewed-by: Daniel Baluta <daniel.baluta@nxp.com>
---
 drivers/remoteproc/imx_dsp_rproc.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/remoteproc/imx_dsp_rproc.c b/drivers/remoteproc/imx_dsp_rproc.c
index 8fcda9b74545..a1c62d15f16c 100644
--- a/drivers/remoteproc/imx_dsp_rproc.c
+++ b/drivers/remoteproc/imx_dsp_rproc.c
@@ -940,6 +940,7 @@ static const struct rproc_ops imx_dsp_rproc_ops = {
 	.kick		= imx_dsp_rproc_kick,
 	.load		= imx_dsp_rproc_elf_load_segments,
 	.parse_fw	= imx_dsp_rproc_parse_fw,
+	.find_loaded_rsc_table = rproc_elf_find_loaded_rsc_table,
 	.sanity_check	= rproc_elf_sanity_check,
 	.get_boot_addr	= rproc_elf_get_boot_addr,
 };
-- 
2.17.1


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

* [PATCH v2 2/2] arm64: dts: imx8mp: add reserve-memory nodes for DSP
  2023-09-12 15:30 [PATCH v2 0/2] Rpmsg support for i.MX DSP with resource table Iuliana Prodan (OSS)
  2023-09-12 15:30 ` [PATCH v2 1/2] remoteproc: imx_dsp_rproc: add mandatory find_loaded_rsc_table op Iuliana Prodan (OSS)
@ 2023-09-12 15:30 ` Iuliana Prodan (OSS)
  2023-09-25  2:31   ` Shawn Guo
  1 sibling, 1 reply; 4+ messages in thread
From: Iuliana Prodan (OSS) @ 2023-09-12 15:30 UTC (permalink / raw)
  To: Mathieu Poirier, robh+dt, krzysztof.kozlowski+dt, conor+dt,
	Shawn Guo, Bjorn Andersson, Sascha Hauer, S.J. Wang,
	Fabio Estevam, devicetree, Daniel Baluta, Mpuaudiosw,
	Iuliana Prodan
  Cc: linux-imx, linux-remoteproc, linux-arm-kernel, linux-kernel,
	Pengutronix Kernel Team, LnxRevLi

From: Iuliana Prodan <iuliana.prodan@nxp.com>

Add the reserve-memory nodes used by DSP when the rpmsg
feature is enabled.

Signed-off-by: Iuliana Prodan <iuliana.prodan@nxp.com>
---
 arch/arm64/boot/dts/freescale/imx8mp.dtsi | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/arch/arm64/boot/dts/freescale/imx8mp.dtsi b/arch/arm64/boot/dts/freescale/imx8mp.dtsi
index cc406bb338fe..59e672382b07 100644
--- a/arch/arm64/boot/dts/freescale/imx8mp.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx8mp.dtsi
@@ -211,6 +211,19 @@
 			reg = <0 0x92400000 0 0x2000000>;
 			no-map;
 		};
+		dsp_vdev0vring0: vdev0vring0@942f0000 {
+			reg = <0 0x942f0000 0 0x8000>;
+			no-map;
+		};
+		dsp_vdev0vring1: vdev0vring1@942f8000 {
+			reg = <0 0x942f8000 0 0x8000>;
+			no-map;
+		};
+		dsp_vdev0buffer: vdev0buffer@94300000 {
+			compatible = "shared-dma-pool";
+			reg = <0 0x94300000 0 0x100000>;
+			no-map;
+		};
 	};
 
 	pmu {
-- 
2.17.1


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

* Re: [PATCH v2 2/2] arm64: dts: imx8mp: add reserve-memory nodes for DSP
  2023-09-12 15:30 ` [PATCH v2 2/2] arm64: dts: imx8mp: add reserve-memory nodes for DSP Iuliana Prodan (OSS)
@ 2023-09-25  2:31   ` Shawn Guo
  0 siblings, 0 replies; 4+ messages in thread
From: Shawn Guo @ 2023-09-25  2:31 UTC (permalink / raw)
  To: Iuliana Prodan (OSS)
  Cc: Mathieu Poirier, robh+dt, krzysztof.kozlowski+dt, conor+dt,
	Bjorn Andersson, Sascha Hauer, S.J. Wang, Fabio Estevam,
	devicetree, Daniel Baluta, Mpuaudiosw, Iuliana Prodan, linux-imx,
	linux-remoteproc, linux-arm-kernel, linux-kernel,
	Pengutronix Kernel Team, LnxRevLi

On Tue, Sep 12, 2023 at 06:30:21PM +0300, Iuliana Prodan (OSS) wrote:
> From: Iuliana Prodan <iuliana.prodan@nxp.com>
> 
> Add the reserve-memory nodes used by DSP when the rpmsg
> feature is enabled.
> 
> Signed-off-by: Iuliana Prodan <iuliana.prodan@nxp.com>
> ---
>  arch/arm64/boot/dts/freescale/imx8mp.dtsi | 13 +++++++++++++
>  1 file changed, 13 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/freescale/imx8mp.dtsi b/arch/arm64/boot/dts/freescale/imx8mp.dtsi
> index cc406bb338fe..59e672382b07 100644
> --- a/arch/arm64/boot/dts/freescale/imx8mp.dtsi
> +++ b/arch/arm64/boot/dts/freescale/imx8mp.dtsi
> @@ -211,6 +211,19 @@
>  			reg = <0 0x92400000 0 0x2000000>;
>  			no-map;
>  		};
> +		dsp_vdev0vring0: vdev0vring0@942f0000 {
> +			reg = <0 0x942f0000 0 0x8000>;
> +			no-map;
> +		};

Please have a newline between nodes.

Shawn

> +		dsp_vdev0vring1: vdev0vring1@942f8000 {
> +			reg = <0 0x942f8000 0 0x8000>;
> +			no-map;
> +		};
> +		dsp_vdev0buffer: vdev0buffer@94300000 {
> +			compatible = "shared-dma-pool";
> +			reg = <0 0x94300000 0 0x100000>;
> +			no-map;
> +		};
>  	};
>  
>  	pmu {
> -- 
> 2.17.1
> 

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

end of thread, other threads:[~2023-09-25  2:31 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-09-12 15:30 [PATCH v2 0/2] Rpmsg support for i.MX DSP with resource table Iuliana Prodan (OSS)
2023-09-12 15:30 ` [PATCH v2 1/2] remoteproc: imx_dsp_rproc: add mandatory find_loaded_rsc_table op Iuliana Prodan (OSS)
2023-09-12 15:30 ` [PATCH v2 2/2] arm64: dts: imx8mp: add reserve-memory nodes for DSP Iuliana Prodan (OSS)
2023-09-25  2:31   ` Shawn Guo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).