diff mbox series

[08/10] arm64: dts: mt8195: Add dma-ranges for the parent "soc" node

Message ID 20230113060133.9394-9-yong.wu@mediatek.com (mailing list archive)
State New, archived
Headers show
Series Adjust the dma-ranges for MTK IOMMU | expand

Commit Message

Yong Wu (吴勇) Jan. 13, 2023, 6:01 a.m. UTC
After commit f1ad5338a4d5 ("of: Fix "dma-ranges" handling for bus
controllers"), the dma-ranges property is not allowed for
the leaf node. But our iommu/dma-ranges is 16GB, we still expect
separate the 16GB dma-range like:
a) display is in 0 - 4GB;
b) vcodec is in 4GB - 8GB;
c) camera is in 8GB - 12GB.
We can not expect all the masters add a parent node for them,
especial for the existed drivers/nodes.
Thus, we add whole the 16GB dma-ranges in the parent "soc" node.

Signed-off-by: Yong Wu <yong.wu@mediatek.com>
---
 arch/arm64/boot/dts/mediatek/mt8195.dtsi | 1 +
 1 file changed, 1 insertion(+)

Comments

AngeloGioacchino Del Regno Jan. 16, 2023, 9:47 a.m. UTC | #1
Il 13/01/23 07:01, Yong Wu ha scritto:
> After commit f1ad5338a4d5 ("of: Fix "dma-ranges" handling for bus
> controllers"), the dma-ranges property is not allowed for
> the leaf node. But our iommu/dma-ranges is 16GB, we still expect
> separate the 16GB dma-range like:
> a) display is in 0 - 4GB;
> b) vcodec is in 4GB - 8GB;
> c) camera is in 8GB - 12GB.
> We can not expect all the masters add a parent node for them,
> especial for the existed drivers/nodes.
> Thus, we add whole the 16GB dma-ranges in the parent "soc" node.
> 
> Signed-off-by: Yong Wu <yong.wu@mediatek.com>

Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
diff mbox series

Patch

diff --git a/arch/arm64/boot/dts/mediatek/mt8195.dtsi b/arch/arm64/boot/dts/mediatek/mt8195.dtsi
index 5d31536f4c48..175eb7a25307 100644
--- a/arch/arm64/boot/dts/mediatek/mt8195.dtsi
+++ b/arch/arm64/boot/dts/mediatek/mt8195.dtsi
@@ -299,6 +299,7 @@ 
 		#size-cells = <2>;
 		compatible = "simple-bus";
 		ranges;
+		dma-ranges = <0x0 0x0 0x0 0x0 0x4 0x0>;
 
 		gic: interrupt-controller@c000000 {
 			compatible = "arm,gic-v3";