aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ext4/inode.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/ext4/inode.c')
-rw-r--r--fs/ext4/inode.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c
index a06a3b7cfc34..bb717cbb749c 100644
--- a/fs/ext4/inode.c
+++ b/fs/ext4/inode.c
@@ -551,7 +551,7 @@ static int ext4_alloc_blocks(handle_t *handle, struct inode *inode,
551 return ret; 551 return ret;
552failed_out: 552failed_out:
553 for (i = 0; i <index; i++) 553 for (i = 0; i <index; i++)
554 ext4_free_blocks(handle, inode, new_blocks[i], 1); 554 ext4_free_blocks(handle, inode, new_blocks[i], 1, 0);
555 return ret; 555 return ret;
556} 556}
557 557
@@ -650,9 +650,9 @@ failed:
650 ext4_journal_forget(handle, branch[i].bh); 650 ext4_journal_forget(handle, branch[i].bh);
651 } 651 }
652 for (i = 0; i <indirect_blks; i++) 652 for (i = 0; i <indirect_blks; i++)
653 ext4_free_blocks(handle, inode, new_blocks[i], 1); 653 ext4_free_blocks(handle, inode, new_blocks[i], 1, 0);
654 654
655 ext4_free_blocks(handle, inode, new_blocks[i], num); 655 ext4_free_blocks(handle, inode, new_blocks[i], num, 0);
656 656
657 return err; 657 return err;
658} 658}
@@ -749,9 +749,10 @@ err_out:
749 for (i = 1; i <= num; i++) { 749 for (i = 1; i <= num; i++) {
750 BUFFER_TRACE(where[i].bh, "call jbd2_journal_forget"); 750 BUFFER_TRACE(where[i].bh, "call jbd2_journal_forget");
751 ext4_journal_forget(handle, where[i].bh); 751 ext4_journal_forget(handle, where[i].bh);
752 ext4_free_blocks(handle,inode,le32_to_cpu(where[i-1].key),1); 752 ext4_free_blocks(handle, inode,
753 le32_to_cpu(where[i-1].key), 1, 0);
753 } 754 }
754 ext4_free_blocks(handle, inode, le32_to_cpu(where[num].key), blks); 755 ext4_free_blocks(handle, inode, le32_to_cpu(where[num].key), blks, 0);
755 756
756 return err; 757 return err;
757} 758}
@@ -2052,7 +2053,7 @@ static void ext4_clear_blocks(handle_t *handle, struct inode *inode,
2052 } 2053 }
2053 } 2054 }
2054 2055
2055 ext4_free_blocks(handle, inode, block_to_free, count); 2056 ext4_free_blocks(handle, inode, block_to_free, count, 0);
2056} 2057}
2057 2058
2058/** 2059/**
@@ -2225,7 +2226,7 @@ static void ext4_free_branches(handle_t *handle, struct inode *inode,
2225 ext4_journal_test_restart(handle, inode); 2226 ext4_journal_test_restart(handle, inode);
2226 } 2227 }
2227 2228
2228 ext4_free_blocks(handle, inode, nr, 1); 2229 ext4_free_blocks(handle, inode, nr, 1, 1);
2229 2230
2230 if (parent_bh) { 2231 if (parent_bh) {
2231 /* 2232 /*