aboutsummaryrefslogtreecommitdiff
path: root/plat/rockchip/common/include/plat_private.h
diff options
context:
space:
mode:
authorCaesar Wang <wxt@rock-chips.com>2016-10-11 09:36:00 +0800
committerCaesar Wang <wxt@rock-chips.com>2016-10-25 03:28:53 +0800
commitec6935692a1ecd69473ca0f1990d8ed280dfca61 (patch)
tree88b19daa7951a23ed6c47415b8488270b44ca621 /plat/rockchip/common/include/plat_private.h
parenta5a423100822c4b8c9982024c333460f0d019d82 (diff)
downloadtrusted-firmware-a-ec6935692a1ecd69473ca0f1990d8ed280dfca61.tar.gz
rockchip: optimize the link mechanism for SRAM code
Add the common extra.ld.S and customized rk3399.ld.S to extend to more features for different platforms. For example, we can add SRAM section and specific address to load there if we need it, and the common bl31.ld.S not need to be modified. Therefore, we can remove the unused codes which copying explicitly from the function pmusram_prepare(). It looks like more clear. Change-Id: Ibffa2da5e8e3d1d2fca80085ebb296ceb967fce8 Signed-off-by: Xing Zheng <zhengxing@rock-chips.com> Signed-off-by: Caesar Wang <wxt@rock-chips.com>
Diffstat (limited to 'plat/rockchip/common/include/plat_private.h')
-rw-r--r--plat/rockchip/common/include/plat_private.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/plat/rockchip/common/include/plat_private.h b/plat/rockchip/common/include/plat_private.h
index ad012666ef..a093e79225 100644
--- a/plat/rockchip/common/include/plat_private.h
+++ b/plat/rockchip/common/include/plat_private.h
@@ -37,6 +37,14 @@
#include <xlat_tables.h>
#include <psci.h>
+#define __sramdata __attribute__((section(".sram.data")))
+#define __sramconst __attribute__((section(".sram.rodata")))
+#define __sramfunc __attribute__((section(".sram.text"))) \
+ __attribute__((noinline))
+
+extern uint32_t __bl31_sram_text_start, __bl31_sram_text_end;
+extern uint32_t __bl31_sram_data_start, __bl31_sram_data_end;
+
/******************************************************************************
* For rockchip socs pm ops
******************************************************************************/
@@ -135,6 +143,10 @@ extern uint64_t cpuson_entry_point[PLATFORM_CORE_COUNT];
extern uint32_t cpuson_flags[PLATFORM_CORE_COUNT];
extern const mmap_region_t plat_rk_mmap[];
+
+void rockchip_plat_sram_mmu_el3(void);
+void plat_rockchip_mem_prepare(void);
+
#endif /* __ASSEMBLY__ */
/******************************************************************************