From patchwork Sat Mar 13 14:39:39 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Eric Van Hensbergen X-Patchwork-Id: 85734 X-Patchwork-Delegate: ericvh@gmail.com Received: from lists.sourceforge.net (lists.sourceforge.net [216.34.181.88]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o2DEe58j005003 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Sat, 13 Mar 2010 14:40:41 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.69) (envelope-from ) id 1NqSVI-0004oz-3h; Sat, 13 Mar 2010 14:39:48 +0000 Received: from sfi-mx-2.v28.ch3.sourceforge.com ([172.29.28.122] helo=mx.sourceforge.net) by sfs-ml-3.v29.ch3.sourceforge.com with esmtp (Exim 4.69) (envelope-from ) id 1NqSVH-0004ou-C5 for v9fs-developer@lists.sourceforge.net; Sat, 13 Mar 2010 14:39:47 +0000 Received-SPF: pass (sfi-mx-2.v28.ch3.sourceforge.com: domain of gmail.com designates 74.125.82.47 as permitted sender) client-ip=74.125.82.47; envelope-from=ericvh@gmail.com; helo=mail-ww0-f47.google.com; Received: from mail-ww0-f47.google.com ([74.125.82.47]) by sfi-mx-2.v28.ch3.sourceforge.com with esmtp (Exim 4.69) id 1NqSVG-0005tp-9B for v9fs-developer@lists.sourceforge.net; Sat, 13 Mar 2010 14:39:47 +0000 Received: by wwg30 with SMTP id 30so1260931wwg.34 for ; Sat, 13 Mar 2010 06:39:40 -0800 (PST) MIME-Version: 1.0 Received: by 10.216.90.208 with SMTP id e58mr1614430wef.57.1268491179859; Sat, 13 Mar 2010 06:39:39 -0800 (PST) In-Reply-To: <1691295304.288201268330013229.JavaMail.root@zmail06.collab.prod.int.phx2.redhat.com> References: <129079056.288181268330011583.JavaMail.root@zmail06.collab.prod.int.phx2.redhat.com> <1691295304.288201268330013229.JavaMail.root@zmail06.collab.prod.int.phx2.redhat.com> Date: Sat, 13 Mar 2010 08:39:39 -0600 Message-ID: From: Eric Van Hensbergen To: V9FS Developers X-Spam-Score: -1.1 (-) X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. -1.5 SPF_CHECK_PASS SPF reports sender host as permitted sender for sender-domain -0.0 SPF_PASS SPF: sender matches SPF record -0.0 DKIM_VERIFIED Domain Keys Identified Mail: signature passes verification 0.0 DKIM_SIGNED Domain Keys Identified Mail: message has a signature 0.4 AWL AWL: From: address is in the auto white-list X-Headers-End: 1NqSVG-0005tp-9B Subject: [V9fs-developer] Fwd: [PATCH] v9fs: Skip check for mandatory locks when unlocking 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.3 (demeter.kernel.org [140.211.167.41]); Sat, 13 Mar 2010 14:40:44 +0000 (UTC) diff -up linux-2.6/fs/9p/vfs_file.c.9p linux-2.6/fs/9p/vfs_file.c --- linux-2.6/fs/9p/vfs_file.c.9p       2010-03-11 17:32:52.000000000 +0000 +++ linux-2.6/fs/9p/vfs_file.c  2010-03-11 17:33:11.000000000 +0000 @@ -114,7 +114,7 @@ static int v9fs_file_lock(struct file *f        P9_DPRINTK(P9_DEBUG_VFS, "filp: %p lock: %p\n", filp, fl);        /* No mandatory locks */ -       if (__mandatory_lock(inode)) +       if (__mandatory_lock(inode) && fl->fl_type != F_UNLCK)                return -ENOLCK;        if ((IS_SETLK(cmd) || IS_SETLKW(cmd)) && fl->fl_type != F_UNLCK) {