ext4: simplify mpage_add_bh_to_extent()
authorJan Kara <jack@suse.cz>
Mon, 28 Jan 2013 18:06:48 +0000 (13:06 -0500)
committerTheodore Ts'o <tytso@mit.edu>
Mon, 28 Jan 2013 18:06:48 +0000 (13:06 -0500)
commitb6a8e62f8b0aec7607c947ba0d37d30fef65440f
tree8227ba01c4f38e032aeb1b8c3c4a45d9e171643a
parentf8bec37037aceb126d695c021cf4dc93b7238d47
ext4: simplify mpage_add_bh_to_extent()

The argument b_size of mpage_add_bh_to_extent() was bogus since it was
always == blocksize (which we can easily derive from inode->i_blkbits).
Also second branch of condition:
if (nrblocks >= EXT4_MAX_TRANS_DATA) {
} else if ((nrblocks + (b_size >> mpd->inode->i_blkbits)) >
EXT4_MAX_TRANS_DATA) {
}
was never taken because (b_size >> mpd->inode->i_blkbits) == 1.

Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
fs/ext4/inode.c