projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d82d500
)
MIPS: Clear XContext at boot time
author
Jiaxun Yang
<jiaxun.yang@flygoat.com>
Wed, 22 Apr 2020 14:45:34 +0000
(22:45 +0800)
committer
Thomas Bogendoerfer
<tsbogend@alpha.franken.de>
Fri, 24 Apr 2020 16:37:23 +0000
(18:37 +0200)
XContext might be dirty at boot time. We need to clear it
to ensure early stackframe is safe.
Signed-off-by: Jiaxun Yang <jiaxun.yang@flygoat.com>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
arch/mips/kernel/head.S
patch
|
blob
|
history
diff --git
a/arch/mips/kernel/head.S
b/arch/mips/kernel/head.S
index 351d40fe08598e7c9b473ddaf085c7e1742161bd..3b02ffe46304bf157ce14a9afd83b553da53522f 100644
(file)
--- a/
arch/mips/kernel/head.S
+++ b/
arch/mips/kernel/head.S
@@
-132,6
+132,9
@@
dtb_found:
#endif
MTC0 zero, CP0_CONTEXT # clear context register
+#ifdef CONFIG_64BIT
+ MTC0 zero, CP0_XCONTEXT
+#endif
PTR_LA $28, init_thread_union
/* Set the SP after an empty pt_regs. */
PTR_LI sp, _THREAD_SIZE - 32 - PT_SIZE