Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756650AbbBQKJQ (ORCPT ); Tue, 17 Feb 2015 05:09:16 -0500 Received: from www.linutronix.de ([62.245.132.108]:43027 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756632AbbBQKJN (ORCPT ); Tue, 17 Feb 2015 05:09:13 -0500 Date: Tue, 17 Feb 2015 11:09:11 +0100 From: Sebastian Andrzej Siewior To: Clark Williams Cc: Thomas Gleixner , LKML , RT Subject: Re: [PATCH RT] rt: add rwsem_is_contended() definition to rwsem_rt.h Message-ID: <20150217100911.GG26177@linutronix.de> References: <20140827160928.6f323642@sluggy> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20140827160928.6f323642@sluggy> X-Key-Id: 97C4700B X-Key-Fingerprint: 09E2 D1F3 9A3A FF13 C3D3 961C 0688 1C1E 97C4 700B User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 910 Lines: 25 * Clark Williams | 2014-08-27 16:09:28 [-0500]: >Thomas, > >The latest btrfs code uses rwsem_is_contended() in the function >caching_thread(). On RT systems, include/linux/rwsem.h is replaced with >include/linux/rwsem_rt.h which does not provide a definition for >rwsem_is_contended(). This commit provides a definition that should >work on RT (where the lock is actually an rt_mutex). I see that I added rwsem_is_contended() in v3.14-rt1 which does: |static inline int rwsem_is_contended(struct rw_semaphore *sem) |{ | /* rt_mutex_has_waiters() */ | return !RB_EMPTY_ROOT(&sem->lock.waiters); |} Do you lack this in kernel prior to v3.14? Sebastian -- 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/