Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 101088
b: refs/heads/master
c: 363d425
h: refs/heads/master
v: v3
  • Loading branch information
Shen Feng authored and Theodore Ts'o committed Jul 11, 2008
1 parent 0a98680 commit aeab443
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 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: f9a8ac99fd79eb961a8573ccf058439bc17b4d3a
refs/heads/master: 363d4251d4bd984c304e0989789f6494343660fd
10 changes: 6 additions & 4 deletions trunk/fs/ext4/mballoc.c
Original file line number Diff line number Diff line change
Expand Up @@ -4058,16 +4058,17 @@ ext4_fsblk_t ext4_mb_new_blocks(handle_t *handle,

ac = kmem_cache_alloc(ext4_ac_cachep, GFP_NOFS);
if (!ac) {
ar->len = 0;
*errp = -ENOMEM;
return 0;
goto out1;
}

ext4_mb_poll_new_transaction(sb, handle);

*errp = ext4_mb_initialize_context(ac, ar);
if (*errp) {
ar->len = 0;
goto out;
goto out2;
}

ac->ac_op = EXT4_MB_HISTORY_PREALLOC;
Expand Down Expand Up @@ -4115,11 +4116,12 @@ ext4_fsblk_t ext4_mb_new_blocks(handle_t *handle,

ext4_mb_release_context(ac);

out:
out2:
kmem_cache_free(ext4_ac_cachep, ac);
out1:
if (ar->len < inquota)
DQUOT_FREE_BLOCK(ar->inode, inquota - ar->len);

kmem_cache_free(ext4_ac_cachep, ac);
return block;
}
static void ext4_mb_poll_new_transaction(struct super_block *sb,
Expand Down

0 comments on commit aeab443

Please sign in to comment.