blob: 42f754e25af2aa2008ebd2020994e4869983be56 [file] [log] [blame]
Dan Handley9df48042015-03-19 18:58:55 +00001/*
Sandrine Bailleux4a1267a2016-05-18 16:11:47 +01002 * Copyright (c) 2015-2016, ARM Limited and Contributors. All rights reserved.
Dan Handley9df48042015-03-19 18:58:55 +00003 *
dp-armfa3cf0b2017-05-03 09:38:09 +01004 * SPDX-License-Identifier: BSD-3-Clause
Dan Handley9df48042015-03-19 18:58:55 +00005 */
6#include <arm_def.h>
7#include <plat_arm.h>
8
9/*
Sandrine Bailleux4a1267a2016-05-18 16:11:47 +010010 * Table of memory regions for different BL stages to map using the MMU.
11 * This doesn't include Trusted SRAM as arm_setup_page_tables() already
12 * takes care of mapping it.
Dan Handley9df48042015-03-19 18:58:55 +000013 */
Masahiro Yamada441bfdd2016-12-25 23:36:24 +090014#ifdef IMAGE_BL1
Dan Handley9df48042015-03-19 18:58:55 +000015const mmap_region_t plat_arm_mmap[] = {
16 ARM_MAP_SHARED_RAM,
Juan Castillob6132f12015-10-06 14:01:35 +010017 V2M_MAP_FLASH0_RO,
Dan Handley9df48042015-03-19 18:58:55 +000018 V2M_MAP_IOFPGA,
19 CSS_MAP_DEVICE,
20 SOC_CSS_MAP_DEVICE,
Yatharth Kochar736a3bf2015-10-11 14:14:55 +010021#if TRUSTED_BOARD_BOOT
22 ARM_MAP_NS_DRAM1,
23#endif
Dan Handley9df48042015-03-19 18:58:55 +000024 {0}
25};
26#endif
Masahiro Yamada441bfdd2016-12-25 23:36:24 +090027#ifdef IMAGE_BL2
Dan Handley9df48042015-03-19 18:58:55 +000028const mmap_region_t plat_arm_mmap[] = {
29 ARM_MAP_SHARED_RAM,
Juan Castillob6132f12015-10-06 14:01:35 +010030 V2M_MAP_FLASH0_RO,
Dan Handley9df48042015-03-19 18:58:55 +000031 V2M_MAP_IOFPGA,
32 CSS_MAP_DEVICE,
33 SOC_CSS_MAP_DEVICE,
34 ARM_MAP_NS_DRAM1,
35 ARM_MAP_TSP_SEC_MEM,
36 {0}
37};
38#endif
Masahiro Yamada441bfdd2016-12-25 23:36:24 +090039#ifdef IMAGE_BL2U
Yatharth Kochar3a11eda2015-10-14 15:28:11 +010040const mmap_region_t plat_arm_mmap[] = {
41 ARM_MAP_SHARED_RAM,
42 CSS_MAP_DEVICE,
43 SOC_CSS_MAP_DEVICE,
44 {0}
45};
46#endif
Masahiro Yamada441bfdd2016-12-25 23:36:24 +090047#ifdef IMAGE_BL31
Dan Handley9df48042015-03-19 18:58:55 +000048const mmap_region_t plat_arm_mmap[] = {
49 ARM_MAP_SHARED_RAM,
50 V2M_MAP_IOFPGA,
51 CSS_MAP_DEVICE,
Soby Mathewcbafd7a2016-11-14 12:44:32 +000052#if CSS_USE_SCMI_DRIVER
53 /*
54 * The SCMI payload area is currently in the Non Secure SRAM. This is
55 * a potential security risk but this will be resolved once SCP
56 * completely replaces SCPI with SCMI as the only communication
57 * protocol.
58 */
59 CSS_MAP_NSRAM,
60#endif
Dan Handley9df48042015-03-19 18:58:55 +000061 SOC_CSS_MAP_DEVICE,
62 {0}
63};
64#endif
Masahiro Yamada441bfdd2016-12-25 23:36:24 +090065#ifdef IMAGE_BL32
Dan Handley9df48042015-03-19 18:58:55 +000066const mmap_region_t plat_arm_mmap[] = {
Yatharth Kochar2694cba2016-11-14 12:00:41 +000067#ifdef AARCH32
68 ARM_MAP_SHARED_RAM,
69#endif
Dan Handley9df48042015-03-19 18:58:55 +000070 V2M_MAP_IOFPGA,
71 CSS_MAP_DEVICE,
72 SOC_CSS_MAP_DEVICE,
73 {0}
74};
75#endif
76
77ARM_CASSERT_MMAP
78