Skip to content

Commit

Permalink
start & pthread
Browse files Browse the repository at this point in the history
  • Loading branch information
pussuw committed Sep 20, 2024
1 parent d30e943 commit 3b57758
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions arch/arm64/src/common/arm64_vectors.S
Original file line number Diff line number Diff line change
Expand Up @@ -189,18 +189,20 @@ restore_new:
*
****************************************************************************/

#ifndef CONFIG_BUILD_FLAT
GTEXT(arm64_jump_to_user)
SECTION_FUNC(text, arm64_jump_to_user)
msr daifset, #IRQ_DAIF_MASK
mov sp, x3
str x0, [sp, #8 * REG_ELR]
str x1, [sp, #8 * REG_X0]
str x2, [sp, #8 * REG_X1]
mrs x19, spsr_el1
and x19, x19, #~SPSR_MODE_MASK
#orr x19, x19, #SPSR_MODE_EL0T # EL0T=0x00, out of range for orr
str x19, [sp, #8 * REG_SPSR]
mrs x0, spsr_el1
and x0, x0, #~SPSR_MODE_MASK
#orr x0, x0, #SPSR_MODE_EL0T # EL0T=0x00, out of range for orr
str x0, [sp, #8 * REG_SPSR]
b arm64_exit_exception
#endif

/****************************************************************************
* Function: arm64_sync_exc
Expand Down

0 comments on commit 3b57758

Please sign in to comment.