All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 00/02] arm64: dts: r8a7795: IPMMU upstream integration V2
@ 2016-12-19  2:19 Magnus Damm
  2016-12-19  2:19 ` [PATCH v2 01/02] arm64: dts: r8a7795: Add IPMMU device nodes Magnus Damm
  2016-12-19  2:19 ` [PATCH v2 02/02] arm64: dts: r8a7795: Hook up SYS-DMAC to IPMMU Magnus Damm
  0 siblings, 2 replies; 7+ messages in thread
From: Magnus Damm @ 2016-12-19  2:19 UTC (permalink / raw)
  To: linux-renesas-soc
  Cc: horms+renesas, Magnus Damm, laurent.pinchart+renesas, joro,
	geert+renesas

arm64: dts: r8a7795: IPMMU upstream integration V2

[PATCH v2 01/02] arm64: dts: r8a7795: Add IPMMU device nodes
[PATCH v2 02/02] arm64: dts: r8a7795: Hook up SYS-DMAC to IPMMU

This series adds DT nodes for IPMMU devices on r8a7795 together
with connections to the DMAC hardware. Currently all the IPMMU
devices remain disabled, but once next hardware iteration of
r8a7795 becomes available (with errata fixes) we can start
enabling the IPMMU devices.

The DT binding for r8a7795 has since long been included in mainline
and this series implements support following such format:

d4e42e7 iommu/ipmmu-vmsa: Add r8a7795 DT binding

The second patch in this series that ties the IPMMU to DMAC devices
has been blocked on DMA Engine framework changes, and in v4.10-rc
the last two patches are in:

60c4e80 arm64: Wire up iommu_dma_{map, unmap}_resource()
51f8cc9 iommu/dma: Implement dma_{map,unmap}_resource()

Compared to the earlier V1 series the last two patches have been
dropped due to lacking software support.

I hope these patches now can be queued up for upstream merge,
ideally aiming at v4.11-rc.

Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---

 Developed on top of renesas-devel-20161212-v4.9

 No special run time or compile time dependencies.

 Earlier posted as
 [PATCH 00/04] arm64: dts: r8a7795: Initial IPMMU upstream integration

 arch/arm64/boot/dts/renesas/r8a7795.dtsi |  153 ++++++++++++++++++++++++++++++
 1 file changed, 153 insertions(+)

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

* [PATCH v2 01/02] arm64: dts: r8a7795: Add IPMMU device nodes
  2016-12-19  2:19 [PATCH v2 00/02] arm64: dts: r8a7795: IPMMU upstream integration V2 Magnus Damm
@ 2016-12-19  2:19 ` Magnus Damm
  2016-12-19  7:39   ` Laurent Pinchart
  2016-12-19  2:19 ` [PATCH v2 02/02] arm64: dts: r8a7795: Hook up SYS-DMAC to IPMMU Magnus Damm
  1 sibling, 1 reply; 7+ messages in thread
From: Magnus Damm @ 2016-12-19  2:19 UTC (permalink / raw)
  To: linux-renesas-soc
  Cc: horms+renesas, Magnus Damm, laurent.pinchart+renesas, joro,
	geert+renesas

From: Magnus Damm <damm+renesas@opensource.se>

Add r8a7795 IPMMU nodes and keep all disabled by default.

Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---

 Changes from V1:
 - None

 arch/arm64/boot/dts/renesas/r8a7795.dtsi |  113 ++++++++++++++++++++++++++++++
 1 file changed, 113 insertions(+)

--- 0001/arch/arm64/boot/dts/renesas/r8a7795.dtsi
+++ work/arch/arm64/boot/dts/renesas/r8a7795.dtsi	2016-12-19 11:02:33.260607110 +0900
@@ -423,6 +423,119 @@
 			power-domains = <&sysc R8A7795_PD_ALWAYS_ON>;
 		};
 
+		ipmmu_vi: mmu@febd0000 {
+			compatible = "renesas,ipmmu-r8a7795";
+			reg = <0 0xfebd0000 0 0x1000>; /* IPMMU-VI */
+			renesas,ipmmu-main = <&ipmmu_mm 11>;
+			#iommu-cells = <1>;
+			status = "disabled";
+		};
+
+		ipmmu_vp: mmu@fe990000 {
+			compatible = "renesas,ipmmu-r8a7795";
+			reg = <0 0xfe990000 0 0x1000>; /* IPMMU-VP */
+			renesas,ipmmu-main = <&ipmmu_mm 12>;
+			#iommu-cells = <1>;
+			status = "disabled";
+		};
+
+		ipmmu_vc0: mmu@fe6b0000 {
+			compatible = "renesas,ipmmu-r8a7795";
+			reg = <0 0xfe6b0000 0 0x1000>; /* IPMMU-VC0 */
+			renesas,ipmmu-main = <&ipmmu_mm 9>;
+			#iommu-cells = <1>;
+			status = "disabled";
+		};
+
+		ipmmu_vc1: mmu@fe6f0000 {
+			compatible = "renesas,ipmmu-r8a7795";
+			reg = <0 0xfe6f0000 0 0x1000>; /* IPMMU-VC1 */
+			renesas,ipmmu-main = <&ipmmu_mm 10>;
+			#iommu-cells = <1>;
+			status = "disabled";
+		};
+
+		ipmmu_pv0: mmu@fd800000 {
+			compatible = "renesas,ipmmu-r8a7795";
+			reg = <0 0xfd800000 0 0x1000>; /* IPMMU-PV0 */
+			renesas,ipmmu-main = <&ipmmu_mm 6>;
+			#iommu-cells = <1>;
+			status = "disabled";
+		};
+
+		ipmmu_ir: mmu@ff8b0000 {
+			compatible = "renesas,ipmmu-r8a7795";
+			reg = <0 0xff8b0000 0 0x1000>; /* IPMMU-IR */
+			renesas,ipmmu-main = <&ipmmu_mm 3>;
+			#iommu-cells = <1>;
+			status = "disabled";
+		};
+
+		ipmmu_hc: mmu@e6570000 {
+			compatible = "renesas,ipmmu-r8a7795";
+			reg = <0 0xe6570000 0 0x1000>; /* IPMMU-HC */
+			renesas,ipmmu-main = <&ipmmu_mm 2>;
+			#iommu-cells = <1>;
+			status = "disabled";
+		};
+
+		ipmmu_rt: mmu@ffc80000 {
+			compatible = "renesas,ipmmu-r8a7795";
+			reg = <0 0xffc80000 0 0x1000>; /* IPMMU-RT */
+			renesas,ipmmu-main = <&ipmmu_mm 7>;
+			#iommu-cells = <1>;
+			status = "disabled";
+		};
+
+		ipmmu_mp0: mmu@ec670000 {
+			compatible = "renesas,ipmmu-r8a7795";
+			reg = <0 0xec670000 0 0x1000>; /* IPMMU-MP0 */
+			renesas,ipmmu-main = <&ipmmu_mm 4>;
+			#iommu-cells = <1>;
+			status = "disabled";
+		};
+
+		ipmmu_mp1: mmu@ec680000 {
+			compatible = "renesas,ipmmu-r8a7795";
+			reg = <0 0xec680000 0 0x1000>; /* IPMMU-MP1 */
+			renesas,ipmmu-main = <&ipmmu_mm 5>;
+			#iommu-cells = <1>;
+			status = "disabled";
+		};
+
+		ipmmu_sy: mmu@e7730000 {
+			compatible = "renesas,ipmmu-r8a7795";
+			reg = <0 0xe7730000 0 0x1000>; /* IPMMU-SY */
+			renesas,ipmmu-main = <&ipmmu_mm 8>;
+			#iommu-cells = <1>;
+			status = "disabled";
+		};
+
+		ipmmu_ds0: mmu@e6740000 {
+			compatible = "renesas,ipmmu-r8a7795";
+			reg = <0 0xe6740000 0 0x1000>; /* IPMMU-DS0 */
+			renesas,ipmmu-main = <&ipmmu_mm 0>;
+			#iommu-cells = <1>;
+			status = "disabled";
+		};
+
+		ipmmu_ds1: mmu@e7740000 {
+			compatible = "renesas,ipmmu-r8a7795";
+			reg = <0 0xe7740000 0 0x1000>; /* IPMMU-DS1 */
+			renesas,ipmmu-main = <&ipmmu_mm 1>;
+			#iommu-cells = <1>;
+			status = "disabled";
+		};
+
+		ipmmu_mm: mmu@e67b0000 {
+			compatible = "renesas,ipmmu-r8a7795";
+			reg = <0 0xe67b0000 0 0x1000>; /* IPMMU-MM */
+			interrupts = <GIC_SPI 196 IRQ_TYPE_LEVEL_HIGH>,
+				     <GIC_SPI 197 IRQ_TYPE_LEVEL_HIGH>;
+			#iommu-cells = <1>;
+			status = "disabled";
+		};
+
 		dmac0: dma-controller@e6700000 {
 			compatible = "renesas,dmac-r8a7795",
 				     "renesas,rcar-dmac";

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

* [PATCH v2 02/02] arm64: dts: r8a7795: Hook up SYS-DMAC to IPMMU
  2016-12-19  2:19 [PATCH v2 00/02] arm64: dts: r8a7795: IPMMU upstream integration V2 Magnus Damm
  2016-12-19  2:19 ` [PATCH v2 01/02] arm64: dts: r8a7795: Add IPMMU device nodes Magnus Damm
@ 2016-12-19  2:19 ` Magnus Damm
  2016-12-19  7:51   ` Laurent Pinchart
  2017-02-07 10:23   ` Geert Uytterhoeven
  1 sibling, 2 replies; 7+ messages in thread
From: Magnus Damm @ 2016-12-19  2:19 UTC (permalink / raw)
  To: linux-renesas-soc
  Cc: horms+renesas, Magnus Damm, laurent.pinchart+renesas, joro,
	geert+renesas

From: Magnus Damm <damm+renesas@opensource.se>

Hook up r8a7795 DMAC nodes to IPMMU-MP1, IPMMU-DS0 and IPMMU-DS1.

Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
---

 Changes from V1:
 - None

 arch/arm64/boot/dts/renesas/r8a7795.dtsi |   40 ++++++++++++++++++++++++++++++
 1 file changed, 40 insertions(+)

--- 0002/arch/arm64/boot/dts/renesas/r8a7795.dtsi
+++ work/arch/arm64/boot/dts/renesas/r8a7795.dtsi	2016-12-19 11:03:23.310607110 +0900
@@ -368,6 +368,14 @@
 			power-domains = <&sysc R8A7795_PD_ALWAYS_ON>;
 			#dma-cells = <1>;
 			dma-channels = <16>;
+			iommus = <&ipmmu_mp1 0>, <&ipmmu_mp1 1>,
+			       <&ipmmu_mp1 2>, <&ipmmu_mp1 3>,
+			       <&ipmmu_mp1 4>, <&ipmmu_mp1 5>,
+			       <&ipmmu_mp1 6>, <&ipmmu_mp1 7>,
+			       <&ipmmu_mp1 8>, <&ipmmu_mp1 9>,
+			       <&ipmmu_mp1 10>, <&ipmmu_mp1 11>,
+			       <&ipmmu_mp1 12>, <&ipmmu_mp1 13>,
+			       <&ipmmu_mp1 14>, <&ipmmu_mp1 15>;
 		};
 
 		audma1: dma-controller@ec720000 {
@@ -401,6 +409,14 @@
 			power-domains = <&sysc R8A7795_PD_ALWAYS_ON>;
 			#dma-cells = <1>;
 			dma-channels = <16>;
+			iommus = <&ipmmu_mp1 16>, <&ipmmu_mp1 17>,
+			       <&ipmmu_mp1 18>, <&ipmmu_mp1 19>,
+			       <&ipmmu_mp1 20>, <&ipmmu_mp1 21>,
+			       <&ipmmu_mp1 22>, <&ipmmu_mp1 23>,
+			       <&ipmmu_mp1 24>, <&ipmmu_mp1 25>,
+			       <&ipmmu_mp1 26>, <&ipmmu_mp1 27>,
+			       <&ipmmu_mp1 28>, <&ipmmu_mp1 29>,
+			       <&ipmmu_mp1 30>, <&ipmmu_mp1 31>;
 		};
 
 		pfc: pfc@e6060000 {
@@ -567,6 +583,14 @@
 			power-domains = <&sysc R8A7795_PD_ALWAYS_ON>;
 			#dma-cells = <1>;
 			dma-channels = <16>;
+			iommus = <&ipmmu_ds0 0>, <&ipmmu_ds0 1>,
+			       <&ipmmu_ds0 2>, <&ipmmu_ds0 3>,
+			       <&ipmmu_ds0 4>, <&ipmmu_ds0 5>,
+			       <&ipmmu_ds0 6>, <&ipmmu_ds0 7>,
+			       <&ipmmu_ds0 8>, <&ipmmu_ds0 9>,
+			       <&ipmmu_ds0 10>, <&ipmmu_ds0 11>,
+			       <&ipmmu_ds0 12>, <&ipmmu_ds0 13>,
+			       <&ipmmu_ds0 14>, <&ipmmu_ds0 15>;
 		};
 
 		dmac1: dma-controller@e7300000 {
@@ -600,6 +624,14 @@
 			power-domains = <&sysc R8A7795_PD_ALWAYS_ON>;
 			#dma-cells = <1>;
 			dma-channels = <16>;
+			iommus = <&ipmmu_ds1 0>, <&ipmmu_ds1 1>,
+			       <&ipmmu_ds1 2>, <&ipmmu_ds1 3>,
+			       <&ipmmu_ds1 4>, <&ipmmu_ds1 5>,
+			       <&ipmmu_ds1 6>, <&ipmmu_ds1 7>,
+			       <&ipmmu_ds1 8>, <&ipmmu_ds1 9>,
+			       <&ipmmu_ds1 10>, <&ipmmu_ds1 11>,
+			       <&ipmmu_ds1 12>, <&ipmmu_ds1 13>,
+			       <&ipmmu_ds1 14>, <&ipmmu_ds1 15>;
 		};
 
 		dmac2: dma-controller@e7310000 {
@@ -633,6 +665,14 @@
 			power-domains = <&sysc R8A7795_PD_ALWAYS_ON>;
 			#dma-cells = <1>;
 			dma-channels = <16>;
+			iommus = <&ipmmu_ds1 16>, <&ipmmu_ds1 17>,
+			       <&ipmmu_ds1 18>, <&ipmmu_ds1 19>,
+			       <&ipmmu_ds1 20>, <&ipmmu_ds1 21>,
+			       <&ipmmu_ds1 22>, <&ipmmu_ds1 23>,
+			       <&ipmmu_ds1 24>, <&ipmmu_ds1 25>,
+			       <&ipmmu_ds1 26>, <&ipmmu_ds1 27>,
+			       <&ipmmu_ds1 28>, <&ipmmu_ds1 29>,
+			       <&ipmmu_ds1 30>, <&ipmmu_ds1 31>;
 		};
 
 		avb: ethernet@e6800000 {

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

* Re: [PATCH v2 01/02] arm64: dts: r8a7795: Add IPMMU device nodes
  2016-12-19  2:19 ` [PATCH v2 01/02] arm64: dts: r8a7795: Add IPMMU device nodes Magnus Damm
@ 2016-12-19  7:39   ` Laurent Pinchart
  0 siblings, 0 replies; 7+ messages in thread
From: Laurent Pinchart @ 2016-12-19  7:39 UTC (permalink / raw)
  To: Magnus Damm; +Cc: linux-renesas-soc, horms+renesas, joro, geert+renesas

Hi Magnus,

Thank you for the patch.

On Monday 19 Dec 2016 11:19:41 Magnus Damm wrote:
> From: Magnus Damm <damm+renesas@opensource.se>
> 
> Add r8a7795 IPMMU nodes and keep all disabled by default.
> 
> Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
> ---
> 
>  Changes from V1:
>  - None
> 
>  arch/arm64/boot/dts/renesas/r8a7795.dtsi |  113 +++++++++++++++++++++++++++
>  1 file changed, 113 insertions(+)
> 
> --- 0001/arch/arm64/boot/dts/renesas/r8a7795.dtsi
> +++ work/arch/arm64/boot/dts/renesas/r8a7795.dtsi	2016-12-19
> 11:02:33.260607110 +0900 @@ -423,6 +423,119 @@
>  			power-domains = <&sysc R8A7795_PD_ALWAYS_ON>;
>  		};
> 
> +		ipmmu_vi: mmu@febd0000 {
> +			compatible = "renesas,ipmmu-r8a7795";
> +			reg = <0 0xfebd0000 0 0x1000>; /* IPMMU-VI */
> +			renesas,ipmmu-main = <&ipmmu_mm 11>;
> +			#iommu-cells = <1>;
> +			status = "disabled";
> +		};
> +
> +		ipmmu_vp: mmu@fe990000 {
> +			compatible = "renesas,ipmmu-r8a7795";
> +			reg = <0 0xfe990000 0 0x1000>; /* IPMMU-VP */
> +			renesas,ipmmu-main = <&ipmmu_mm 12>;
> +			#iommu-cells = <1>;
> +			status = "disabled";
> +		};
> +
> +		ipmmu_vc0: mmu@fe6b0000 {
> +			compatible = "renesas,ipmmu-r8a7795";
> +			reg = <0 0xfe6b0000 0 0x1000>; /* IPMMU-VC0 */
> +			renesas,ipmmu-main = <&ipmmu_mm 9>;
> +			#iommu-cells = <1>;
> +			status = "disabled";
> +		};
> +
> +		ipmmu_vc1: mmu@fe6f0000 {
> +			compatible = "renesas,ipmmu-r8a7795";
> +			reg = <0 0xfe6f0000 0 0x1000>; /* IPMMU-VC1 */
> +			renesas,ipmmu-main = <&ipmmu_mm 10>;
> +			#iommu-cells = <1>;
> +			status = "disabled";
> +		};

According to the datasheet the VC0 and VC1 instances are in the A3VC power 
domain. The VP instance is documented to be in the A3VP power domain, but on 
ES1.x only. I'm not sure whether the lack of power domain for ES2 is an 
oversight in the documentation or a real hardware change. The other ones 
should probably be added to the always-on power domain.

> +		ipmmu_pv0: mmu@fd800000 {
> +			compatible = "renesas,ipmmu-r8a7795";
> +			reg = <0 0xfd800000 0 0x1000>; /* IPMMU-PV0 */
> +			renesas,ipmmu-main = <&ipmmu_mm 6>;
> +			#iommu-cells = <1>;
> +			status = "disabled";
> +		};
> +
> +		ipmmu_ir: mmu@ff8b0000 {
> +			compatible = "renesas,ipmmu-r8a7795";
> +			reg = <0 0xff8b0000 0 0x1000>; /* IPMMU-IR */
> +			renesas,ipmmu-main = <&ipmmu_mm 3>;
> +			#iommu-cells = <1>;
> +			status = "disabled";
> +		};
> +
> +		ipmmu_hc: mmu@e6570000 {
> +			compatible = "renesas,ipmmu-r8a7795";
> +			reg = <0 0xe6570000 0 0x1000>; /* IPMMU-HC */
> +			renesas,ipmmu-main = <&ipmmu_mm 2>;
> +			#iommu-cells = <1>;
> +			status = "disabled";
> +		};
> +
> +		ipmmu_rt: mmu@ffc80000 {
> +			compatible = "renesas,ipmmu-r8a7795";
> +			reg = <0 0xffc80000 0 0x1000>; /* IPMMU-RT */
> +			renesas,ipmmu-main = <&ipmmu_mm 7>;
> +			#iommu-cells = <1>;
> +			status = "disabled";
> +		};
> +
> +		ipmmu_mp0: mmu@ec670000 {
> +			compatible = "renesas,ipmmu-r8a7795";
> +			reg = <0 0xec670000 0 0x1000>; /* IPMMU-MP0 */
> +			renesas,ipmmu-main = <&ipmmu_mm 4>;
> +			#iommu-cells = <1>;
> +			status = "disabled";
> +		};
> +
> +		ipmmu_mp1: mmu@ec680000 {
> +			compatible = "renesas,ipmmu-r8a7795";
> +			reg = <0 0xec680000 0 0x1000>; /* IPMMU-MP1 */
> +			renesas,ipmmu-main = <&ipmmu_mm 5>;
> +			#iommu-cells = <1>;
> +			status = "disabled";
> +		};
> +
> +		ipmmu_sy: mmu@e7730000 {
> +			compatible = "renesas,ipmmu-r8a7795";
> +			reg = <0 0xe7730000 0 0x1000>; /* IPMMU-SY */
> +			renesas,ipmmu-main = <&ipmmu_mm 8>;
> +			#iommu-cells = <1>;
> +			status = "disabled";
> +		};
> +
> +		ipmmu_ds0: mmu@e6740000 {
> +			compatible = "renesas,ipmmu-r8a7795";
> +			reg = <0 0xe6740000 0 0x1000>; /* IPMMU-DS0 */
> +			renesas,ipmmu-main = <&ipmmu_mm 0>;
> +			#iommu-cells = <1>;
> +			status = "disabled";
> +		};
> +
> +		ipmmu_ds1: mmu@e7740000 {
> +			compatible = "renesas,ipmmu-r8a7795";
> +			reg = <0 0xe7740000 0 0x1000>; /* IPMMU-DS1 */
> +			renesas,ipmmu-main = <&ipmmu_mm 1>;
> +			#iommu-cells = <1>;
> +			status = "disabled";
> +		};
> +
> +		ipmmu_mm: mmu@e67b0000 {
> +			compatible = "renesas,ipmmu-r8a7795";

Wouldn't it make sense to use a different compatible string for the master 
IOMMU, as it's quite different from the slaves ?

> +			reg = <0 0xe67b0000 0 0x1000>; /* IPMMU-MM */
> +			interrupts = <GIC_SPI 196 IRQ_TYPE_LEVEL_HIGH>,
> +				     <GIC_SPI 197 IRQ_TYPE_LEVEL_HIGH>;
> +			#iommu-cells = <1>;
> +			status = "disabled";

I wonder where the clocks are. They're not documented, but I'd be surprised if 
they did not exist. This can always be addressed later anyway, it's not a 
blocker.

Apart from that,

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

(with all register addresses, interrupts and slave indices verified)

> +		};
> +
>  		dmac0: dma-controller@e6700000 {
>  			compatible = "renesas,dmac-r8a7795",
>  				     "renesas,rcar-dmac";

-- 
Regards,

Laurent Pinchart

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

* Re: [PATCH v2 02/02] arm64: dts: r8a7795: Hook up SYS-DMAC to IPMMU
  2016-12-19  2:19 ` [PATCH v2 02/02] arm64: dts: r8a7795: Hook up SYS-DMAC to IPMMU Magnus Damm
@ 2016-12-19  7:51   ` Laurent Pinchart
  2016-12-19  8:39     ` Laurent Pinchart
  2017-02-07 10:23   ` Geert Uytterhoeven
  1 sibling, 1 reply; 7+ messages in thread
From: Laurent Pinchart @ 2016-12-19  7:51 UTC (permalink / raw)
  To: Magnus Damm; +Cc: linux-renesas-soc, horms+renesas, joro, geert+renesas

Hi Magnus,

Thank you for the patch.

On Monday 19 Dec 2016 11:19:50 Magnus Damm wrote:
> From: Magnus Damm <damm+renesas@opensource.se>
> 
> Hook up r8a7795 DMAC nodes to IPMMU-MP1, IPMMU-DS0 and IPMMU-DS1.

I assume you have verified that hooking up a disabled IOMMU doesn't adversely 
affect system operation.

> Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
> ---
> 
>  Changes from V1:
>  - None
> 
>  arch/arm64/boot/dts/renesas/r8a7795.dtsi |   40 +++++++++++++++++++++++++++
>  1 file changed, 40 insertions(+)
> 
> --- 0002/arch/arm64/boot/dts/renesas/r8a7795.dtsi
> +++ work/arch/arm64/boot/dts/renesas/r8a7795.dtsi	2016-12-19
> 11:03:23.310607110 +0900 @@ -368,6 +368,14 @@
>  			power-domains = <&sysc R8A7795_PD_ALWAYS_ON>;
>  			#dma-cells = <1>;
>  			dma-channels = <16>;
> +			iommus = <&ipmmu_mp1 0>, <&ipmmu_mp1 1>,
> +			       <&ipmmu_mp1 2>, <&ipmmu_mp1 3>,
> +			       <&ipmmu_mp1 4>, <&ipmmu_mp1 5>,
> +			       <&ipmmu_mp1 6>, <&ipmmu_mp1 7>,
> +			       <&ipmmu_mp1 8>, <&ipmmu_mp1 9>,
> +			       <&ipmmu_mp1 10>, <&ipmmu_mp1 11>,
> +			       <&ipmmu_mp1 12>, <&ipmmu_mp1 13>,
> +			       <&ipmmu_mp1 14>, <&ipmmu_mp1 15>;

This is the audio DMAC, you should update the commit subject.

With this fixed,

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

>  		};
> 
>  		audma1: dma-controller@ec720000 {
> @@ -401,6 +409,14 @@
>  			power-domains = <&sysc R8A7795_PD_ALWAYS_ON>;
>  			#dma-cells = <1>;
>  			dma-channels = <16>;
> +			iommus = <&ipmmu_mp1 16>, <&ipmmu_mp1 17>,
> +			       <&ipmmu_mp1 18>, <&ipmmu_mp1 19>,
> +			       <&ipmmu_mp1 20>, <&ipmmu_mp1 21>,
> +			       <&ipmmu_mp1 22>, <&ipmmu_mp1 23>,
> +			       <&ipmmu_mp1 24>, <&ipmmu_mp1 25>,
> +			       <&ipmmu_mp1 26>, <&ipmmu_mp1 27>,
> +			       <&ipmmu_mp1 28>, <&ipmmu_mp1 29>,
> +			       <&ipmmu_mp1 30>, <&ipmmu_mp1 31>;
>  		};
> 
>  		pfc: pfc@e6060000 {
> @@ -567,6 +583,14 @@
>  			power-domains = <&sysc R8A7795_PD_ALWAYS_ON>;
>  			#dma-cells = <1>;
>  			dma-channels = <16>;
> +			iommus = <&ipmmu_ds0 0>, <&ipmmu_ds0 1>,
> +			       <&ipmmu_ds0 2>, <&ipmmu_ds0 3>,
> +			       <&ipmmu_ds0 4>, <&ipmmu_ds0 5>,
> +			       <&ipmmu_ds0 6>, <&ipmmu_ds0 7>,
> +			       <&ipmmu_ds0 8>, <&ipmmu_ds0 9>,
> +			       <&ipmmu_ds0 10>, <&ipmmu_ds0 11>,
> +			       <&ipmmu_ds0 12>, <&ipmmu_ds0 13>,
> +			       <&ipmmu_ds0 14>, <&ipmmu_ds0 15>;
>  		};
> 
>  		dmac1: dma-controller@e7300000 {
> @@ -600,6 +624,14 @@
>  			power-domains = <&sysc R8A7795_PD_ALWAYS_ON>;
>  			#dma-cells = <1>;
>  			dma-channels = <16>;
> +			iommus = <&ipmmu_ds1 0>, <&ipmmu_ds1 1>,
> +			       <&ipmmu_ds1 2>, <&ipmmu_ds1 3>,
> +			       <&ipmmu_ds1 4>, <&ipmmu_ds1 5>,
> +			       <&ipmmu_ds1 6>, <&ipmmu_ds1 7>,
> +			       <&ipmmu_ds1 8>, <&ipmmu_ds1 9>,
> +			       <&ipmmu_ds1 10>, <&ipmmu_ds1 11>,
> +			       <&ipmmu_ds1 12>, <&ipmmu_ds1 13>,
> +			       <&ipmmu_ds1 14>, <&ipmmu_ds1 15>;
>  		};
> 
>  		dmac2: dma-controller@e7310000 {
> @@ -633,6 +665,14 @@
>  			power-domains = <&sysc R8A7795_PD_ALWAYS_ON>;
>  			#dma-cells = <1>;
>  			dma-channels = <16>;
> +			iommus = <&ipmmu_ds1 16>, <&ipmmu_ds1 17>,
> +			       <&ipmmu_ds1 18>, <&ipmmu_ds1 19>,
> +			       <&ipmmu_ds1 20>, <&ipmmu_ds1 21>,
> +			       <&ipmmu_ds1 22>, <&ipmmu_ds1 23>,
> +			       <&ipmmu_ds1 24>, <&ipmmu_ds1 25>,
> +			       <&ipmmu_ds1 26>, <&ipmmu_ds1 27>,
> +			       <&ipmmu_ds1 28>, <&ipmmu_ds1 29>,
> +			       <&ipmmu_ds1 30>, <&ipmmu_ds1 31>;
>  		};
> 
>  		avb: ethernet@e6800000 {

-- 
Regards,

Laurent Pinchart

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

* Re: [PATCH v2 02/02] arm64: dts: r8a7795: Hook up SYS-DMAC to IPMMU
  2016-12-19  7:51   ` Laurent Pinchart
@ 2016-12-19  8:39     ` Laurent Pinchart
  0 siblings, 0 replies; 7+ messages in thread
From: Laurent Pinchart @ 2016-12-19  8:39 UTC (permalink / raw)
  To: Magnus Damm; +Cc: linux-renesas-soc, horms+renesas, joro, geert+renesas

Hi Magnus,

On Monday 19 Dec 2016 09:51:44 Laurent Pinchart wrote:
> On Monday 19 Dec 2016 11:19:50 Magnus Damm wrote:
> > From: Magnus Damm <damm+renesas@opensource.se>
> > 
> > Hook up r8a7795 DMAC nodes to IPMMU-MP1, IPMMU-DS0 and IPMMU-DS1.
> 
> I assume you have verified that hooking up a disabled IOMMU doesn't
> adversely affect system operation.

I saw in a reply to v1 that you have verified this on top of the renesas-
drivers tree, so I give it a try on mainline. The DMAC devices get probed 
properly and dmatest completes without failures.

> > Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
> > ---
> > 
> >  Changes from V1:
> >  - None
> >  
> >  arch/arm64/boot/dts/renesas/r8a7795.dtsi |   40 ++++++++++++++++++++++++
> >  1 file changed, 40 insertions(+)

-- 
Regards,

Laurent Pinchart

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

* Re: [PATCH v2 02/02] arm64: dts: r8a7795: Hook up SYS-DMAC to IPMMU
  2016-12-19  2:19 ` [PATCH v2 02/02] arm64: dts: r8a7795: Hook up SYS-DMAC to IPMMU Magnus Damm
  2016-12-19  7:51   ` Laurent Pinchart
@ 2017-02-07 10:23   ` Geert Uytterhoeven
  1 sibling, 0 replies; 7+ messages in thread
From: Geert Uytterhoeven @ 2017-02-07 10:23 UTC (permalink / raw)
  To: Magnus Damm
  Cc: Linux-Renesas, Simon Horman, Laurent Pinchart, Joerg Roedel,
	Geert Uytterhoeven

Hi Magnus,

On Mon, Dec 19, 2016 at 3:19 AM, Magnus Damm <magnus.damm@gmail.com> wrote:
> From: Magnus Damm <damm+renesas@opensource.se>
>
> Hook up r8a7795 DMAC nodes to IPMMU-MP1, IPMMU-DS0 and IPMMU-DS1.
>
> Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
> ---
>
>  Changes from V1:
>  - None
>
>  arch/arm64/boot/dts/renesas/r8a7795.dtsi |   40 ++++++++++++++++++++++++++++++
>  1 file changed, 40 insertions(+)
>
> --- 0002/arch/arm64/boot/dts/renesas/r8a7795.dtsi
> +++ work/arch/arm64/boot/dts/renesas/r8a7795.dtsi       2016-12-19 11:03:23.310607110 +0900
> @@ -368,6 +368,14 @@
>                         power-domains = <&sysc R8A7795_PD_ALWAYS_ON>;
>                         #dma-cells = <1>;
>                         dma-channels = <16>;
> +                       iommus = <&ipmmu_mp1 0>, <&ipmmu_mp1 1>,
> +                              <&ipmmu_mp1 2>, <&ipmmu_mp1 3>,
> +                              <&ipmmu_mp1 4>, <&ipmmu_mp1 5>,
> +                              <&ipmmu_mp1 6>, <&ipmmu_mp1 7>,
> +                              <&ipmmu_mp1 8>, <&ipmmu_mp1 9>,
> +                              <&ipmmu_mp1 10>, <&ipmmu_mp1 11>,
> +                              <&ipmmu_mp1 12>, <&ipmmu_mp1 13>,
> +                              <&ipmmu_mp1 14>, <&ipmmu_mp1 15>;

For consistency, you may want to add these line just below the power-domains
property (everywhere).

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

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

end of thread, other threads:[~2017-02-07 10:24 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-12-19  2:19 [PATCH v2 00/02] arm64: dts: r8a7795: IPMMU upstream integration V2 Magnus Damm
2016-12-19  2:19 ` [PATCH v2 01/02] arm64: dts: r8a7795: Add IPMMU device nodes Magnus Damm
2016-12-19  7:39   ` Laurent Pinchart
2016-12-19  2:19 ` [PATCH v2 02/02] arm64: dts: r8a7795: Hook up SYS-DMAC to IPMMU Magnus Damm
2016-12-19  7:51   ` Laurent Pinchart
2016-12-19  8:39     ` Laurent Pinchart
2017-02-07 10:23   ` Geert Uytterhoeven

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.