From: "Aneesh Kumar K.V" Subject: Re: [PATCH 1/4] 9p: do no return 0 from ->check_acl without actually checking Date: Mon, 25 Jul 2011 12:10:54 +0530 Message-ID: <87wrf6g8w9.fsf@skywalker.in.ibm.com> References: <20110723153621.GA10832@lst.de> <20110723153638.GA10887@lst.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: linux-fsdevel To: Christoph Hellwig , Al Viro , Linus Torvalds Return-path: Received: from e39.co.us.ibm.com ([32.97.110.160]:52437 "EHLO e39.co.us.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750987Ab1GYGlE (ORCPT ); Mon, 25 Jul 2011 02:41:04 -0400 Received: from d03relay02.boulder.ibm.com (d03relay02.boulder.ibm.com [9.17.195.227]) by e39.co.us.ibm.com (8.14.4/8.13.1) with ESMTP id p6P6QDKw006746 for ; Mon, 25 Jul 2011 00:26:13 -0600 Received: from d03av02.boulder.ibm.com (d03av02.boulder.ibm.com [9.17.195.168]) by d03relay02.boulder.ibm.com (8.13.8/8.13.8/NCO v9.1) with ESMTP id p6P6f1dI198934 for ; Mon, 25 Jul 2011 00:41:01 -0600 Received: from d03av02.boulder.ibm.com (loopback [127.0.0.1]) by d03av02.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id p6P0eYSg006971 for ; Sun, 24 Jul 2011 18:40:34 -0600 In-Reply-To: <20110723153638.GA10887@lst.de> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Sat, 23 Jul 2011 17:36:38 +0200, Christoph Hellwig wrote: > If we do not want to use ACLs we at least need to perform normal Unix > permission checks. From the comment I'm not quite sure that's what > is intended, but if 0p wants to do permission checks entirely on the > server it needs to do so in ->permission, not in ->check_acl. > > Signed-off-by: Christoph Hellwig > > Index: linux-2.6/fs/9p/acl.c > =================================================================== > --- linux-2.6.orig/fs/9p/acl.c 2011-07-23 16:39:19.200749795 +0200 > +++ linux-2.6/fs/9p/acl.c 2011-07-23 16:39:24.690749763 +0200 > @@ -108,7 +108,7 @@ int v9fs_check_acl(struct inode *inode, > * On access = client and acl = on mode get the acl > * values from the server > */ > - return 0; > + return -EAGAIN; > } > acl = v9fs_get_cached_acl(inode, ACL_TYPE_ACCESS); > Acked-by: Aneesh Kumar K.V -aneesh