The patch titled rtmutex-clean-up-and-remove-some-extra-spinlocks-more has been added to the -mm tree. Its filename is rtmutex-clean-up-and-remove-some-extra-spinlocks-more.patch See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find out what to do about this ------------------------------------------------------ Subject: rtmutex-clean-up-and-remove-some-extra-spinlocks-more From: Oleg Nesterov <oleg@xxxxxxxxxx> On top of Steven's rtmutex-clean-up-and-remove-some-extra-spinlocks.patch There are still 2 get_task_struct()s under ->pi_lock. Imho, this is confusing. Move them outside of ->pi_lock protected section. The task can't go away, otherwise it was unsafe to take task->pi_lock. Signed-off-by: Oleg Nesterov <oleg@xxxxxxxxxx> Cc: Steven Rostedt <rostedt@xxxxxxxxxxx> Cc: Ingo Molnar <mingo@xxxxxxx> Cc: Thomas Gleixner <tglx@xxxxxxxxxxxxx> Cc: Esben Nielsen <nielsen.esben@xxxxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxx> --- kernel/rtmutex.c | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff -puN kernel/rtmutex.c~rtmutex-clean-up-and-remove-some-extra-spinlocks-more kernel/rtmutex.c --- a/kernel/rtmutex.c~rtmutex-clean-up-and-remove-some-extra-spinlocks-more +++ a/kernel/rtmutex.c @@ -251,6 +251,7 @@ static int rt_mutex_adjust_prio_chain(st /* Grab the next task */ task = rt_mutex_owner(lock); + get_task_struct(task); spin_lock_irqsave(&task->pi_lock, flags); if (waiter == rt_mutex_top_waiter(lock)) { @@ -269,7 +270,6 @@ static int rt_mutex_adjust_prio_chain(st __rt_mutex_adjust_prio(task); } - get_task_struct(task); spin_unlock_irqrestore(&task->pi_lock, flags); top_waiter = rt_mutex_top_waiter(lock); @@ -591,10 +591,10 @@ void rt_mutex_adjust_pi(struct task_stru return; } - /* gets dropped in rt_mutex_adjust_prio_chain()! */ - get_task_struct(task); spin_unlock_irqrestore(&task->pi_lock, flags); + /* gets dropped in rt_mutex_adjust_prio_chain()! */ + get_task_struct(task); rt_mutex_adjust_prio_chain(task, 0, NULL, NULL, task); } _ Patches currently in -mm which might be from oleg@xxxxxxxxxx are sys_getppid-oopses-on-debug-kernel-v2.patch pid-implement-transfer_pid-and-use-it-to-simplify-de_thread.patch pid-remove-temporary-debug-code-in-attach_pid.patch rtmutex-clean-up-and-remove-some-extra-spinlocks.patch rtmutex-clean-up-and-remove-some-extra-spinlocks-more.patch pidhash-temporary-debug-checks.patch - To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html