diff options
author | Tao Ma <boyu.mt@taobao.com> | 2012-12-10 14:05:57 -0500 |
---|---|---|
committer | Theodore Ts'o <tytso@mit.edu> | 2012-12-10 14:05:57 -0500 |
commit | 9c3569b50f12e47cc5e907b5e37e4a45c0c10b43 (patch) | |
tree | dfd2c1cf5ad98ca059ff2f1f330f34faed2f79eb /fs/ext4/ext4.h | |
parent | 3fdcfb668fd78ec92d9bc2daddf1d41e2a8a30bb (diff) |
ext4: add delalloc support for inline data
For delayed allocation mode, we write to inline data if the file
is small enough. And in case of we write to some offset larger
than the inline size, the 1st page is dirtied, so that
ext4_da_writepages can handle the conversion. When the 1st page
is initialized with blocks, the inline part is removed.
Signed-off-by: Tao Ma <boyu.mt@taobao.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Diffstat (limited to 'fs/ext4/ext4.h')
-rw-r--r-- | fs/ext4/ext4.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/ext4/ext4.h b/fs/ext4/ext4.h index 9f4efc6c37ba..268636af7f5c 100644 --- a/fs/ext4/ext4.h +++ b/fs/ext4/ext4.h | |||
@@ -2022,6 +2022,8 @@ int ext4_get_block_write(struct inode *inode, sector_t iblock, | |||
2022 | struct buffer_head *bh_result, int create); | 2022 | struct buffer_head *bh_result, int create); |
2023 | int ext4_get_block(struct inode *inode, sector_t iblock, | 2023 | int ext4_get_block(struct inode *inode, sector_t iblock, |
2024 | struct buffer_head *bh_result, int create); | 2024 | struct buffer_head *bh_result, int create); |
2025 | int ext4_da_get_block_prep(struct inode *inode, sector_t iblock, | ||
2026 | struct buffer_head *bh, int create); | ||
2025 | int ext4_walk_page_buffers(handle_t *handle, | 2027 | int ext4_walk_page_buffers(handle_t *handle, |
2026 | struct buffer_head *head, | 2028 | struct buffer_head *head, |
2027 | unsigned from, | 2029 | unsigned from, |
@@ -2031,6 +2033,8 @@ int ext4_walk_page_buffers(handle_t *handle, | |||
2031 | struct buffer_head *bh)); | 2033 | struct buffer_head *bh)); |
2032 | int do_journal_get_write_access(handle_t *handle, | 2034 | int do_journal_get_write_access(handle_t *handle, |
2033 | struct buffer_head *bh); | 2035 | struct buffer_head *bh); |
2036 | #define FALL_BACK_TO_NONDELALLOC 1 | ||
2037 | #define CONVERT_INLINE_DATA 2 | ||
2034 | 2038 | ||
2035 | extern struct inode *ext4_iget(struct super_block *, unsigned long); | 2039 | extern struct inode *ext4_iget(struct super_block *, unsigned long); |
2036 | extern int ext4_write_inode(struct inode *, struct writeback_control *); | 2040 | extern int ext4_write_inode(struct inode *, struct writeback_control *); |