Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 280333
b: refs/heads/master
c: c688b8b
h: refs/heads/master
i:
  280331: 32ddcbb
v: v3
  • Loading branch information
Bob Peterson authored and Steven Whitehouse committed Nov 15, 2011
1 parent 967ce8e commit eed940b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 79c4c379c8f16a12c28ea2084db5138e33d17ebd
refs/heads/master: c688b8b334d20acbc79b0383af2816ecf7365741
8 changes: 5 additions & 3 deletions trunk/fs/gfs2/rgrp.c
Original file line number Diff line number Diff line change
Expand Up @@ -978,7 +978,7 @@ static int get_local_rgrp(struct gfs2_inode *ip, u64 *last_unlinked)
struct gfs2_sbd *sdp = GFS2_SB(&ip->i_inode);
struct gfs2_rgrpd *rgd, *begin = NULL;
struct gfs2_alloc *al = ip->i_alloc;
int error, rg_locked;
int error, rg_locked, flags = LM_FLAG_TRY;
int loops = 0;

if (ip->i_rgd && rgrp_contains_block(ip->i_rgd, ip->i_goal))
Expand All @@ -997,7 +997,7 @@ static int get_local_rgrp(struct gfs2_inode *ip, u64 *last_unlinked)
error = 0;
} else {
error = gfs2_glock_nq_init(rgd->rd_gl, LM_ST_EXCLUSIVE,
LM_FLAG_TRY, &al->al_rgd_gh);
flags, &al->al_rgd_gh);
}
switch (error) {
case 0:
Expand All @@ -1012,8 +1012,10 @@ static int get_local_rgrp(struct gfs2_inode *ip, u64 *last_unlinked)
/* fall through */
case GLR_TRYFAILED:
rgd = gfs2_rgrpd_get_next(rgd);
if (rgd == begin)
if (rgd == begin) {
flags = 0;
loops++;
}
break;
default:
return error;
Expand Down

0 comments on commit eed940b

Please sign in to comment.