summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVineet Gupta <vgupta@synopsys.com>2013-05-14 18:30:50 +0530
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-05-13 13:59:42 +0200
commit1a43738d057559e87e0036e25c33715d6eff11ed (patch)
treeca64c950930c1b067603009ead5427e88549bb3e
parent6eed5b7500dc3754dc4d24f328f02bed118adb89 (diff)
downloadlwn-1a43738d057559e87e0036e25c33715d6eff11ed.tar.gz
lwn-1a43738d057559e87e0036e25c33715d6eff11ed.zip
ARC: Entry Handler tweaks: Simplify branch for in-kernel preemption
commit 147aece29b15051173eb1e767018135361cdba89 upstream. Signed-off-by: Vineet Gupta <vgupta@synopsys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--arch/arc/kernel/entry.S8
1 files changed, 2 insertions, 6 deletions
diff --git a/arch/arc/kernel/entry.S b/arch/arc/kernel/entry.S
index 6dbe359c760d..922150e153ea 100644
--- a/arch/arc/kernel/entry.S
+++ b/arch/arc/kernel/entry.S
@@ -589,11 +589,7 @@ ARC_ENTRY ret_from_exception
; Pre-{IRQ,Trap,Exception} K/U mode from pt_regs->status32
ld r8, [sp, PT_status32] ; returning to User/Kernel Mode
-#ifdef CONFIG_PREEMPT
bbit0 r8, STATUS_U_BIT, resume_kernel_mode
-#else
- bbit0 r8, STATUS_U_BIT, restore_regs
-#endif
; Before returning to User mode check-for-and-complete any pending work
; such as rescheduling/signal-delivery etc.
@@ -653,10 +649,10 @@ resume_user_mode_begin:
b resume_user_mode_begin ; unconditionally back to U mode ret chks
; for single exit point from this block
-#ifdef CONFIG_PREEMPT
-
resume_kernel_mode:
+#ifdef CONFIG_PREEMPT
+
; Can't preempt if preemption disabled
GET_CURR_THR_INFO_FROM_SP r10
ld r8, [r10, THREAD_INFO_PREEMPT_COUNT]