From patchwork Mon Mar 28 05:03:51 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ryan Mallon X-Patchwork-Id: 667291 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p2S53vp1008474 for ; Mon, 28 Mar 2011 05:03:57 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751938Ab1C1FDx (ORCPT ); Mon, 28 Mar 2011 01:03:53 -0400 Received: from mail.bluewatersys.com ([202.124.120.130]:45037 "EHLO hayes.bluewaternz.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1750788Ab1C1FDj (ORCPT ); Mon, 28 Mar 2011 01:03:39 -0400 Received: (qmail 22258 invoked by uid 89); 28 Mar 2011 05:04:00 -0000 Received: from unknown (HELO ?192.168.2.96?) (ryan@192.168.2.96) by 0 with ESMTPA; 28 Mar 2011 05:04:00 -0000 Message-ID: <4D9016B7.1080505@bluewatersys.com> Date: Mon, 28 Mar 2011 18:03:51 +1300 From: Ryan Mallon User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.13) Gecko/20101208 Lightning/1.0b2 Thunderbird/3.1.7 MIME-Version: 1.0 To: Dave Chinner , sage@newdream.net CC: viro@zeniv.linux.org.uk, dchinner@redhat.com, Trond.Myklebust@netapp.com, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, linux-nfs@vger.kernel.org, ceph-devel@vger.kernel.org Subject: Re: [RFC PATCH 0/2] Introduce unlocked version of igrab References: <1301277361-9453-1-git-send-email-ryan@bluewatersys.com> <20110328044334.GA1022@dastard> <4D9012C5.8070401@bluewatersys.com> In-Reply-To: <4D9012C5.8070401@bluewatersys.com> X-Enigmail-Version: 1.1.2 Sender: linux-nfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Mon, 28 Mar 2011 05:03:58 +0000 (UTC) diff --git a/fs/ceph/addr.c b/fs/ceph/addr.c index 561438b..37368ba 100644 --- a/fs/ceph/addr.c +++ b/fs/ceph/addr.c @@ -92,7 +92,7 @@ static int ceph_set_page_dirty(struct page *page) ci->i_head_snapc = ceph_get_snap_context(snapc); ++ci->i_wrbuffer_ref_head; if (ci->i_wrbuffer_ref == 0) - igrab(inode); + ihold(inode); ++ci->i_wrbuffer_ref; dout("%p set_page_dirty %p idx %lu head %d/%d -> %d/%d " "snapc %p seq %lld (%d snaps)\n", diff --git a/fs/ceph/snap.c b/fs/ceph/snap.c index f40b913..03afa8e 100644 --- a/fs/ceph/snap.c +++ b/fs/ceph/snap.c @@ -463,7 +463,7 @@ void ceph_queue_cap_snap(struct ceph_inode_info *ci) dout("queue_cap_snap %p cap_snap %p queuing under %p\n", inode, capsnap, snapc); - igrab(inode); + ihold(inode); atomic_set(&capsnap->nref, 1); capsnap->ci = ci;