summaryrefslogtreecommitdiff
path: root/include/linux/ext3_fs_i.h
diff options
context:
space:
mode:
authorMingming Cao <cmm@us.ibm.com>2005-04-03 17:39:16 -0700
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-03 17:39:16 -0700
commit1f374d8cc10fd9932359bf5928ed04bdbeca97b1 (patch)
tree4d2dd97da5af8989d150f76a98fff2e3203945bb /include/linux/ext3_fs_i.h
parentd0091e60a7e122b3e70658bf6e1148a389f71e90 (diff)
[PATCH] ext3: dynamic allocation of block reservation info
Right now the ext3 reservation structure(ext3_reserve_window_node) is part of the ext3 inode itself. This part of information is only needed for files that need allocate blocks on disk. So, the attached patches reduce the ext3 inode size by dynamically allocating the block allocation/reservation info structure(called struct ext3_block_alloc_info) when it is needed(i.e. only for files who need to allocate blocks) The reservation structure is being allocated and linked to the ext3 inode at ext3_get_block_handle(), and being freed and unlinked at the iput_final->ext3_clear_inode(). The ei->truncate_sem which is currently used to protect concurrent ext3_get_block() and ext3_truncate is used to protect reservation structure allocation and deallocation. Signed-off-by: Mingming Cao <cmm@us.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'include/linux/ext3_fs_i.h')
-rw-r--r--include/linux/ext3_fs_i.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/ext3_fs_i.h b/include/linux/ext3_fs_i.h
index 5e781aaff404..f72b7a99438e 100644
--- a/include/linux/ext3_fs_i.h
+++ b/include/linux/ext3_fs_i.h
@@ -75,8 +75,8 @@ struct ext3_inode_info {
* allocation when we detect linearly ascending requests.
*/
__u32 i_next_alloc_goal;
- /* block reservation window */
- struct ext3_reserve_window_node i_rsv_window;
+ /* block reservation info */
+ struct ext3_reserve_window_node *i_rsv_window;
__u32 i_dir_start_lookup;
#ifdef CONFIG_EXT3_FS_XATTR