Commit d379e64c authored by Frederic Weisbecker's avatar Frederic Weisbecker Committed by Greg Kroah-Hartman

sched/preempt: Rename PREEMPT_CHECK_OFFSET to PREEMPT_DISABLE_OFFSET

commit 90b62b51 upstream.

"CHECK" suggests it's only used as a comparison mask. But now it's used
further as a config-conditional preempt disabler offset. Lets
disambiguate this name.
Signed-off-by: default avatarFrederic Weisbecker <fweisbec@gmail.com>
Signed-off-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Link: http://lkml.kernel.org/r/1431441711-29753-4-git-send-email-fweisbec@gmail.comSigned-off-by: default avatarIngo Molnar <mingo@kernel.org>
Signed-off-by: default avatarMike Galbraith <efault@gmx.de>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent d11f754e
...@@ -72,9 +72,9 @@ ...@@ -72,9 +72,9 @@
#define in_nmi() (preempt_count() & NMI_MASK) #define in_nmi() (preempt_count() & NMI_MASK)
#if defined(CONFIG_PREEMPT_COUNT) #if defined(CONFIG_PREEMPT_COUNT)
# define PREEMPT_CHECK_OFFSET 1 # define PREEMPT_DISABLE_OFFSET 1
#else #else
# define PREEMPT_CHECK_OFFSET 0 # define PREEMPT_DISABLE_OFFSET 0
#endif #endif
/* /*
...@@ -90,7 +90,7 @@ ...@@ -90,7 +90,7 @@
* *
* Work as expected. * Work as expected.
*/ */
#define SOFTIRQ_LOCK_OFFSET (SOFTIRQ_DISABLE_OFFSET + PREEMPT_CHECK_OFFSET) #define SOFTIRQ_LOCK_OFFSET (SOFTIRQ_DISABLE_OFFSET + PREEMPT_DISABLE_OFFSET)
/* /*
* Are we running in atomic context? WARNING: this macro cannot * Are we running in atomic context? WARNING: this macro cannot
...@@ -106,7 +106,7 @@ ...@@ -106,7 +106,7 @@
* (used by the scheduler, *after* releasing the kernel lock) * (used by the scheduler, *after* releasing the kernel lock)
*/ */
#define in_atomic_preempt_off() \ #define in_atomic_preempt_off() \
((preempt_count() & ~PREEMPT_ACTIVE) != PREEMPT_CHECK_OFFSET) ((preempt_count() & ~PREEMPT_ACTIVE) != PREEMPT_DISABLE_OFFSET)
#ifdef CONFIG_PREEMPT_COUNT #ifdef CONFIG_PREEMPT_COUNT
# define preemptible() (preempt_count() == 0 && !irqs_disabled()) # define preemptible() (preempt_count() == 0 && !irqs_disabled())
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment