From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755131AbbGQXbS (ORCPT ); Fri, 17 Jul 2015 19:31:18 -0400 Received: from mx1.redhat.com ([209.132.183.28]:52969 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753456AbbGQXbQ (ORCPT ); Fri, 17 Jul 2015 19:31:16 -0400 Date: Sat, 18 Jul 2015 01:29:30 +0200 From: Oleg Nesterov To: "Paul E. McKenney" Cc: Linus Torvalds , Peter Zijlstra , Daniel Wagner , Davidlohr Bueso , Ingo Molnar , Tejun Heo , linux-kernel@vger.kernel.org Subject: Re: [PATCH 0/7] Add rcu_sync infrastructure to avoid _expedited() in percpu-rwsem Message-ID: <20150717232930.GA16247@redhat.com> References: <20150711233535.GA829@redhat.com> <20150715182713.GL3717@linux.vnet.ibm.com> <20150715193601.GA4386@redhat.com> <20150715215927.GO3717@linux.vnet.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20150715215927.GO3717@linux.vnet.ibm.com> User-Agent: Mutt/1.5.18 (2008-05-17) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 07/15, Paul E. McKenney wrote: > > On Wed, Jul 15, 2015 at 09:36:01PM +0200, Oleg Nesterov wrote: > > > > Do you mean you need another user except percpu_rw_semaphore? I do > > not see any right now... > > Not asking for more than one use, but it does need a use. I believe > that percpu_rw_semaphore suffices. > > > Let me remind about sb_writers again. It actually has 3 rw_sem's > > and I am trying to turn then into percpu_rw_semaphore's. > > > > In this case freeze_super() will need 6 synchronize_sched_expedited(). > > This just looks ugly. But if we have rcu_sync primitives, all 3 sem's > > in struct super_block can share the same "struct rcu_sync", and > > freeze_super() will need only once synchronize_sched(). > > Makes sense. Great, thanks. And iiuc Linus doesn't object to this particular change. Plus I see the "Make checkpatch.pl warn on expedited RCU grace periods" patch ;) So can I assume you will take these changes? I do not need them right now, just I need to know what should I do in destroy_super() and (much more importantly) what should I say in the changelogs if I try to convert sb_writers to use percpu_rw_semaphore. Oleg.