]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/blobdiff - include/linux/preempt.h
sched/core: Simplify preempt_count tests
[mirror_ubuntu-artful-kernel.git] / include / linux / preempt.h
index 448dfd0b2ea6f8f2cd9c21205756b6f576235977..b2676a16cfbe2448f39d6ee975f96785a1bb581c 100644 (file)
  * Check whether we were atomic before we did preempt_disable():
  * (used by the scheduler)
  */
-#define in_atomic_preempt_off() \
-               ((preempt_count() & ~PREEMPT_ACTIVE) != PREEMPT_DISABLE_OFFSET)
+#define in_atomic_preempt_off() (preempt_count() != PREEMPT_DISABLE_OFFSET)
 
 #if defined(CONFIG_DEBUG_PREEMPT) || defined(CONFIG_PREEMPT_TRACER)
 extern void preempt_count_add(int val);