Commit 73d33caf authored by Gregory Haskins's avatar Gregory Haskins Committed by Thomas Gleixner

rtmutex: Remove the extra call to try_to_take_lock

[ The following text is in the "utf-8" character set. ]
    [ Your display is set for the "iso-8859-1" character set.  ]
    [ Some characters may be displayed incorrectly. ]

From: Peter W. Morreale <pmorreale@novell.com>

Remove the redundant attempt to get the lock.  While it is true that the
exit path with this patch adds an un-necessary xchg (in the event the
lock is granted without further traversal in the loop) experimentation
shows that we almost never encounter this situation.
Signed-off-by: default avatarPeter W. Morreale <pmorreale@novell.com>
Signed-off-by: default avatarGregory Haskins <ghaskins@novell.com>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
parent 26ba8e4b
......@@ -775,12 +775,6 @@ rt_spin_lock_slowlock(struct rt_mutex *lock)
atomic_spin_lock_irqsave(&lock->wait_lock, flags);
init_lists(lock);
/* Try to acquire the lock again: */
if (do_try_to_take_rt_mutex(lock, STEAL_LATERAL)) {
atomic_spin_unlock_irqrestore(&lock->wait_lock, flags);
return;
}
BUG_ON(rt_mutex_owner(lock) == current);
/*
......
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