Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp2135983ybi; Thu, 20 Jun 2019 09:39:08 -0700 (PDT) X-Google-Smtp-Source: APXvYqzUVeXqoMyhkZLer8Vy1ANlNK4bIdUjp2s7banDH34dy7CO77GS7RCtHoRaQSZChj6bCd+T X-Received: by 2002:a17:90a:8a84:: with SMTP id x4mr506301pjn.105.1561048748060; Thu, 20 Jun 2019 09:39:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1561048748; cv=none; d=google.com; s=arc-20160816; b=DvamfKPSWVNRSvYeSFsTztvNzlQ6mHhDLLC42ucH0nBXAFMY76845/OmQPOg+AkYQB EMTMBkh4cCC82L2nRwuhJEJcW8CW1v9YEVe3+pcNqY413zlrcOSQHQEPuyGOaGWe5/JS Z/gm7tH5SGcMieQkRjKSTztXlkImolsjlLSC9GHHtEQtIfxwpy2XHKQxqdZm5IdMwwxL 1spgt/TLP3cDLIM/1+Eze1L7ndRAKFNJnTxLfwMd63Zc+17uPB/vtTx/sbRmA/5Duvrq LzvHMhKxnunVBUB2ByF7BznEPeDpvxinvICXOljNI1O4/TfrVjBaagUtnPbdRsteYsvT b7ig== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:reply-to:message-id :subject:cc:to:from:date; bh=Wpkd1lveydrpmEYMRjlAi3xLbcqi4jKtDPCZ51Zihr0=; b=MVFvmJe6O6KndrSptTtaOA0HOsd1Eld7OGjPhQQAsqB8IFQsUc9vQ8alHeeE5E5N4u y209rX0L09PZmL1Clh/kVZYcaC4Jgq/zFhdlrqwBZW8frdBdR8H/A+ecRiy9EZvuJj1i X4Oag/l0y/F+J7ijlyPwoA3DOk43eAXyqZliTvlB0FvnJ69aQrO6Z9TleSkw4aNh6Awi JTisJdwbTymA0eNGnb5JIfvQFk602kkWBD48wuuZg9VGt0z0inbstzwPifIkrNb8r34b d7tDtOKI+D8sCkBcHrbeiOH6mXHHRtelgDKrtj/CrdYbnCv0PLJlU/zsudI2xKBjse2S lx5g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b2si15391pgt.270.2019.06.20.09.38.52; Thu, 20 Jun 2019 09:39:08 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732033AbfFTQi2 (ORCPT + 99 others); Thu, 20 Jun 2019 12:38:28 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:31718 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726675AbfFTQi2 (ORCPT ); Thu, 20 Jun 2019 12:38:28 -0400 Received: from pps.filterd (m0098396.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x5KGR0xZ120326; Thu, 20 Jun 2019 12:37:47 -0400 Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com with ESMTP id 2t8cmtkcqq-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 20 Jun 2019 12:37:47 -0400 Received: from m0098396.ppops.net (m0098396.ppops.net [127.0.0.1]) by pps.reinject (8.16.0.27/8.16.0.27) with SMTP id x5KGSnO5125503; Thu, 20 Jun 2019 12:37:46 -0400 Received: from ppma03dal.us.ibm.com (b.bd.3ea9.ip4.static.sl-reverse.com [169.62.189.11]) by mx0a-001b2d01.pphosted.com with ESMTP id 2t8cmtkcqb-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 20 Jun 2019 12:37:46 -0400 Received: from pps.filterd (ppma03dal.us.ibm.com [127.0.0.1]) by ppma03dal.us.ibm.com (8.16.0.27/8.16.0.27) with SMTP id x5KGVPpg018598; Thu, 20 Jun 2019 16:37:45 GMT Received: from b01cxnp23034.gho.pok.ibm.com (b01cxnp23034.gho.pok.ibm.com [9.57.198.29]) by ppma03dal.us.ibm.com with ESMTP id 2t4ra6ar88-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 20 Jun 2019 16:37:45 +0000 Received: from b01ledav003.gho.pok.ibm.com (b01ledav003.gho.pok.ibm.com [9.57.199.108]) by b01cxnp23034.gho.pok.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x5KGbiiI43909394 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 20 Jun 2019 16:37:44 GMT Received: from b01ledav003.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id CC5C2B2064; Thu, 20 Jun 2019 16:37:44 +0000 (GMT) Received: from b01ledav003.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id AF0F8B205F; Thu, 20 Jun 2019 16:37:44 +0000 (GMT) Received: from paulmck-ThinkPad-W541 (unknown [9.70.82.26]) by b01ledav003.gho.pok.ibm.com (Postfix) with ESMTP; Thu, 20 Jun 2019 16:37:44 +0000 (GMT) Received: by paulmck-ThinkPad-W541 (Postfix, from userid 1000) id 647E616C2A4A; Thu, 20 Jun 2019 09:37:46 -0700 (PDT) Date: Thu, 20 Jun 2019 09:37:46 -0700 From: "Paul E. McKenney" To: Alan Stern Cc: LKMM Maintainers -- Akira Yokosawa , Andrea Parri , Boqun Feng , Daniel Lustig , David Howells , Jade Alglave , Luc Maranget , Nicholas Piggin , Peter Zijlstra , Will Deacon , Kernel development list Subject: Re: [PATCH 1/3] tools: memory-model: Expand definition of barrier Message-ID: <20190620163746.GS26519@linux.ibm.com> Reply-To: paulmck@linux.ibm.com References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) X-TM-AS-GCONF: 00 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2019-06-20_11:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1906200120 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jun 20, 2019 at 11:55:36AM -0400, Alan Stern wrote: > Commit 66be4e66a7f4 ("rcu: locking and unlocking need to always be at > least barriers") added compiler barriers back into rcu_read_lock() and > rcu_read_unlock(). Furthermore, srcu_read_lock() and > srcu_read_unlock() have always contained compiler barriers. > > The Linux Kernel Memory Model ought to know about these barriers. > This patch adds them into the memory model. > > Signed-off-by: Alan Stern And yes, much easier to understand this way, thank you! I have queued them and they both diff equal to your previous patch and give the expected results on the litmus-tests and github tests having Result tags. Thanx, Paul > --- > > > tools/memory-model/linux-kernel.cat | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > Index: usb-devel/tools/memory-model/linux-kernel.cat > =================================================================== > --- usb-devel.orig/tools/memory-model/linux-kernel.cat > +++ usb-devel/tools/memory-model/linux-kernel.cat > @@ -47,7 +47,8 @@ let strong-fence = mb | gp > let nonrw-fence = strong-fence | po-rel | acq-po > let fence = nonrw-fence | wmb | rmb > let barrier = fencerel(Barrier | Rmb | Wmb | Mb | Sync-rcu | Sync-srcu | > - Before-atomic | After-atomic | Acquire | Release) | > + Before-atomic | After-atomic | Acquire | Release | > + Rcu-lock | Rcu-unlock | Srcu-lock | Srcu-unlock) | > (po ; [Release]) | ([Acquire] ; po) > > (**********************************) >