diff mbox series

[v2,07/15] ARM: dts: increase default cma size to 40MB

Message ID 20180423134750.30403-8-rui.silva@linaro.org
State New
Headers show
Series media: staging/imx7: add i.MX7 media driver | expand

Commit Message

Rui Miguel Silva April 23, 2018, 1:47 p.m. UTC
To support camera in i.MX7 the cma heap is used to allocate frame buffers. The
default size of CMA is 16MB which is not enough for higher resolutions (ex:
1600x1200).

So, increase the default CMA size to 40MB.

Signed-off-by: Rui Miguel Silva <rui.silva@linaro.org>

---
 arch/arm/boot/dts/imx7s.dtsi | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

-- 
2.17.0

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Comments

Shawn Guo May 3, 2018, 2:40 a.m. UTC | #1
On Mon, Apr 23, 2018 at 02:47:42PM +0100, Rui Miguel Silva wrote:
> To support camera in i.MX7 the cma heap is used to allocate frame buffers. The

> default size of CMA is 16MB which is not enough for higher resolutions (ex:

> 1600x1200).

> 

> So, increase the default CMA size to 40MB.

> 

> Signed-off-by: Rui Miguel Silva <rui.silva@linaro.org>


CMA size can be adjusted by kernel cmdline.  I'm not sure it's necessary
to make it fixed in DT.

Shawn

> ---

>  arch/arm/boot/dts/imx7s.dtsi | 14 ++++++++++++++

>  1 file changed, 14 insertions(+)

> 

> diff --git a/arch/arm/boot/dts/imx7s.dtsi b/arch/arm/boot/dts/imx7s.dtsi

> index 4d42335c0dee..142ea709d296 100644

> --- a/arch/arm/boot/dts/imx7s.dtsi

> +++ b/arch/arm/boot/dts/imx7s.dtsi

> @@ -182,6 +182,20 @@

>  			     <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>;

>  	};

>  

> +	reserved-memory {

> +		#address-cells = <1>;

> +		#size-cells = <1>;

> +		ranges;

> +

> +		/* global autoconfigured region for contiguous allocations */

> +		linux,cma {

> +			compatible = "shared-dma-pool";

> +			reusable;

> +			size = <0x2800000>;

> +			linux,cma-default;

> +		};

> +	};

> +

>  	soc {

>  		#address-cells = <1>;

>  		#size-cells = <1>;

> -- 

> 2.17.0

> 

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox series

Patch

diff --git a/arch/arm/boot/dts/imx7s.dtsi b/arch/arm/boot/dts/imx7s.dtsi
index 4d42335c0dee..142ea709d296 100644
--- a/arch/arm/boot/dts/imx7s.dtsi
+++ b/arch/arm/boot/dts/imx7s.dtsi
@@ -182,6 +182,20 @@ 
 			     <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>;
 	};
 
+	reserved-memory {
+		#address-cells = <1>;
+		#size-cells = <1>;
+		ranges;
+
+		/* global autoconfigured region for contiguous allocations */
+		linux,cma {
+			compatible = "shared-dma-pool";
+			reusable;
+			size = <0x2800000>;
+			linux,cma-default;
+		};
+	};
+
 	soc {
 		#address-cells = <1>;
 		#size-cells = <1>;