summaryrefslogtreecommitdiffstats
path: root/fs/ext4/ext4_extents.h
diff options
context:
space:
mode:
authorTheodore Ts'o <tytso@mit.edu>2011-01-10 12:13:26 -0500
committerTheodore Ts'o <tytso@mit.edu>2011-01-10 12:13:26 -0500
commitb05e6ae58a13b56e3e11882c1fc71948c9b29760 (patch)
tree452cbadcbc8091b4db95f917f28b0f9de845dabf /fs/ext4/ext4_extents.h
parent01f49d0b9d0209dc1194255b11601e4b94447b36 (diff)
downloadblackbird-op-linux-b05e6ae58a13b56e3e11882c1fc71948c9b29760.tar.gz
blackbird-op-linux-b05e6ae58a13b56e3e11882c1fc71948c9b29760.zip
ext4: drop ec_type from the ext4_ext_cache structure
We can encode the ec_type information by using ee_len == 0 to denote EXT4_EXT_CACHE_NO, ee_start == 0 to denote EXT4_EXT_CACHE_GAP, and if neither is true, then the cache type must be EXT4_EXT_CACHE_EXTENT. This allows us to reduce the size of ext4_ext_inode by another 8 bytes. (ec_type is 4 bytes, plus another 4 bytes of padding) Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Diffstat (limited to 'fs/ext4/ext4_extents.h')
-rw-r--r--fs/ext4/ext4_extents.h6
1 files changed, 1 insertions, 5 deletions
diff --git a/fs/ext4/ext4_extents.h b/fs/ext4/ext4_extents.h
index dfdda1766927..2e29abb30f76 100644
--- a/fs/ext4/ext4_extents.h
+++ b/fs/ext4/ext4_extents.h
@@ -119,10 +119,6 @@ struct ext4_ext_path {
* structure for external API
*/
-#define EXT4_EXT_CACHE_NO 0
-#define EXT4_EXT_CACHE_GAP 1
-#define EXT4_EXT_CACHE_EXTENT 2
-
/*
* to be called by ext4_ext_walk_space()
* negative retcode - error
@@ -197,7 +193,7 @@ static inline unsigned short ext_depth(struct inode *inode)
static inline void
ext4_ext_invalidate_cache(struct inode *inode)
{
- EXT4_I(inode)->i_cached_extent.ec_type = EXT4_EXT_CACHE_NO;
+ EXT4_I(inode)->i_cached_extent.ec_len = 0;
}
static inline void ext4_ext_mark_uninitialized(struct ext4_extent *ext)
OpenPOWER on IntegriCloud