Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756137Ab3I3TQ6 (ORCPT ); Mon, 30 Sep 2013 15:16:58 -0400 Received: from mx1.redhat.com ([209.132.183.28]:60427 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755272Ab3I3TQ5 (ORCPT ); Mon, 30 Sep 2013 15:16:57 -0400 Date: Mon, 30 Sep 2013 21:16:00 +0200 From: Andrea Arcangeli To: Linus Torvalds Cc: Ingo Molnar , Waiman Long , Ingo Molnar , Andrew Morton , Linux Kernel Mailing List , Rik van Riel , Peter Hurley , Davidlohr Bueso , Alex Shi , Tim Chen , Peter Zijlstra , Matthew R Wilcox , Dave Hansen , Michel Lespinasse , Andi Kleen , "Chandramouleeswaran, Aswin" , "Norton, Scott J" , Haggai Eran , Sagi Grimberg , Or Gerlitz , Jerome Glisse Subject: Re: [PATCH] anon_vmas: Convert the rwsem to an rwlock_t Message-ID: <20130930191600.GL29230@redhat.com> References: <1380308424-31011-1-git-send-email-Waiman.Long@hp.com> <20130928074144.GA17773@gmail.com> <20130928192123.GA8228@gmail.com> <20130928193739.GA8642@gmail.com> <20130930085243.GA25685@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1330 Lines: 27 On Mon, Sep 30, 2013 at 09:26:21AM -0700, Linus Torvalds wrote: > On Mon, Sep 30, 2013 at 1:52 AM, Andrea Arcangeli wrote: > > > > Sorry having to break the party but the sleepable locks for anon_vma > > and i_mmap_mutex are now requirement for the "pageable RDMA" effort > > recently achieved upstream by mellanox with the MMU notifier. > > I'll happily break that. Unless a solution is found that could allow to invalidate secondary MMUs with a spinlock/rwlock for anon_vma->lock/i_mmap_lock, would it be acceptable to switch between spinlock/rwlock mutex/rwsem through a config option? option CONFIG_SLEEPABLE_RMAP, implicitly selected by CONFIG_SLEEPABLE_MMU_NOTIFIER, in turn selected by the RDMA and nvidia drivers if they're built (ideally nvidia drivers will figure out how to avoid scheduling). I mean it only requires a wrapping header file, aside from the header file it wouldn't be a much bigger patch than the one posted already. It would be much easier to switch between spinning and sleeping locks to keep benchmarking different scenarios too. -- 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/