Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 211622
b: refs/heads/master
c: 9a3f236
h: refs/heads/master
v: v3
  • Loading branch information
Steven Whitehouse committed Sep 20, 2010
1 parent b4386bc commit 0d7b8ed
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 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: 820969f353587281d645735c83c7f07d606e67ba
refs/heads/master: 9a3f236d40a99ea8dca3df40d8ef67631057cad6
10 changes: 9 additions & 1 deletion trunk/fs/gfs2/rgrp.c
Original file line number Diff line number Diff line change
Expand Up @@ -1496,11 +1496,19 @@ int gfs2_alloc_block(struct gfs2_inode *ip, u64 *bn, unsigned int *n)
struct gfs2_sbd *sdp = GFS2_SB(&ip->i_inode);
struct buffer_head *dibh;
struct gfs2_alloc *al = ip->i_alloc;
struct gfs2_rgrpd *rgd = al->al_rgd;
struct gfs2_rgrpd *rgd;
u32 goal, blk;
u64 block;
int error;

/* Only happens if there is a bug in gfs2, return something distinctive
* to ensure that it is noticed.
*/
if (al == NULL)
return -ECANCELED;

rgd = al->al_rgd;

if (rgrp_contains_block(rgd, ip->i_goal))
goal = ip->i_goal - rgd->rd_data0;
else
Expand Down

0 comments on commit 0d7b8ed

Please sign in to comment.