diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2010-02-24 09:50:22 +0100 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2010-02-24 12:10:52 +0100 |
commit | d0ce166dd4c76b1eb484aa68f1cddaafdeef9238 (patch) | |
tree | 6f1733a3a5b4087a00cec568a322b6811547855d /include | |
parent | 8e7deaa4367607057fd7c1038d2f6df981367bd5 (diff) | |
download | lwn-d0ce166dd4c76b1eb484aa68f1cddaafdeef9238.tar.gz lwn-d0ce166dd4c76b1eb484aa68f1cddaafdeef9238.zip |
semaphore: Make inner lock raw
There is no reason to have the spin_lock protecting the semaphore
being converted to a sleeping spinlock in -rt. Convert it to a
raw_spinlock. That also solves lockdep complaining about the
rt_mutex.wait_lock being not initialized.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/semaphore.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/semaphore.h b/include/linux/semaphore.h index aaeced9d24ea..66d25917cea0 100644 --- a/include/linux/semaphore.h +++ b/include/linux/semaphore.h @@ -14,14 +14,14 @@ /* Please don't access any members of this structure directly */ struct semaphore { - spinlock_t lock; + raw_spinlock_t lock; unsigned int count; struct list_head wait_list; }; #define __SEMAPHORE_INITIALIZER(name, n) \ { \ - .lock = __SPIN_LOCK_UNLOCKED((name).lock), \ + .lock = __RAW_SPIN_LOCK_UNLOCKED((name).lock), \ .count = n, \ .wait_list = LIST_HEAD_INIT((name).wait_list), \ } |