mirror of
https://github.com/feyisay07/meta-bsp-imx8mm.git
synced 2026-09-24 06:10:13 +01:00
56 lines
2.0 KiB
Diff
56 lines
2.0 KiB
Diff
From 928e166d8356dd43cdd68fdc080064450801a495 Mon Sep 17 00:00:00 2001
|
|
From: Kirill Kapranov <kirill.kapranov@compulab.co.il>
|
|
Date: Mon, 19 Apr 2021 17:30:22 +0300
|
|
Subject: [PATCH 2/2] optee: Apply a new CFG_TZDRAM_START calcutation logics
|
|
|
|
1) Allocate at the uppere edge of the 1G
|
|
2) Set the maximum available DRAM_SIZE=4G
|
|
|
|
Signed-off-by: Valentin Raevsky <valentin@compulab.co.il>
|
|
Signed-off-by: Kirill Kapranov <kirill.kapranov@compulab.co.il>
|
|
---
|
|
core/arch/arm/plat-imx/conf.mk | 8 +++++++-
|
|
core/arch/arm/plat-imx/platform_config.h | 6 +++---
|
|
2 files changed, 10 insertions(+), 4 deletions(-)
|
|
|
|
diff --git a/core/arch/arm/plat-imx/conf.mk b/core/arch/arm/plat-imx/conf.mk
|
|
index aa801f11..75aa862c 100644
|
|
--- a/core/arch/arm/plat-imx/conf.mk
|
|
+++ b/core/arch/arm/plat-imx/conf.mk
|
|
@@ -338,8 +338,14 @@ CFG_UART_BASE ?= UART1_BASE
|
|
endif
|
|
|
|
ifneq (,$(filter $(PLATFORM_FLAVOR),mx8mmevk))
|
|
-CFG_DDR_SIZE ?= 0x80000000
|
|
CFG_UART_BASE = UART3_BASE
|
|
+CFG_DDR_SIZE = 0x100000000
|
|
+CFG_DDR_0SEC_SIZE = 0x40000000
|
|
+CFG_TZDRAM_START = ($(CFG_DRAM_BASE) - 0x02000000 + $(CFG_DDR_0SEC_SIZE))
|
|
+
|
|
+CFG_DRAM0_NSEC_SIZE = ($(CFG_DDR_0SEC_SIZE) - 0x02000000 )
|
|
+CFG_DRAM1_NSEC_BASE = 0x80000000
|
|
+CFG_DRAM1_NSEC_SIZE = ($(CFG_DDR_SIZE) - $(CFG_DDR_0SEC_SIZE))
|
|
endif
|
|
|
|
ifneq (,$(filter $(PLATFORM_FLAVOR),mx8mnevk))
|
|
diff --git a/core/arch/arm/plat-imx/platform_config.h b/core/arch/arm/plat-imx/platform_config.h
|
|
index 72bebcb2..8db15fa6 100644
|
|
--- a/core/arch/arm/plat-imx/platform_config.h
|
|
+++ b/core/arch/arm/plat-imx/platform_config.h
|
|
@@ -75,9 +75,9 @@
|
|
#if defined(CFG_MX8MQ) || defined(CFG_MX8MM) || defined(CFG_MX8MN) || \
|
|
defined(CFG_MX8MP)
|
|
#define DRAM0_NSEC_BASE CFG_DRAM_BASE
|
|
-#define DRAM0_NSEC_SIZE (CFG_TZDRAM_START - CFG_DRAM_BASE)
|
|
-#define DRAM1_NSEC_BASE (CFG_TZDRAM_START + 0x2000000)
|
|
-#define DRAM1_NSEC_SIZE (CFG_DDR_SIZE - DRAM1_NSEC_BASE + CFG_DRAM_BASE)
|
|
+#define DRAM0_NSEC_SIZE CFG_DRAM0_NSEC_SIZE
|
|
+#define DRAM1_NSEC_BASE CFG_DRAM1_NSEC_BASE
|
|
+#define DRAM1_NSEC_SIZE CFG_DRAM1_NSEC_SIZE
|
|
#endif
|
|
|
|
#if defined(CFG_IMX_DEK_HAB) && !defined(DRAM0_NSEC_SIZE)
|
|
--
|
|
2.17.1
|
|
|