aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arc
diff options
context:
space:
mode:
authorVineet Gupta <vgupta@synopsys.com>2013-05-14 09:00:50 -0400
committerVineet Gupta <vgupta@synopsys.com>2013-06-22 09:53:24 -0400
commit147aece29b15051173eb1e767018135361cdba89 (patch)
tree7a2b856e5b2214cc32bcbb0ac1606633db872aae /arch/arc
parent1898a959b7512fcf6fa9f436ac8c403fab7255c3 (diff)
ARC: Entry Handler tweaks: Simplify branch for in-kernel preemption
Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
Diffstat (limited to 'arch/arc')
-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 b4a96144430d..919e2f065d2f 100644
--- a/arch/arc/kernel/entry.S
+++ b/arch/arc/kernel/entry.S
@@ -586,11 +586,7 @@ ARC_ENTRY ret_from_exception
586 ; Pre-{IRQ,Trap,Exception} K/U mode from pt_regs->status32 586 ; Pre-{IRQ,Trap,Exception} K/U mode from pt_regs->status32
587 ld r8, [sp, PT_status32] ; returning to User/Kernel Mode 587 ld r8, [sp, PT_status32] ; returning to User/Kernel Mode
588 588
589#ifdef CONFIG_PREEMPT
590 bbit0 r8, STATUS_U_BIT, resume_kernel_mode 589 bbit0 r8, STATUS_U_BIT, resume_kernel_mode
591#else
592 bbit0 r8, STATUS_U_BIT, restore_regs
593#endif
594 590
595 ; Before returning to User mode check-for-and-complete any pending work 591 ; Before returning to User mode check-for-and-complete any pending work
596 ; such as rescheduling/signal-delivery etc. 592 ; such as rescheduling/signal-delivery etc.
@@ -650,10 +646,10 @@ resume_user_mode_begin:
650 b resume_user_mode_begin ; unconditionally back to U mode ret chks 646 b resume_user_mode_begin ; unconditionally back to U mode ret chks
651 ; for single exit point from this block 647 ; for single exit point from this block
652 648
653#ifdef CONFIG_PREEMPT
654
655resume_kernel_mode: 649resume_kernel_mode:
656 650
651#ifdef CONFIG_PREEMPT
652
657 ; Can't preempt if preemption disabled 653 ; Can't preempt if preemption disabled
658 GET_CURR_THR_INFO_FROM_SP r10 654 GET_CURR_THR_INFO_FROM_SP r10
659 ld r8, [r10, THREAD_INFO_PREEMPT_COUNT] 655 ld r8, [r10, THREAD_INFO_PREEMPT_COUNT]