[PATCH v2 8/9] sh64: entry: Remove unneeded need_resched() loop

From: Valentin Schneider
Date: Mon Sep 23 2019 - 10:37:01 EST


Since the enabling and disabling of IRQs within preempt_schedule_irq()
is contained in a need_resched() loop, we don't need the outer arch
code loop.

Signed-off-by: Valentin Schneider <valentin.schneider@xxxxxxx>
Cc: Yoshinori Sato <ysato@xxxxxxxxxxxxxxxxxxxx>
Cc: Rich Felker <dalias@xxxxxxxx>
Cc: linux-sh@xxxxxxxxxxxxxxx
---
arch/sh/kernel/cpu/sh5/entry.S | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/arch/sh/kernel/cpu/sh5/entry.S b/arch/sh/kernel/cpu/sh5/entry.S
index de68ffdfffbf..40e6d9a7a6a2 100644
--- a/arch/sh/kernel/cpu/sh5/entry.S
+++ b/arch/sh/kernel/cpu/sh5/entry.S
@@ -897,7 +897,6 @@ resume_kernel:
ld.l r6, TI_PRE_COUNT, r7
beq/u r7, ZERO, tr0

-need_resched:
ld.l r6, TI_FLAGS, r7
movi (1 << TIF_NEED_RESCHED), r8
and r8, r7, r8
@@ -911,9 +910,7 @@ need_resched:
ori r7, 1, r7
ptabs r7, tr1
blink tr1, LINK
-
- pta need_resched, tr1
- blink tr1, ZERO
+ blink tr0, ZERO
#endif

.global ret_from_syscall
--
2.22.0