Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OwnTech
Bootloader
Commits
ee1b7b9d
Commit
ee1b7b9d
authored
Apr 07, 2022
by
Jim Tan
Committed by
David Brown
Apr 18, 2022
Browse files
zephyr: fix booting address incorrect in ram-load mode
Signed-off-by:
Jim Tan
<
KuoChun.Tan@ite.com.tw
>
parent
93d02179
Changes
1
Hide whitespace changes
Inline
Side-by-side
boot/zephyr/main.c
View file @
ee1b7b9d
...
...
@@ -297,8 +297,12 @@ static void do_boot(struct boot_rsp *rsp)
*/
static
void
do_boot
(
struct
boot_rsp
*
rsp
)
{
uintptr_t
flash_base
;
void
*
start
;
#if defined(MCUBOOT_RAM_LOAD)
start
=
(
void
*
)(
rsp
->
br_hdr
->
ih_load_addr
+
rsp
->
br_hdr
->
ih_hdr_size
);
#else
uintptr_t
flash_base
;
int
rc
;
rc
=
flash_device_base
(
rsp
->
br_flash_dev_id
,
&
flash_base
);
...
...
@@ -306,6 +310,7 @@ static void do_boot(struct boot_rsp *rsp)
start
=
(
void
*
)(
flash_base
+
rsp
->
br_image_off
+
rsp
->
br_hdr
->
ih_hdr_size
);
#endif
/* Lock interrupts and dive into the entry point */
irq_lock
();
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment