aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/traps.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2009-02-17 11:20:11 -0500
committerIngo Molnar <mingo@elte.hu>2009-02-17 11:20:11 -0500
commit0b6de0092244c98b5ba1abda34c92470a20e0d0c (patch)
tree478e4e18c33fd9fa517559e1ce951fe378d5965f /arch/x86/kernel/traps.c
parent37a25424252b6cff4dd4b1937ab6a1dbfcadabcc (diff)
parentf62bae5009c1ba596cd475cafbc83e0570a36e26 (diff)
Merge branch 'x86/apic' into perfcounters/core
Conflicts: arch/x86/kernel/cpu/perfctr-watchdog.c
Diffstat (limited to 'arch/x86/kernel/traps.c')
-rw-r--r--arch/x86/kernel/traps.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/arch/x86/kernel/traps.c b/arch/x86/kernel/traps.c
index 6cba7abf3518..c85a86cb7fb1 100644
--- a/arch/x86/kernel/traps.c
+++ b/arch/x86/kernel/traps.c
@@ -98,6 +98,12 @@ static inline void preempt_conditional_sti(struct pt_regs *regs)
98 local_irq_enable(); 98 local_irq_enable();
99} 99}
100 100
101static inline void conditional_cli(struct pt_regs *regs)
102{
103 if (regs->flags & X86_EFLAGS_IF)
104 local_irq_disable();
105}
106
101static inline void preempt_conditional_cli(struct pt_regs *regs) 107static inline void preempt_conditional_cli(struct pt_regs *regs)
102{ 108{
103 if (regs->flags & X86_EFLAGS_IF) 109 if (regs->flags & X86_EFLAGS_IF)
@@ -625,8 +631,10 @@ clear_dr7:
625 631
626#ifdef CONFIG_X86_32 632#ifdef CONFIG_X86_32
627debug_vm86: 633debug_vm86:
634 /* reenable preemption: handle_vm86_trap() might sleep */
635 dec_preempt_count();
628 handle_vm86_trap((struct kernel_vm86_regs *) regs, error_code, 1); 636 handle_vm86_trap((struct kernel_vm86_regs *) regs, error_code, 1);
629 preempt_conditional_cli(regs); 637 conditional_cli(regs);
630 return; 638 return;
631#endif 639#endif
632 640