summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilipp Tomsich <philipp.tomsich@theobroma-systems.com>2017-08-30 15:28:30 +0200
committerPhilipp Tomsich <philipp.tomsich@theobroma-systems.com>2017-09-01 18:51:13 +0200
commit1a148b3aebfdb3e0659d582e5ebbc172b24e63a8 (patch)
treeac71c82ea115d97fe6d6ca7007aa56f87f6c9243
parent07b6f3535f5abe3a7c00ca0838d1b8d674975228 (diff)
[wip] FDT support
-rw-r--r--plat/rockchip/common/bl31_plat_setup.c34
1 files changed, 11 insertions, 23 deletions
diff --git a/plat/rockchip/common/bl31_plat_setup.c b/plat/rockchip/common/bl31_plat_setup.c
index 65aea75d..0a41f216 100644
--- a/plat/rockchip/common/bl31_plat_setup.c
+++ b/plat/rockchip/common/bl31_plat_setup.c
@@ -36,7 +36,7 @@ unsigned long __RO_END__;
#define BL31_END (uintptr_t)(&__BL31_END__)
-//static entry_point_info_t bl32_ep_info;
+static entry_point_info_t bl32_ep_info;
static entry_point_info_t bl33_ep_info;
/*******************************************************************************
@@ -47,7 +47,7 @@ static entry_point_info_t bl33_ep_info;
******************************************************************************/
entry_point_info_t *bl31_plat_get_next_image_ep_info(uint32_t type)
{
-#if 1
+#if 0
assert(sec_state_is_valid(type));
assert(type == NON_SECURE);
@@ -65,11 +65,6 @@ entry_point_info_t *bl31_plat_get_next_image_ep_info(uint32_t type)
#endif
}
-#pragma weak params_early_setup
-void params_early_setup(void *plat_param_from_bl2)
-{
-}
-
/*******************************************************************************
* Perform any BL3-1 early platform setup. Here is an opportunity to copy
* parameters passed by the calling EL (S-EL1 in BL2 & S-EL3 in BL1) before they
@@ -87,34 +82,27 @@ void bl31_early_platform_setup(bl31_params_t *from_bl2,
console_init(PLAT_RK_UART_BASE, PLAT_RK_UART_CLOCK,
PLAT_RK_UART_BAUDRATE);
- VERBOSE("bl31_setup\n");
+ INFO("%s: from_bl2 %p plat_params_from_bl2 %p",
+ __func__, (void*)from_bl2, plat_params_from_bl2);
/* Passing a NULL context is a critical programming error */
assert(from_bl2);
-#if 0
+ INFO("%s: from_bl2->h.type %x\n",
+ __func__, from_bl2->h.type);
assert(from_bl2->h.type == PARAM_BL31);
+ INFO("%s: from_bl2->h.version %x\n",
+ __func__, from_bl2->h.version);
assert(from_bl2->h.version >= VERSION_1);
bl32_ep_info = *from_bl2->bl32_ep_info;
bl33_ep_info = *from_bl2->bl33_ep_info;
-#endif
- /*
- * Tell BL31 where the non-trusted software image
- * is located and the entry state information
- */
- bl33_ep_info.pc = 0x00200000;
- bl33_ep_info.spsr = SPSR_64(MODE_EL2, MODE_SP_ELX,
- DISABLE_ALL_EXCEPTIONS);
- SET_SECURITY_STATE(bl33_ep_info.h.attr, NON_SECURE);
+ /* there may have some board specific data */
+ params_early_setup(plat_params_from_bl2);
+ INFO("bl33_ep_info.pc: %p\n", (void*)(bl33_ep_info.pc));
plat_rockchip_pmusram_prepare();
-
-#if 0
- /* there may have some board sepcific message need to initialize */
- params_early_setup(plat_params_from_bl2);
-#endif
}
/*******************************************************************************