From: Michal Wilczynski Date: Wed, 28 Aug 2024 08:17:35 +0000 (+0200) Subject: riscv: dts: spacemit: Add reserved memory for dpu X-Git-Tag: accepted/tizen/unified/x/20240911.015644~10 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=0d8501e25a7f8f3cf12f2d1e65d7641a606236a2;p=platform%2Fkernel%2Flinux-riscv.git riscv: dts: spacemit: Add reserved memory for dpu The hdmi nodes are dependent on memory ranges for the dpu. Port them from the vendor kernel [1]. [1] - https://github.com/BPI-SINOVOIP/pi-linux.git Change-Id: I8e1e80c1ef3490f08aa56a5522de6d73d9560091 Signed-off-by: Michal Wilczynski --- diff --git a/arch/riscv/boot/dts/spacemit/k1-bananapi-f3.dts b/arch/riscv/boot/dts/spacemit/k1-bananapi-f3.dts index d642b8a85011..d1a54d28bc52 100644 --- a/arch/riscv/boot/dts/spacemit/k1-bananapi-f3.dts +++ b/arch/riscv/boot/dts/spacemit/k1-bananapi-f3.dts @@ -10,6 +10,42 @@ model = "Banana Pi BPI-F3"; compatible = "bananapi,bpi-f3", "spacemit,k1"; + memory@0 { + device_type = "memory"; + reg = <0x0 0x00000000 0x0 0x80000000>; + }; + + memory@100000000 { + device_type = "memory"; + reg = <0x1 0x00000000 0x0 0x80000000>; + }; + + reserved-memory { + #address-cells = <2>; + #size-cells = <2>; + ranges; + + linux,cma { + compatible = "shared-dma-pool"; + /* alloc memory from 0x40000000~0x80000000 */ + alloc-ranges = <0 0x40000000 0 0x40000000>; + /* size of cma buffer is 384MByte */ + size = <0 0x18000000>; + /* start address is 1Mbyte aligned */ + alignment = <0x0 0x100000>; + linux,cma-default; + /* besides hardware, dma for ex. buffer can be used by memory management */ + reusable; + }; + + /* reserved 384K for dpu, including mmu table(256K) and cmdlist(128K) */ + dpu_resv: dpu_reserved@2ff40000 { + compatible = "shared-dma-pool"; + reg = <0x0 0x2ff40000 0x0 0x000C0000>; + no-map; + }; + }; + chosen { stdout-path = "serial0"; };