|
6 | 6 | #ifndef PLATFORM_CONFIG_H
|
7 | 7 | #define PLATFORM_CONFIG_H
|
8 | 8 |
|
| 9 | +#include <mm/generic_ram_layout.h> |
| 10 | + |
9 | 11 | /* Make stacks aligned to data cache line length */
|
10 | 12 | #define STACK_ALIGNMENT 64
|
11 | 13 |
|
|
44 | 46 | /*
|
45 | 47 | * HiKey and HiKey960 memory map
|
46 | 48 | *
|
| 49 | + * Refer to the default configuration from conf.mk for description below. |
| 50 | + * |
47 | 51 | * TZDRAM is secured (firewalled) by the DDR controller, see ARM-TF, but note
|
48 | 52 | * that security of this type of memory is weak for two reasons:
|
49 | 53 | * 1. It is prone to physical tampering since DRAM is external to the SoC
|
|
126 | 130 | #error Unknown HiKey PLATFORM_FLAVOR
|
127 | 131 | #endif /* PLATFORM_FLAVOR_hikey */
|
128 | 132 |
|
129 |
| - |
130 |
| -#ifdef CFG_WITH_PAGER |
131 |
| - |
132 |
| -#define TZSRAM_BASE 0x3F000000 |
133 |
| -#define TZSRAM_SIZE CFG_CORE_TZSRAM_EMUL_SIZE |
134 |
| - |
135 |
| -#define TZDRAM_BASE 0x3F200000 |
136 |
| -#define TZDRAM_SIZE (14 * 1024 * 1024) |
137 |
| - |
138 |
| -#else /* CFG_WITH_PAGER */ |
139 |
| - |
140 |
| -#define TZDRAM_BASE 0x3F000000 |
141 |
| -#define TZDRAM_SIZE (16 * 1024 * 1024) |
142 |
| - |
143 |
| -#endif /* CFG_WITH_PAGER */ |
144 |
| - |
145 |
| -#define TEE_SHMEM_START 0x3EE00000 |
146 |
| -#define TEE_SHMEM_SIZE (2 * 1024 * 1024) |
147 |
| - |
148 |
| -#define TEE_RAM_VA_SIZE (2 * 1024 * 1024) |
149 |
| - |
150 |
| -#define TEE_LOAD_ADDR 0x3F000000 |
151 |
| - |
152 |
| -#ifdef CFG_WITH_PAGER |
153 |
| - |
154 |
| -#define TEE_RAM_START TZSRAM_BASE |
155 |
| -#define TEE_RAM_PH_SIZE TZSRAM_SIZE |
156 |
| -#define TA_RAM_START ROUNDUP(TZDRAM_BASE, CORE_MMU_DEVICE_SIZE) |
157 |
| -#define TA_RAM_SIZE ROUNDDOWN(TZDRAM_SIZE, CORE_MMU_DEVICE_SIZE) |
158 |
| - |
159 |
| -#else /* CFG_WITH_PAGER */ |
160 |
| - |
161 |
| -#define TEE_RAM_PH_SIZE TEE_RAM_VA_SIZE |
162 |
| -#define TEE_RAM_START TZDRAM_BASE |
163 |
| -#define TA_RAM_START ROUNDUP((TZDRAM_BASE + TEE_RAM_VA_SIZE), \ |
164 |
| - CORE_MMU_DEVICE_SIZE) |
165 |
| - |
166 |
| -#define TA_RAM_SIZE ROUNDDOWN((TZDRAM_SIZE - TEE_RAM_VA_SIZE),\ |
167 |
| - CORE_MMU_DEVICE_SIZE) |
168 |
| - |
169 |
| -#endif /* CFG_WITH_PAGER */ |
170 |
| - |
171 | 133 | #endif /* PLATFORM_CONFIG_H */
|
0 commit comments