summaryrefslogtreecommitdiffstats
path: root/fs/gfs2/bmap.c
diff options
context:
space:
mode:
authorSteven Whitehouse <swhiteho@redhat.com>2011-08-31 16:38:29 +0100
committerSteven Whitehouse <swhiteho@redhat.com>2011-10-21 12:39:33 +0100
commit8339ee543ece6e2dcc1bbd97d5350163c198cf00 (patch)
tree80b3d4b990a8ab5f8b7c28945f694b01301c05c6 /fs/gfs2/bmap.c
parent7c9ca621137cde26be05448133fc1a554345f4f8 (diff)
downloadlinux-8339ee543ece6e2dcc1bbd97d5350163c198cf00.tar.gz
linux-8339ee543ece6e2dcc1bbd97d5350163c198cf00.tar.bz2
linux-8339ee543ece6e2dcc1bbd97d5350163c198cf00.zip
GFS2: Make resource groups "append only" during life of fs
Since we have ruled out supporting online filesystem shrink, it is possible to make the resource group list append only during the life of a super block. This gives several benefits: Firstly, we only need to read new rindex elements as they are added rather than needing to reread the whole rindex file each time one element is added. Secondly, the rindex glock can be held for much shorter periods of time, and is completely removed from the fast path for allocations. The lock is taken in shared mode only when updating the resource groups when the first allocation occurs, and after a grow has taken place. Thirdly, this results in a reduction in code size, and everything gets a lot simpler to understand in this area. Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
Diffstat (limited to 'fs/gfs2/bmap.c')
-rw-r--r--fs/gfs2/bmap.c7
1 files changed, 0 insertions, 7 deletions
diff --git a/fs/gfs2/bmap.c b/fs/gfs2/bmap.c
index 7878c473ae62..e60296137707 100644
--- a/fs/gfs2/bmap.c
+++ b/fs/gfs2/bmap.c
@@ -783,11 +783,6 @@ static int do_strip(struct gfs2_inode *ip, struct buffer_head *dibh,
else if (ip->i_depth)
revokes = sdp->sd_inptrs;
- if (ip != GFS2_I(sdp->sd_rindex))
- error = gfs2_rindex_hold(sdp, &ip->i_alloc->al_ri_gh);
- else if (!sdp->sd_rgrps)
- error = gfs2_ri_update(ip);
-
if (error)
return error;
@@ -887,8 +882,6 @@ out_rg_gunlock:
out_rlist:
gfs2_rlist_free(&rlist);
out:
- if (ip != GFS2_I(sdp->sd_rindex))
- gfs2_glock_dq_uninit(&ip->i_alloc->al_ri_gh);
return error;
}