summaryrefslogtreecommitdiff
path: root/libcpu
diff options
context:
space:
mode:
authorShell <[email protected]>2023-11-02 20:23:11 +0800
committerGitHub <[email protected]>2023-11-02 20:23:11 +0800
commitc2036e769ae5a16931e40f834cc0687342dc89ce (patch)
tree4cd769b538d956d7ca9114318cc5beb403c43df6 /libcpu
parent1b6f0e88a309251de7ccaa21bf5e078c8d9eb8ed (diff)
[smart] fixup of lwp recycling and mm varea (#8206)
Signed-off-by: shell <[email protected]> Signed-off-by: Shell <[email protected]> Co-authored-by: xqyjlj <[email protected]>
Diffstat (limited to 'libcpu')
-rw-r--r--libcpu/aarch64/SConscript2
-rw-r--r--libcpu/aarch64/common/trap.c2
2 files changed, 3 insertions, 1 deletions
diff --git a/libcpu/aarch64/SConscript b/libcpu/aarch64/SConscript
index 8cd26c411f..c4dd45682c 100644
--- a/libcpu/aarch64/SConscript
+++ b/libcpu/aarch64/SConscript
@@ -12,9 +12,9 @@ bsp_path = Dir('#').abspath
if not os.path.exists(bsp_path + "/link.lds"):
Env['LINKFLAGS'] = Env['LINKFLAGS'].replace('link.lds', cwd + "/link.lds")
- # fix the linker with crtx.o
Preprocessing("link.lds.S", ".lds", CPPPATH=[bsp_path])
+# fix the linker with crtx.o
Env['LINKFLAGS'] += ' -nostartfiles'
# add common code files
diff --git a/libcpu/aarch64/common/trap.c b/libcpu/aarch64/common/trap.c
index bac4ceaf21..325fe1e8ba 100644
--- a/libcpu/aarch64/common/trap.c
+++ b/libcpu/aarch64/common/trap.c
@@ -373,6 +373,8 @@ void rt_hw_trap_exception(struct rt_hw_exp_stack *regs)
#endif
#ifdef RT_USING_LWP
+ /* restore normal execution environment */
+ __asm__ volatile("msr daifclr, 0x3\ndmb ishst\nisb\n");
_check_fault(regs, 0, "user fault");
#endif