From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756620AbcBBRhh (ORCPT ); Tue, 2 Feb 2016 12:37:37 -0500 Received: from foss.arm.com ([217.140.101.70]:57295 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756573AbcBBRhg (ORCPT ); Tue, 2 Feb 2016 12:37:36 -0500 Date: Tue, 2 Feb 2016 17:37:35 +0000 From: Will Deacon To: "Paul E. McKenney" Cc: Boqun Feng , Peter Zijlstra , "Maciej W. Rozycki" , David Daney , =?iso-8859-1?Q?M=E5ns_Rullg=E5rd?= , Ralf Baechle , linux-kernel@vger.kernel.org, torvalds@linux-foundation.org Subject: Re: [RFC][PATCH] mips: Fix arch_spin_unlock() Message-ID: <20160202173734.GN10166@arm.com> References: <20160128223131.GV4503@linux.vnet.ibm.com> <20160129095958.GA4541@arm.com> <20160129102253.GG4503@linux.vnet.ibm.com> <20160201135621.GD6828@arm.com> <20160202035458.GF6719@linux.vnet.ibm.com> <20160202051904.GC1239@fixme-laptop.cn.ibm.com> <20160202114559.GA10166@arm.com> <20160202121230.GE1239@fixme-laptop.cn.ibm.com> <20160202122025.GB10166@arm.com> <20160202171237.GL6719@linux.vnet.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20160202171237.GL6719@linux.vnet.ibm.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Feb 02, 2016 at 09:12:37AM -0800, Paul E. McKenney wrote: > On Tue, Feb 02, 2016 at 12:20:25PM +0000, Will Deacon wrote: > > On Tue, Feb 02, 2016 at 08:12:30PM +0800, Boqun Feng wrote: > > > On Tue, Feb 02, 2016 at 11:45:59AM +0000, Will Deacon wrote: > > > > Well, the following ISA2 test is permitted on ARM: > > > > > > > > > > > > P0: > > > > Wx=1 > > > > WyRel=1 // rcu_assign_pointer > > > > > > > > P1: > > > > Ry=1 // rcu_dereference > > > > > > What if a dependency is added here? Same result? > > > > Right, that fixes it. So if we're only considering things like: > > > > rcu_dereference > > > > RELEASE > > > > then local transitivity should be preserved. > > Whew!!! ;-) > > > I think the same applies to , which seems to match your later > > example. > > Could you please check? I should've been more concrete here: it does indeed apply if you replace the with a in the snippet above, I just hadn't got Boqun's example paged in and didn't want to commit on the examples being identical. Will