diff options
author | Masahisa Kojima <masahisa.kojima@linaro.org> | 2020-11-12 11:48:45 +0900 |
---|---|---|
committer | jimqui01 <54316584+jimqui01@users.noreply.github.com> | 2020-11-16 10:33:28 +0000 |
commit | f6e767b4d8fa981b22a86990ebaa47f63fbd09d3 (patch) | |
tree | 28a45f5e89610295f9b4576bd5da08ae656a2bc5 /product | |
parent | f73422868da3eeaa877286545850520e9b431055 (diff) |
synquacer: scp_romfw: set vector table offset register
With the use of CMSIS from Commit afd75a9 ("Refactor the architecture
layer"), ROM firmware is expected to set the vector table offset
register to the RAM firmware's vector table before jumping to the RAM
firmware. This patch sets the VTOR register to the RAM firmware's vector
table for synquacer platform.
Change-Id: I720fe8249b0d40a56028af0c26d00ef1aa2156d2
Signed-off-by: Masahisa Kojima <masahisa.kojima@linaro.org>
Diffstat (limited to 'product')
-rw-r--r-- | product/synquacer/module/synquacer_rom/src/mod_synquacer_rom.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/product/synquacer/module/synquacer_rom/src/mod_synquacer_rom.c b/product/synquacer/module/synquacer_rom/src/mod_synquacer_rom.c index a980f0d5..89ab6207 100644 --- a/product/synquacer/module/synquacer_rom/src/mod_synquacer_rom.c +++ b/product/synquacer/module/synquacer_rom/src/mod_synquacer_rom.c @@ -16,6 +16,8 @@ #include <fwk_status.h> #include <fwk_thread.h> +#include <fmw_cmsis.h> + #include <stdint.h> #include <string.h> @@ -43,6 +45,9 @@ static void jump_to_ramfw(void) ramfw_reset_handler = (void (*)(void))(*reset_base); + /* Set the vector table offset register to ramfw vector table */ + SCB->VTOR = rom_config->ramfw_base; + /* * Execute the RAM firmware's reset handler to pass control from ROM * firmware to the RAM firmware. |