From patchwork Sun Feb 2 22:04:38 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Trond Myklebust X-Patchwork-Id: 3567631 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id D9AFDC02DC for ; Sun, 2 Feb 2014 22:05:22 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 02CB720165 for ; Sun, 2 Feb 2014 22:05:22 +0000 (UTC) Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 07A92201BC for ; Sun, 2 Feb 2014 22:05:21 +0000 (UTC) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1WA5A3-0007qF-Ao; Sun, 02 Feb 2014 22:05:07 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1WA5A0-0000e1-UH; Sun, 02 Feb 2014 22:05:04 +0000 Received: from mail-ie0-f172.google.com ([209.85.223.172]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1WA59y-0000cp-01 for linux-arm-kernel@lists.infradead.org; Sun, 02 Feb 2014 22:05:02 +0000 Received: by mail-ie0-f172.google.com with SMTP id e14so5899593iej.17 for ; Sun, 02 Feb 2014 14:04:40 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:organization:content-type:mime-version :content-transfer-encoding; bh=sB8rsMO6nSCUbMueFrJAbSFjw3YY5PNeTA4o3same4Q=; b=JAt82Rlad5VEni/GxOmkJydq86SkaUvW69hAT+GXkNX9StktZZUdmIXgJF0W5AvdXd 2OkeUv4jgbPTJWBE9nwJQOrbcfbgskjzQ4aDPzgLB6SwX55bmFCWSEOZvfYiPmbLGuiw qg8BYp95CD5lQTzGLz2B4OdmPNia350WN8fdWcRzBgPpaJTBnyh3gnBPR6SkUUBrukmy HKRsYBLmGFsazPBs/llSRMmZQO24+sMYvsZgdAFR6BFCx1fYyPfcUw3xDK25m8HgzycP 0X5tEQsdi7E9dW+QBEFA3VWh26mTgTHfd0KRg2QG74OoH/l+eSyTUCAi1n5aWqs0qyYL FSSg== X-Gm-Message-State: ALoCoQlGe1QfaIS7TaUXQQ0ergBZUQLolrvvZLx817gNUx78bVgIuyJ8qMhUKnrEI7Q7jEmYXKP9 X-Received: by 10.50.79.170 with SMTP id k10mr9271365igx.14.1391378680097; Sun, 02 Feb 2014 14:04:40 -0800 (PST) Received: from [172.16.74.153] (c-98-209-19-95.hsd1.mi.comcast.net. [98.209.19.95]) by mx.google.com with ESMTPSA id ft2sm23515634igb.5.2014.02.02.14.04.38 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Sun, 02 Feb 2014 14:04:39 -0800 (PST) Message-ID: <1391378678.8123.5.camel@leira.trondhjem.org> Subject: Re: NFS client broken in Linus' tip From: Trond Myklebust To: Russell King - ARM Linux Date: Sun, 02 Feb 2014 17:04:38 -0500 In-Reply-To: <20140202122757.GC26684@n2100.arm.linux.org.uk> References: <20140130140834.GW15937@n2100.arm.linux.org.uk> <20140130141405.GA23985@infradead.org> <20140130142752.GX15937@n2100.arm.linux.org.uk> <20140130143208.GB9573@infradead.org> <20140130153812.GA15937@n2100.arm.linux.org.uk> <1391201970.6978.1.camel@leira.trondhjem.org> <20140201010328.GI15937@n2100.arm.linux.org.uk> <20140202122757.GC26684@n2100.arm.linux.org.uk> Organization: Primary Data X-Mailer: Evolution 3.10.3 (3.10.3-1.fc20) Mime-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20140202_170502_081834_014A10D1 X-CRM114-Status: GOOD ( 30.27 ) X-Spam-Score: -2.6 (--) Cc: linux-nfs@vger.kernel.org, linux-kernel@vger.kernel.org, Christoph Hellwig , Al Viro , Christoph Hellwig , linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.7 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP On Sun, 2014-02-02 at 12:27 +0000, Russell King - ARM Linux wrote: > On Sat, Feb 01, 2014 at 01:03:28AM +0000, Russell King - ARM Linux wrote: > > On Fri, Jan 31, 2014 at 03:59:30PM -0500, Trond Myklebust wrote: > > > On Thu, 2014-01-30 at 15:38 +0000, Russell King - ARM Linux wrote: > > > > On Thu, Jan 30, 2014 at 06:32:08AM -0800, Christoph Hellwig wrote: > > > > > On Thu, Jan 30, 2014 at 02:27:52PM +0000, Russell King - ARM Linux wrote: > > > > > > Yes and no. I still end up with an empty /etc/mtab, but the file now > > > > > > exists. However, I can create and echo data into /etc/mtab, but it seems > > > > > > that can't happen at boot time. > > > > > > > > > > Odd. Can you disable CONFIG_NFSD_V3_ACL for now to isolate the issue? > > > > > > > > Unfortunately, that results in some problem at boot time, which > > > > ultimately ends up with the other three CPUs being stopped, and > > > > hence the original reason scrolls off the screen before it can be > > > > read... even at 1920p. > > > > > > > Hi Russell, > > > > > > The following patch fixes the issue for me. > > > > It doesn't entirely fix the issue for me, instead we've got even weirder > > behaviour: > > > > root@cubox-i4:~# ls -al test > > ls: cannot access test: No such file or directory > > root@cubox-i4:~# touch test > > root@cubox-i4:~# ls -al test > > -rw-r--r-- 1 root root 0 Feb 1 01:01 test > > root@cubox-i4:~# echo foo > test > > root@cubox-i4:~# ls -al test > > -rw-r--r-- 1 root root 4 Feb 1 01:01 test > > root@cubox-i4:~# cat test > > foo > > root@cubox-i4:~# rm test > > root@cubox-i4:~# echo foo > test > > -bash: test: Operation not supported > > root@cubox-i4:~# ls -al test > > -rw-r--r-- 1 root root 0 Feb 1 01:01 test > > FYI, I just tested Linus' tip, and NFS is still broken. > Hi Russell, The following patch should fix the above problem. It needs to be applied on top of the one I sent you previously. In addition, you will want to apply Noah Massey's patch from http://lkml.kernel.org/r/1391135472-9639-1-git-send-email-Noah.Massey@gmail.com Cheers, Trond 8<------------------------------------------------------------------------------ From f9ad7a7b43554bc36eccf03d33617c05b8a2c77d Mon Sep 17 00:00:00 2001 From: Trond Myklebust Date: Sun, 2 Feb 2014 14:36:42 -0500 Subject: [PATCH] NFSv3: Fix return value of nfs3_proc_setacls nfs3_proc_setacls is used internally by the NFSv3 create operations to set the acl after the file has been created. If the operation fails because the server doesn't support acls, then it must return '0', not -EOPNOTSUPP. Signed-off-by: Trond Myklebust --- fs/nfs/nfs3acl.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/fs/nfs/nfs3acl.c b/fs/nfs/nfs3acl.c index 9271a6bb9a41..871d6eda8dba 100644 --- a/fs/nfs/nfs3acl.c +++ b/fs/nfs/nfs3acl.c @@ -113,7 +113,7 @@ getout: return ERR_PTR(status); } -int nfs3_proc_setacls(struct inode *inode, struct posix_acl *acl, +static int __nfs3_proc_setacls(struct inode *inode, struct posix_acl *acl, struct posix_acl *dfacl) { struct nfs_server *server = NFS_SERVER(inode); @@ -198,6 +198,15 @@ out: return status; } +int nfs3_proc_setacls(struct inode *inode, struct posix_acl *acl, + struct posix_acl *dfacl) +{ + int ret; + ret = __nfs3_proc_setacls(inode, acl, dfacl); + return (ret == -EOPNOTSUPP) ? 0 : ret; + +} + int nfs3_set_acl(struct inode *inode, struct posix_acl *acl, int type) { struct posix_acl *alloc = NULL, *dfacl = NULL; @@ -225,7 +234,7 @@ int nfs3_set_acl(struct inode *inode, struct posix_acl *acl, int type) if (IS_ERR(alloc)) goto fail; } - status = nfs3_proc_setacls(inode, acl, dfacl); + status = __nfs3_proc_setacls(inode, acl, dfacl); posix_acl_release(alloc); return status;