diff options
author | Ingo Molnar <mingo@elte.hu> | 2008-08-12 00:11:49 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-08-12 00:11:49 +0200 |
commit | 23a0ee908cbfba3264d19729c67c22b20fa73886 (patch) | |
tree | 541103f6283cbac6b82cff88a7b91128acfce046 /kernel/spinlock.c | |
parent | cc7a486cac78f6fc1a24e8cd63036bae8d2ab431 (diff) | |
parent | 0f2bc27be27ca1dcc66b96131e44bf7648b959c6 (diff) | |
download | blackbird-op-linux-23a0ee908cbfba3264d19729c67c22b20fa73886.tar.gz blackbird-op-linux-23a0ee908cbfba3264d19729c67c22b20fa73886.zip |
Merge branch 'core/locking' into core/urgent
Diffstat (limited to 'kernel/spinlock.c')
-rw-r--r-- | kernel/spinlock.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/kernel/spinlock.c b/kernel/spinlock.c index a1fb54c93cdd..44baeea94ab9 100644 --- a/kernel/spinlock.c +++ b/kernel/spinlock.c @@ -292,6 +292,7 @@ void __lockfunc _spin_lock_nested(spinlock_t *lock, int subclass) } EXPORT_SYMBOL(_spin_lock_nested); + unsigned long __lockfunc _spin_lock_irqsave_nested(spinlock_t *lock, int subclass) { unsigned long flags; @@ -314,6 +315,16 @@ unsigned long __lockfunc _spin_lock_irqsave_nested(spinlock_t *lock, int subclas EXPORT_SYMBOL(_spin_lock_irqsave_nested); +void __lockfunc _spin_lock_nest_lock(spinlock_t *lock, + struct lockdep_map *nest_lock) +{ + preempt_disable(); + spin_acquire_nest(&lock->dep_map, 0, 0, nest_lock, _RET_IP_); + LOCK_CONTENDED(lock, _raw_spin_trylock, _raw_spin_lock); +} + +EXPORT_SYMBOL(_spin_lock_nest_lock); + #endif void __lockfunc _spin_unlock(spinlock_t *lock) |