Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753380AbdGGCxp (ORCPT ); Thu, 6 Jul 2017 22:53:45 -0400 Received: from mail-pg0-f43.google.com ([74.125.83.43]:35088 "EHLO mail-pg0-f43.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753296AbdGGCxn (ORCPT ); Thu, 6 Jul 2017 22:53:43 -0400 From: Alex Shi To: peterz@infradead.org, mingo@redhat.com, corbet@lwn.net, linux-kernel@vger.kernel.org (open list:LOCKING PRIMITIVES), linux-doc@vger.kernel.org (open list:DOCUMENTATION) Cc: linux-kernel@vger.kernel.org, Alex Shi , Steven Rostedt , Sebastian Siewior , Mathieu Poirier , Juri Lelli , Thomas Gleixner Subject: [PATCH 3/3] rtmutex: remove unnecessary adjust prio Date: Fri, 7 Jul 2017 10:52:02 +0800 Message-Id: <1499395922-542-3-git-send-email-alex.shi@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1499395922-542-1-git-send-email-alex.shi@linaro.org> References: <1499395922-542-1-git-send-email-alex.shi@linaro.org> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 975 Lines: 30 We don't need to adjust prio before new pi_waiter adding. The prio only need update after pi_waiter change or task priority change. Signed-off-by: Alex Shi Cc: Steven Rostedt Cc: Sebastian Siewior Cc: Mathieu Poirier Cc: Juri Lelli Cc: Thomas Gleixner To: linux-kernel@vger.kernel.org To: Ingo Molnar To: Peter Zijlstra --- kernel/locking/rtmutex.c | 1 - 1 file changed, 1 deletion(-) diff --git a/kernel/locking/rtmutex.c b/kernel/locking/rtmutex.c index 28cd09e..d1fe41f 100644 --- a/kernel/locking/rtmutex.c +++ b/kernel/locking/rtmutex.c @@ -963,7 +963,6 @@ static int task_blocks_on_rt_mutex(struct rt_mutex *lock, return -EDEADLK; raw_spin_lock(&task->pi_lock); - rt_mutex_adjust_prio(task); waiter->task = task; waiter->lock = lock; waiter->prio = task->prio; -- 2.7.4