arch: arm: common Armv8-M support
This PR includes the required changes in order to support conditional compilation for Armv8-M architecture. Two variants of the Armv8-M architecture are defined: - the Armv8-M Baseline (backwards compatible with ARMv6-M), - the Armv8-M Mainline (backwards compatible with ARMv7-M). Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
This commit is contained in:
parent
edbce1c14c
commit
a0a03d7597
21 changed files with 197 additions and 115 deletions
|
@ -90,12 +90,12 @@ SECTION_SUBSEC_FUNC(TEXT, _HandlerModeExit, _ExcExit)
|
|||
#ifdef CONFIG_TIMESLICING
|
||||
push {lr}
|
||||
bl _update_time_slice_before_swap
|
||||
#if defined(CONFIG_ARMV6_M)
|
||||
#if defined(CONFIG_ARMV6_M_ARMV8_M_BASELINE)
|
||||
pop {r0}
|
||||
mov lr, r0
|
||||
#else
|
||||
pop {lr}
|
||||
#endif /* CONFIG_ARMV6_M */
|
||||
#endif /* CONFIG_ARMV6_M_ARMV8_M_BASELINE */
|
||||
#endif /* CONFIG_TIMESLICING */
|
||||
|
||||
/* context switch required, pend the PendSV exception */
|
||||
|
@ -111,12 +111,12 @@ _EXIT_EXC:
|
|||
#ifdef CONFIG_STACK_SENTINEL
|
||||
push {lr}
|
||||
bl _check_stack_sentinel
|
||||
#if defined(CONFIG_ARMV6_M)
|
||||
#if defined(CONFIG_ARMV6_M_ARMV8_M_BASELINE)
|
||||
pop {r0}
|
||||
mov lr, r0
|
||||
#else
|
||||
pop {lr}
|
||||
#endif /* CONFIG_ARMV6_M */
|
||||
#endif /* CONFIG_ARMV6_M_ARMV8_M_BASELINE */
|
||||
#endif /* CONFIG_STACK_SENTINEL */
|
||||
|
||||
bx lr
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue