Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754307AbbFEMfn (ORCPT ); Fri, 5 Jun 2015 08:35:43 -0400 Received: from www.linutronix.de ([62.245.132.108]:35278 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751195AbbFEMfl (ORCPT ); Fri, 5 Jun 2015 08:35:41 -0400 Date: Fri, 5 Jun 2015 14:35:32 +0200 (CEST) From: Thomas Gleixner To: Davidlohr Bueso cc: Peter Zijlstra , Ingo Molnar , Steven Rostedt , Mike Galbraith , "Paul E. McKenney" , Sebastian Andrzej Siewior , linux-kernel@vger.kernel.org, Davidlohr Bueso Subject: Re: [PATCH 1/4] locking/rtmutex: Implement lockless top-waiter wakeup In-Reply-To: <1432056298-18738-2-git-send-email-dave@stgolabs.net> Message-ID: References: <1432056298-18738-1-git-send-email-dave@stgolabs.net> <1432056298-18738-2-git-send-email-dave@stgolabs.net> User-Agent: Alpine 2.11 (DEB 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Linutronix-Spam-Score: -1.0 X-Linutronix-Spam-Level: - X-Linutronix-Spam-Status: No , -1.0 points, 5.0 required, ALL_TRUSTED=-1,SHORTCIRCUIT=-0.0001,URIBL_BLOCKED=0.001 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1006 Lines: 20 On Tue, 19 May 2015, Davidlohr Bueso wrote: > Mark the task for later wakeup after the wait_lock has been released. > This way, once the next task is awoken, it will have a better chance > to of finding the wait_lock free when continuing executing in > __rt_mutex_slowlock() when trying to acquire the rtmutex, calling > try_to_take_rt_mutex(). Upon contended scenarios, other tasks attempting > take the lock may acquire it first, right after the wait_lock is released, > but (a) this can also occur with the current code, as it relies on the > spinlock fairness, and (b) we are dealing with the top-waiter anyway, > so it will always take the lock next. > > Signed-off-by: Davidlohr Bueso Reviewed-by: Thomas Gleixner -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/