diff options
-rw-r--r-- | kernel/Kconfig.locks | 3 | ||||
-rw-r--r-- | kernel/mutex.c | 4 |
2 files changed, 5 insertions, 2 deletions
diff --git a/kernel/Kconfig.locks b/kernel/Kconfig.locks index d1f86db71451..88c92fb44618 100644 --- a/kernel/Kconfig.locks +++ b/kernel/Kconfig.locks | |||
@@ -197,3 +197,6 @@ config INLINE_WRITE_UNLOCK_IRQ | |||
197 | 197 | ||
198 | config INLINE_WRITE_UNLOCK_IRQRESTORE | 198 | config INLINE_WRITE_UNLOCK_IRQRESTORE |
199 | def_bool !DEBUG_SPINLOCK && ARCH_INLINE_WRITE_UNLOCK_IRQRESTORE | 199 | def_bool !DEBUG_SPINLOCK && ARCH_INLINE_WRITE_UNLOCK_IRQRESTORE |
200 | |||
201 | config MUTEX_SPIN_ON_OWNER | ||
202 | def_bool SMP && !DEBUG_MUTEXES && !HAVE_DEFAULT_NO_SPIN_MUTEXES | ||
diff --git a/kernel/mutex.c b/kernel/mutex.c index 947b3ad551f8..632f04c57d82 100644 --- a/kernel/mutex.c +++ b/kernel/mutex.c | |||
@@ -148,8 +148,8 @@ __mutex_lock_common(struct mutex *lock, long state, unsigned int subclass, | |||
148 | 148 | ||
149 | preempt_disable(); | 149 | preempt_disable(); |
150 | mutex_acquire(&lock->dep_map, subclass, 0, ip); | 150 | mutex_acquire(&lock->dep_map, subclass, 0, ip); |
151 | #if defined(CONFIG_SMP) && !defined(CONFIG_DEBUG_MUTEXES) && \ | 151 | |
152 | !defined(CONFIG_HAVE_DEFAULT_NO_SPIN_MUTEXES) | 152 | #ifdef CONFIG_MUTEX_SPIN_ON_OWNER |
153 | /* | 153 | /* |
154 | * Optimistic spinning. | 154 | * Optimistic spinning. |
155 | * | 155 | * |