From mboxrd@z Thu Jan 1 00:00:00 1970 From: Peter Zijlstra Subject: Re: f68f031d ("Documentation: atomic_t.txt: Explain ordering provided by smp_mb__{before,after}_atomic()") Date: Fri, 3 May 2019 18:34:11 +0200 Message-ID: <20190503163411.GH2606@hirez.programming.kicks-ass.net> References: <20190503151915.GD2606@hirez.programming.kicks-ass.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org To: Alan Stern Cc: "Paul E. McKenney" , linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org List-Id: linux-arch.vger.kernel.org On Fri, May 03, 2019 at 12:19:21PM -0400, Alan Stern wrote: > On Fri, 3 May 2019, Peter Zijlstra wrote: > > > On Fri, May 03, 2019 at 07:53:26AM -0700, Paul E. McKenney wrote: > > > Hello, Alan, > > > > > > Just following up on the -rcu commit below. I believe that it needs > > > some adjustment given Peter Zijlstra's addition of "memory" to the x86 > > > non-value-returning atomics, but thought I should double-check. > > > > Right; I should get back to that thread... > > The real question, still outstanding, is whether smp_mb__before_atomic > orders anything following the RMW instruction (and similarly, whether > smp_mb__after_atomic orders anything preceding the RMW instruction). Yes -- that was very much the intent, and only (some) x86 ops and (some) MIPS config have issues with that. From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from bombadil.infradead.org ([198.137.202.133]:52528 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725809AbfECQeO (ORCPT ); Fri, 3 May 2019 12:34:14 -0400 Date: Fri, 3 May 2019 18:34:11 +0200 From: Peter Zijlstra Subject: Re: f68f031d ("Documentation: atomic_t.txt: Explain ordering provided by smp_mb__{before,after}_atomic()") Message-ID: <20190503163411.GH2606@hirez.programming.kicks-ass.net> References: <20190503151915.GD2606@hirez.programming.kicks-ass.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: linux-arch-owner@vger.kernel.org List-ID: To: Alan Stern Cc: "Paul E. McKenney" , linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org Message-ID: <20190503163411.anpdpJAQNYJf-2OxaFHiiFpfdTSy6aIAWzIT0qER8fs@z> On Fri, May 03, 2019 at 12:19:21PM -0400, Alan Stern wrote: > On Fri, 3 May 2019, Peter Zijlstra wrote: > > > On Fri, May 03, 2019 at 07:53:26AM -0700, Paul E. McKenney wrote: > > > Hello, Alan, > > > > > > Just following up on the -rcu commit below. I believe that it needs > > > some adjustment given Peter Zijlstra's addition of "memory" to the x86 > > > non-value-returning atomics, but thought I should double-check. > > > > Right; I should get back to that thread... > > The real question, still outstanding, is whether smp_mb__before_atomic > orders anything following the RMW instruction (and similarly, whether > smp_mb__after_atomic orders anything preceding the RMW instruction). Yes -- that was very much the intent, and only (some) x86 ops and (some) MIPS config have issues with that.