From patchwork Tue Jun 14 06:59:12 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Aneesh Kumar K.V" X-Patchwork-Id: 877982 X-Patchwork-Delegate: ericvh@gmail.com Received: from lists.sourceforge.net (lists.sourceforge.net [216.34.181.88]) by demeter1.kernel.org (8.14.4/8.14.4) with ESMTP id p5E703IU014950 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Tue, 14 Jun 2011 07:00:29 GMT Received: from localhost ([127.0.0.1] helo=sfs-ml-3.v29.ch3.sourceforge.com) by sfs-ml-3.v29.ch3.sourceforge.com with esmtp (Exim 4.76) (envelope-from ) id 1QWNb5-0003EF-Hy; Tue, 14 Jun 2011 06:59:35 +0000 Received: from sog-mx-4.v43.ch3.sourceforge.com ([172.29.43.194] helo=mx.sourceforge.net) by sfs-ml-3.v29.ch3.sourceforge.com with esmtp (Exim 4.76) (envelope-from ) id 1QWNb4-0003E6-Ft for v9fs-developer@lists.sourceforge.net; Tue, 14 Jun 2011 06:59:34 +0000 X-ACL-Warn: Received: from e35.co.us.ibm.com ([32.97.110.153]) by sog-mx-4.v43.ch3.sourceforge.com with esmtps (TLSv1:AES256-SHA:256) (Exim 4.76) id 1QWNb3-0006Hm-Jy for v9fs-developer@lists.sourceforge.net; Tue, 14 Jun 2011 06:59:34 +0000 Received: from d03relay05.boulder.ibm.com (d03relay05.boulder.ibm.com [9.17.195.107]) by e35.co.us.ibm.com (8.14.4/8.13.1) with ESMTP id p5E6fX90006276 for ; Tue, 14 Jun 2011 00:41:33 -0600 Received: from d03av02.boulder.ibm.com (d03av02.boulder.ibm.com [9.17.195.168]) by d03relay05.boulder.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id p5E6xMt9316026 for ; Tue, 14 Jun 2011 00:59:22 -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 p5E0wsVo025176 for ; Mon, 13 Jun 2011 18:58:54 -0600 Received: from skywalker.linux.vnet.ibm.com ([9.79.198.180]) by d03av02.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVin) with ESMTP id p5E0wlRc024619; Mon, 13 Jun 2011 18:58:50 -0600 From: "Aneesh Kumar K.V" To: Eric Van Hensbergen In-Reply-To: References: <1307383308-5773-1-git-send-email-aneesh.kumar@linux.vnet.ibm.com> <1307383308-5773-3-git-send-email-aneesh.kumar@linux.vnet.ibm.com> User-Agent: Notmuch/0.5-215-g5143e5e (http://notmuchmail.org) Emacs/23.2.1 (i686-pc-linux-gnu) Date: Tue, 14 Jun 2011 12:29:12 +0530 Message-ID: <87oc20ew5b.fsf@linux.vnet.ibm.com> MIME-Version: 1.0 X-Spam-Score: 0.9 (/) X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. -0.0 T_RP_MATCHES_RCVD Envelope sender domain matches handover relay domain 0.9 AWL AWL: From: address is in the auto white-list X-Headers-End: 1QWNb3-0006Hm-Jy Cc: linux-fsdevel@vger.kernel.org, v9fs-developer@lists.sourceforge.net, linux-kernel@vger.kernel.org Subject: Re: [V9fs-developer] [PATCH 3/3] 9p: add 9P2000.L unlinkat operation X-BeenThere: v9fs-developer@lists.sourceforge.net X-Mailman-Version: 2.1.9 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: v9fs-developer-bounces@lists.sourceforge.net X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Tue, 14 Jun 2011 07:00:29 +0000 (UTC) On Mon, 13 Jun 2011 16:12:52 -0500, Eric Van Hensbergen wrote: > Could be wrong, but a quick regression check of your patches fails > against a legacy server. Are you making sure the new operations are > properly protected by a .L flag? How about below diff [3.0-pending@v9fs]$ git diff related to renameat i have updated to check for -EOPNOTSUPP instead of -ENOSYS. I am not sure any other dotl server out there is returning -ENOSYS. We haven't documented what the server should return in case it doesn't support any specific operation. -aneesh ------------------------------------------------------------------------------ EditLive Enterprise is the world's most technically advanced content authoring tool. Experience the power of Track Changes, Inline Image Editing and ensure content is compliant with Accessibility Checking. http://p.sf.net/sfu/ephox-dev2dev diff --git a/fs/9p/vfs_inode.c b/fs/9p/vfs_inode.c index f40fdc3..436699e 100644 --- a/fs/9p/vfs_inode.c +++ b/fs/9p/vfs_inode.c @@ -499,13 +499,15 @@ v9fs_inode_from_fid(struct v9fs_session_info *v9ses, struct p9_fid *fid, static int v9fs_remove(struct inode *dir, struct dentry *dentry, int flags) { - int retval; struct inode *inode; + int retval = -EOPNOTSUPP; struct p9_fid *v9fid, *dfid; + struct v9fs_session_info *v9ses; P9_DPRINTK(P9_DEBUG_VFS, "inode: %p dentry: %p rmdir: %x\n", dir, dentry, flags); + v9ses = v9fs_inode2v9ses(dir); inode = dentry->d_inode; dfid = v9fs_fid_lookup(dentry->d_parent); if (IS_ERR(dfid)) { @@ -513,7 +515,8 @@ static int v9fs_remove(struct inode *dir, struct dentry *dentry, int flags) P9_DPRINTK(P9_DEBUG_VFS, "fid lookup failed %d\n", retval); return retval; } - retval = p9_client_unlinkat(dfid, dentry->d_name.name, flags); + if (v9fs_proto_dotl(v9ses)) + retval = p9_client_unlinkat(dfid, dentry->d_name.name, flags); if (retval == -EOPNOTSUPP) { /* Try the one based on path */ v9fid = v9fs_fid_clone(dentry);