Btrfs: remove unneeded field / smaller extent_map structure
authorFilipe Manana <fdmanana@gmail.com>
Tue, 25 Feb 2014 14:15:12 +0000 (14:15 +0000)
committerJosef Bacik <jbacik@fb.com>
Mon, 10 Mar 2014 19:16:56 +0000 (15:16 -0400)
commitcbc0e9287d710ce7dce5f8daf667729e83316c45
treeabd3c0c847c07464186b86afb9cea66473f024ed
parente84752d434b5cca0869e906e7b94d0531b25c6d3
Btrfs: remove unneeded field / smaller extent_map structure

We don't need to have an unsigned int field in the extent_map struct
to tell us whether the extent map is in the inode's extent_map tree or
not. We can use the rb_node struct field and the RB_CLEAR_NODE and
RB_EMPTY_NODE macros to achieve the same task.

This reduces sizeof(struct extent_map) from 152 bytes to 144 bytes (on a
64 bits system).

Signed-off-by: Filipe David Borba Manana <fdmanana@gmail.com>
Reviewed-by: David Sterba <dsterba@suse.cz>
Signed-off-by: Josef Bacik <jbacik@fb.com>
fs/btrfs/extent_io.c
fs/btrfs/extent_map.c
fs/btrfs/extent_map.h