diff options
author | Eric Sandeen <sandeen@redhat.com> | 2012-11-08 11:22:46 -0500 |
---|---|---|
committer | Theodore Ts'o <tytso@mit.edu> | 2012-11-08 11:22:46 -0500 |
commit | 37be2f59d3149b95afaeeeff94edde2c07f165d2 (patch) | |
tree | e24a689476b15f3d39aa71026e8db67a8b57b545 /fs/ext4/resize.c | |
parent | 6d138ced751d4e41e02c38ad55d1b3cd2913b150 (diff) |
ext4: remove ext4_handle_release_buffer()
ext4_handle_release_buffer() was intended to remove journal
write access from a buffer, but it doesn't actually do anything
at all other than add a BUFFER_TRACE point, but it's not reliably
used for that either. Remove all the associated dead code.
Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Reviewed-by: Carlos Maiolino <cmaiolino@redhat.com>
Diffstat (limited to 'fs/ext4/resize.c')
-rw-r--r-- | fs/ext4/resize.c | 17 |
1 files changed, 3 insertions, 14 deletions
diff --git a/fs/ext4/resize.c b/fs/ext4/resize.c index 47bf06a2765d..d99387b89edd 100644 --- a/fs/ext4/resize.c +++ b/fs/ext4/resize.c | |||
@@ -783,7 +783,7 @@ static int add_new_gdb(handle_t *handle, struct inode *inode, | |||
783 | 783 | ||
784 | err = ext4_journal_get_write_access(handle, gdb_bh); | 784 | err = ext4_journal_get_write_access(handle, gdb_bh); |
785 | if (unlikely(err)) | 785 | if (unlikely(err)) |
786 | goto exit_sbh; | 786 | goto exit_dind; |
787 | 787 | ||
788 | err = ext4_journal_get_write_access(handle, dind); | 788 | err = ext4_journal_get_write_access(handle, dind); |
789 | if (unlikely(err)) | 789 | if (unlikely(err)) |
@@ -792,7 +792,7 @@ static int add_new_gdb(handle_t *handle, struct inode *inode, | |||
792 | /* ext4_reserve_inode_write() gets a reference on the iloc */ | 792 | /* ext4_reserve_inode_write() gets a reference on the iloc */ |
793 | err = ext4_reserve_inode_write(handle, inode, &iloc); | 793 | err = ext4_reserve_inode_write(handle, inode, &iloc); |
794 | if (unlikely(err)) | 794 | if (unlikely(err)) |
795 | goto exit_dindj; | 795 | goto exit_dind; |
796 | 796 | ||
797 | n_group_desc = ext4_kvmalloc((gdb_num + 1) * | 797 | n_group_desc = ext4_kvmalloc((gdb_num + 1) * |
798 | sizeof(struct buffer_head *), | 798 | sizeof(struct buffer_head *), |
@@ -846,12 +846,7 @@ static int add_new_gdb(handle_t *handle, struct inode *inode, | |||
846 | 846 | ||
847 | exit_inode: | 847 | exit_inode: |
848 | ext4_kvfree(n_group_desc); | 848 | ext4_kvfree(n_group_desc); |
849 | /* ext4_handle_release_buffer(handle, iloc.bh); */ | ||
850 | brelse(iloc.bh); | 849 | brelse(iloc.bh); |
851 | exit_dindj: | ||
852 | /* ext4_handle_release_buffer(handle, dind); */ | ||
853 | exit_sbh: | ||
854 | /* ext4_handle_release_buffer(handle, EXT4_SB(sb)->s_sbh); */ | ||
855 | exit_dind: | 850 | exit_dind: |
856 | brelse(dind); | 851 | brelse(dind); |
857 | exit_bh: | 852 | exit_bh: |
@@ -969,14 +964,8 @@ static int reserve_backup_gdb(handle_t *handle, struct inode *inode, | |||
969 | } | 964 | } |
970 | 965 | ||
971 | for (i = 0; i < reserved_gdb; i++) { | 966 | for (i = 0; i < reserved_gdb; i++) { |
972 | if ((err = ext4_journal_get_write_access(handle, primary[i]))) { | 967 | if ((err = ext4_journal_get_write_access(handle, primary[i]))) |
973 | /* | ||
974 | int j; | ||
975 | for (j = 0; j < i; j++) | ||
976 | ext4_handle_release_buffer(handle, primary[j]); | ||
977 | */ | ||
978 | goto exit_bh; | 968 | goto exit_bh; |
979 | } | ||
980 | } | 969 | } |
981 | 970 | ||
982 | if ((err = ext4_reserve_inode_write(handle, inode, &iloc))) | 971 | if ((err = ext4_reserve_inode_write(handle, inode, &iloc))) |