summaryrefslogtreecommitdiff
path: root/fs/ext4/extents.c
diff options
context:
space:
mode:
authorJan Kara <jack@suse.cz>2009-06-09 00:17:05 -0400
committerTheodore Ts'o <tytso@mit.edu>2009-06-09 00:17:05 -0400
commit03f5d8bcf094a5e3b501bd2ae1553656efa8d1be (patch)
tree04644e9008e7357fd87f14fee6404b7c306bc3e9 /fs/ext4/extents.c
parent0b8e58a140cae2ba1c4a21ccae7c6c3c939c51f9 (diff)
downloadlinux-rpi-03f5d8bcf094a5e3b501bd2ae1553656efa8d1be.tar.gz
linux-rpi-03f5d8bcf094a5e3b501bd2ae1553656efa8d1be.tar.bz2
linux-rpi-03f5d8bcf094a5e3b501bd2ae1553656efa8d1be.zip
ext4: Get rid of EXTEND_DISKSIZE flag of ext4_get_blocks_handle()
Get rid of EXTEND_DISKSIZE flag of ext4_get_blocks_handle(). This seems to be a relict from some old days and setting disksize in this function does not make much sense. Currently it was set only by ext4_getblk(). Since the parameter has some effect only if create == 1, it is easy to check by grepping through the sources that the three callers which end up calling ext4_getblk() with create == 1 (ext4_append, ext4_quota_write, ext4_mkdir) do the right thing and set disksize themselves. Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Diffstat (limited to 'fs/ext4/extents.c')
-rw-r--r--fs/ext4/extents.c9
1 files changed, 0 insertions, 9 deletions
diff --git a/fs/ext4/extents.c b/fs/ext4/extents.c
index d4e99e96fddb..9c35a7b1f0ae 100644
--- a/fs/ext4/extents.c
+++ b/fs/ext4/extents.c
@@ -2779,7 +2779,6 @@ int ext4_ext_get_blocks(handle_t *handle, struct inode *inode,
int err = 0, depth, ret, cache_type;
unsigned int allocated = 0;
struct ext4_allocation_request ar;
- loff_t disksize;
__clear_bit(BH_New, &bh_result->b_state);
ext_debug("blocks %u/%u requested for inode %u\n",
@@ -2969,14 +2968,6 @@ int ext4_ext_get_blocks(handle_t *handle, struct inode *inode,
newblock = ext_pblock(&newex);
allocated = ext4_ext_get_actual_len(&newex);
outnew:
- if (flags & EXT4_GET_BLOCKS_EXTEND_DISKSIZE) {
- disksize = ((loff_t) iblock + ar.len) << inode->i_blkbits;
- if (disksize > i_size_read(inode))
- disksize = i_size_read(inode);
- if (disksize > EXT4_I(inode)->i_disksize)
- EXT4_I(inode)->i_disksize = disksize;
- }
-
set_buffer_new(bh_result);
/* Cache only when it is _not_ an uninitialized extent */