From 903dc66a883ca2d4e923956a8d507ac6f2b6e6d6 Mon Sep 17 00:00:00 2001 From: Lei Qian Date: Thu, 26 Jul 2018 11:41:15 +0800 Subject: [PATCH] dts:txl:optimize ion memory usage [2/2] PD#170336:dts:txl: optimize ion memory usage Change-Id: I8eb3cbf60ceeba959dbb74b51912947c9880ceb4 Signed-off-by: Lei Qian --- arch/arm64/boot/dts/amlogic/mesontxl.dtsi | 4 --- arch/arm64/boot/dts/amlogic/txl_t950_p341.dts | 9 ++++-- arch/arm64/boot/dts/amlogic/txl_t960_p346.dts | 9 ++++-- arch/arm64/boot/dts/amlogic/txl_t962_p320.dts | 7 +++- arch/arm64/boot/dts/amlogic/txl_t962_p321.dts | 32 ++++++++----------- 5 files changed, 34 insertions(+), 27 deletions(-) diff --git a/arch/arm64/boot/dts/amlogic/mesontxl.dtsi b/arch/arm64/boot/dts/amlogic/mesontxl.dtsi index 6de9a9d390f0..0e0060c80c60 100644 --- a/arch/arm64/boot/dts/amlogic/mesontxl.dtsi +++ b/arch/arm64/boot/dts/amlogic/mesontxl.dtsi @@ -645,10 +645,6 @@ }; };/* end of hiubus*/ - ion_dev { - compatible = "amlogic, ion_dev"; - memory-region = <&ion_cma_reserved>; - };/* end of ion_dev*/ }; /* end of soc*/ custom_maps: custom_maps { diff --git a/arch/arm64/boot/dts/amlogic/txl_t950_p341.dts b/arch/arm64/boot/dts/amlogic/txl_t950_p341.dts index e6a33ceb9a20..066a3d9f7ff1 100644 --- a/arch/arm64/boot/dts/amlogic/txl_t950_p341.dts +++ b/arch/arm64/boot/dts/amlogic/txl_t950_p341.dts @@ -39,6 +39,11 @@ i2c4 = &i2c_AO; }; + ion_dev { + compatible = "amlogic, ion_dev"; + memory-region = <&ion_reserved>; + }; + memory@00000000 { device_type = "memory"; linux,usable-memory = <0x0 0x100000 0x0 0x3ff00000>; @@ -73,10 +78,10 @@ alloc-ranges = <0x0 0x3f800000 0x0 0x800000>; }; - ion_cma_reserved:linux,ion-dev { + ion_reserved:linux,ion-dev { compatible = "shared-dma-pool"; reusable; - size = <0x0 0x8000000>; + size = <0x0 0x2000000>; alignment = <0x0 0x400000>; }; diff --git a/arch/arm64/boot/dts/amlogic/txl_t960_p346.dts b/arch/arm64/boot/dts/amlogic/txl_t960_p346.dts index b3520c23b1d8..f1a4dff5d979 100644 --- a/arch/arm64/boot/dts/amlogic/txl_t960_p346.dts +++ b/arch/arm64/boot/dts/amlogic/txl_t960_p346.dts @@ -39,6 +39,11 @@ i2c4 = &i2c_AO; }; + ion_dev { + compatible = "amlogic, ion_dev"; + memory-region = <&ion_reserved>; + }; + memory@00000000 { device_type = "memory"; linux,usable-memory = <0x0 0x100000 0x0 0x3ff00000>; @@ -73,10 +78,10 @@ alloc-ranges = <0x0 0x3f800000 0x0 0x800000>; }; - ion_cma_reserved:linux,ion-dev { + ion_reserved:linux,ion-dev { compatible = "shared-dma-pool"; reusable; - size = <0x0 0x8000000>; + size = <0x0 0x2000000>; alignment = <0x0 0x400000>; }; diff --git a/arch/arm64/boot/dts/amlogic/txl_t962_p320.dts b/arch/arm64/boot/dts/amlogic/txl_t962_p320.dts index 3024447644d3..4543b3d170dc 100644 --- a/arch/arm64/boot/dts/amlogic/txl_t962_p320.dts +++ b/arch/arm64/boot/dts/amlogic/txl_t962_p320.dts @@ -39,6 +39,11 @@ i2c4 = &i2c_AO; }; + ion_dev { + compatible = "amlogic, ion_dev"; + memory-region = <&ion_reserved>; + }; + memory@00000000 { device_type = "memory"; linux,usable-memory = <0x0 0x100000 0x0 0x7ff00000>; @@ -73,7 +78,7 @@ alloc-ranges = <0x0 0x3f800000 0x0 0x800000>; }; - ion_cma_reserved:linux,ion-dev { + ion_reserved:linux,ion-dev { compatible = "shared-dma-pool"; reusable; size = <0x0 0x8000000>; diff --git a/arch/arm64/boot/dts/amlogic/txl_t962_p321.dts b/arch/arm64/boot/dts/amlogic/txl_t962_p321.dts index a3bcedb8a7b4..cc6b77a8a073 100644 --- a/arch/arm64/boot/dts/amlogic/txl_t962_p321.dts +++ b/arch/arm64/boot/dts/amlogic/txl_t962_p321.dts @@ -39,6 +39,11 @@ i2c4 = &i2c_AO; }; + ion_dev { + compatible = "amlogic, ion_dev"; + memory-region = <&ion_reserved>; + }; + memory@00000000 { device_type = "memory"; linux,usable-memory = <0x0 0x100000 0x0 0x3ff00000>; @@ -58,12 +63,12 @@ alloc-ranges = <0x0 0x05000000 0x0 0x400000>; }; - secos_reserved:linux,secos { - compatible = "amlogic, aml_secos_memory"; - status = "disable"; - reg = <0x0 0x05300000 0x0 0x2000000>; - no-map; - }; + //secos_reserved:linux,secos { + // status = "disabled"; + // compatible = "amlogic, aml_secos_memory"; + // reg = <0x0 0x05300000 0x0 0x2000000>; + // no-map; + //}; logo_reserved:linux,meson-fb { compatible = "shared-dma-pool"; @@ -73,10 +78,10 @@ alloc-ranges = <0x0 0x3f800000 0x0 0x800000>; }; - ion_cma_reserved:linux,ion-dev { + ion_reserved:linux,ion-dev { compatible = "shared-dma-pool"; reusable; - size = <0x0 0x8000000>; + size = <0x0 0x2000000>; alignment = <0x0 0x400000>; }; @@ -145,15 +150,6 @@ alignment = <0x0 0x400000>; }; - /* vdin0 CMA pool */ - vdin0_cma_reserved:linux,vdin0_cma { - compatible = "shared-dma-pool"; - reusable; - /* 1920x1080x2x4 =16+4 M */ - size = <0x0 0x04000000>; - alignment = <0x0 0x400000>; - }; - /* vdin1 CMA pool */ vdin1_cma_reserved:linux,vdin1_cma { compatible = "shared-dma-pool"; @@ -319,9 +315,9 @@ vdin@1 { compatible = "amlogic, vdin"; - status = "okay"; memory-region = <&vdin1_cma_reserved>; dev_name = "vdin1"; + status = "okay"; reserve-iomap = "true"; flag_cma = <0>;/*1:share with codec_mm;0:cma alone*/ interrupts = <0 85 1>; -- 2.20.1