cluster-devel.redhat.com archive mirror
 help / color / mirror / Atom feed
From: Steven Whitehouse <swhiteho@redhat.com>
To: cluster-devel.redhat.com
Subject: [Cluster-devel] [PATCH 1/4] GFS2: put glock reference in error patch of read_rindex_entry
Date: Wed, 11 Apr 2012 09:56:51 +0100	[thread overview]
Message-ID: <1334134614-19805-2-git-send-email-swhiteho@redhat.com> (raw)
In-Reply-To: <1334134614-19805-1-git-send-email-swhiteho@redhat.com>

From: Bob Peterson <rpeterso@redhat.com>

This patch fixes the error path of function read_rindex_entry
so that it correctly gives up its glock reference in cases where
there is a race to re-read the rindex after gfs2_grow.

Signed-off-by: Bob Peterson <rpeterso@redhat.com>
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>

diff --git a/fs/gfs2/rgrp.c b/fs/gfs2/rgrp.c
index 19bde40..19354a2 100644
--- a/fs/gfs2/rgrp.c
+++ b/fs/gfs2/rgrp.c
@@ -640,6 +640,7 @@ static int read_rindex_entry(struct gfs2_inode *ip,
 		return 0;
 
 	error = 0; /* someone else read in the rgrp; free it and ignore it */
+	gfs2_glock_put(rgd->rd_gl);
 
 fail:
 	kfree(rgd->rd_bits);
-- 
1.7.4



  reply	other threads:[~2012-04-11  8:56 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-11  8:56 [Cluster-devel] GFS2: Pre-pull patch posting (fixes) Steven Whitehouse
2012-04-11  8:56 ` Steven Whitehouse [this message]
2012-04-11  8:56 ` [Cluster-devel] [PATCH 2/4] GFS2: use depends instead of select in kconfig Steven Whitehouse
2012-04-11  8:56 ` [Cluster-devel] [PATCH 3/4] GFS2: Make sure rindex is uptodate before starting transactions Steven Whitehouse
2012-04-11  8:56 ` [Cluster-devel] [PATCH 4/4] GFS2: Allow caching of rindex glock Steven Whitehouse

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1334134614-19805-2-git-send-email-swhiteho@redhat.com \
    --to=swhiteho@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).