From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from relay.sgi.com (relay2.corp.sgi.com [137.38.102.29]) by oss.sgi.com (Postfix) with ESMTP id 509097CF2 for ; Thu, 7 Jul 2016 09:14:27 -0500 (CDT) Received: from cuda.sgi.com (cuda2.sgi.com [192.48.176.25]) by relay2.corp.sgi.com (Postfix) with ESMTP id 217243040E4 for ; Thu, 7 Jul 2016 07:14:20 -0700 (PDT) Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by cuda.sgi.com with ESMTP id mUmhIDRbHziK4H8X (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO) for ; Thu, 07 Jul 2016 07:14:20 -0700 (PDT) From: David Howells In-Reply-To: <1467831425.2908.16.camel@redhat.com> References: <1467831425.2908.16.camel@redhat.com> <1467294433-3222-1-git-send-email-agruenba@redhat.com> <1467294433-3222-14-git-send-email-agruenba@redhat.com> Subject: Re: [PATCH v23 13/22] vfs: Cache richacl in struct inode MIME-Version: 1.0 Content-ID: <1688.1467900853.1@warthog.procyon.org.uk> Date: Thu, 07 Jul 2016 15:14:13 +0100 Message-ID: <1689.1467900853@warthog.procyon.org.uk> List-Id: XFS Filesystem from SGI List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: xfs-bounces@oss.sgi.com Sender: xfs-bounces@oss.sgi.com To: Jeff Layton , Andreas Gruenbacher , Alexander Viro Cc: Christoph Hellwig , linux-nfs@vger.kernel.org, Theodore Ts'o , linux-cifs@vger.kernel.org, linux-api@vger.kernel.org, Trond Myklebust , linux-kernel@vger.kernel.org, xfs@oss.sgi.com, dhowells@redhat.com, Andreas Dilger , "J. Bruce Fields" , linux-fsdevel@vger.kernel.org, linux-ext4@vger.kernel.org, Anna Schumaker Jeff Layton wrote: > > + if (cmpxchg(&inode->i_acl, ACL_NOT_CACHED, sentinel) != ACL_NOT_CACHED) > > + /* fall through */ ; > > + > > So you do the same thing regardless of the outcome of the above? Why > bother with the if at all here? Just do the cmpxchg and toss out the > result. gcc might complain if you don't check the result. However, this does look like it's subject to a thundering herd problem. If 30000 processes all look at the ACL at the same time on a network fs, could that cause 30000 RPC calls to be transmitted for the same thing? David _______________________________________________ xfs mailing list xfs@oss.sgi.com http://oss.sgi.com/mailman/listinfo/xfs