Merge branch 'locking/rwsem'
[linux-2.6-microblaze.git] / kernel / futex.c
index ac32887..c47d101 100644 (file)
@@ -310,8 +310,6 @@ static inline bool should_fail_futex(bool fshared)
 
 #ifdef CONFIG_COMPAT
 static void compat_exit_robust_list(struct task_struct *curr);
-#else
-static inline void compat_exit_robust_list(struct task_struct *curr) { }
 #endif
 
 /*
@@ -788,8 +786,9 @@ static void put_pi_state(struct futex_pi_state *pi_state)
         */
        if (pi_state->owner) {
                struct task_struct *owner;
+               unsigned long flags;
 
-               raw_spin_lock_irq(&pi_state->pi_mutex.wait_lock);
+               raw_spin_lock_irqsave(&pi_state->pi_mutex.wait_lock, flags);
                owner = pi_state->owner;
                if (owner) {
                        raw_spin_lock(&owner->pi_lock);
@@ -797,7 +796,7 @@ static void put_pi_state(struct futex_pi_state *pi_state)
                        raw_spin_unlock(&owner->pi_lock);
                }
                rt_mutex_proxy_unlock(&pi_state->pi_mutex, owner);
-               raw_spin_unlock_irq(&pi_state->pi_mutex.wait_lock);
+               raw_spin_unlock_irqrestore(&pi_state->pi_mutex.wait_lock, flags);
        }
 
        if (current->pi_state_cache) {