[RFC,v1,16/16] powerpc/32: don't do syscall stuff in transfer_to_handler on non BOOKE

Message ID e7ba540e3ca711be32ca84870fb2314c2f0b025d.1549630193.git.christophe.leroy@c-s.fr
State New
Headers show
Series
  • powerpc/32: Implement fast syscall entry
Related show

Checks

Context Check Description
snowpatch_ozlabs/checkpatch success total: 0 errors, 0 warnings, 0 checks, 42 lines checked
snowpatch_ozlabs/build-pmac32 success build succeeded & removed 0 sparse warning(s)
snowpatch_ozlabs/build-ppc64e success build succeeded & removed 0 sparse warning(s)
snowpatch_ozlabs/build-ppc64be success build succeeded & removed 0 sparse warning(s)
snowpatch_ozlabs/build-ppc64le success build succeeded & removed 0 sparse warning(s)
snowpatch_ozlabs/apply_patch success next/apply_patch Successfully applied

Commit Message

Christophe Leroy Feb. 8, 2019, 12:52 p.m.
As syscalls are now handled via a fast entry path, syscall related
actions can be removed from the generic transfer_to_handler path.

Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
---
 arch/powerpc/kernel/entry_32.S | 8 ++++++++
 1 file changed, 8 insertions(+)

Patch

diff --git a/arch/powerpc/kernel/entry_32.S b/arch/powerpc/kernel/entry_32.S
index 0927d5ff1e79..85f1fc88c237 100644
--- a/arch/powerpc/kernel/entry_32.S
+++ b/arch/powerpc/kernel/entry_32.S
@@ -211,7 +211,9 @@  transfer_to_handler_cont:
 	 */
 	tophys(r12, r1)
 	lwz	r12,_MSR(r12)
+#ifdef CONFIG_BOOKE	/* to be removed once BOOKE uses fast syscall entry */
 	xor	r12,r10,r12
+#endif
 	andi.	r12,r12,MSR_EE
 	bne	1f
 
@@ -252,8 +254,10 @@  reenable_mmu:
 	 * the rest is restored from the exception frame.
 	 */
 
+#ifdef CONFIG_BOOKE	/* to be removed once BOOKE uses fast syscall entry */
 	/* Are we enabling or disabling interrupts ? */
 	andi.	r0,r10,MSR_EE
+#endif
 
 	stwu	r1,-32(r1)
 	stw	r9,8(r1)
@@ -262,7 +266,9 @@  reenable_mmu:
 	stw	r4,20(r1)
 	stw	r5,24(r1)
 
+#ifdef CONFIG_BOOKE	/* to be removed once BOOKE uses fast syscall entry */
 	bne-	0f
+#endif
 
 	/* If we are disabling interrupts (normal case), simply log it with
 	 * lockdep
@@ -282,6 +288,7 @@  reenable_mmu:
 	mtlr	r9
 	bctr				/* jump to handler */
 
+#ifdef CONFIG_BOOKE	/* to be removed once BOOKE uses fast syscall entry */
 	/* If we are enabling interrupt, this is a syscall. They shouldn't
 	 * happen while interrupts are disabled, so let's do a warning here.
 	 */
@@ -294,6 +301,7 @@  reenable_mmu:
 	ori	r10,r10,MSR_EE
 	mtmsr	r10
 	b	2b
+#endif
 #endif /* CONFIG_TRACE_IRQFLAGS */
 
 #if defined (CONFIG_PPC_BOOK3S_32) || defined(CONFIG_E500)