]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - arch/x86/kernel/entry_32.S
sched, x86: Provide a per-cpu preempt_count implementation
[karo-tx-linux.git] / arch / x86 / kernel / entry_32.S
index f0dcb0ceb6a2eda24d298b8a05650374e753bcf6..fd1bc1b15e6d8ebfc0f9e98a025e2ed65601c7fa 100644 (file)
@@ -362,12 +362,9 @@ END(ret_from_exception)
 #ifdef CONFIG_PREEMPT
 ENTRY(resume_kernel)
        DISABLE_INTERRUPTS(CLBR_ANY)
-       cmpl $0,TI_preempt_count(%ebp)  # non-zero preempt_count ?
-       jnz restore_all
 need_resched:
-       movl TI_flags(%ebp), %ecx       # need_resched set ?
-       testb $_TIF_NEED_RESCHED, %cl
-       jz restore_all
+       cmpl $0,PER_CPU_VAR(__preempt_count)
+       jnz restore_all
        testl $X86_EFLAGS_IF,PT_EFLAGS(%esp)    # interrupts off (exception path) ?
        jz restore_all
        call preempt_schedule_irq