diff options
author | Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> | 2010-12-26 16:28:28 +0900 |
---|---|---|
committer | Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> | 2011-01-10 14:05:45 +0900 |
commit | 27e6c7a3ce29ae5fa5bec4ed5917f8508bfac120 (patch) | |
tree | 958d82757bf23e426c7bc1035f76d986f09be535 /fs/nilfs2/segment.c | |
parent | e828949e5b42bfd234ee537cdb7c5e3a577958a3 (diff) | |
download | linux-27e6c7a3ce29ae5fa5bec4ed5917f8508bfac120.tar.gz linux-27e6c7a3ce29ae5fa5bec4ed5917f8508bfac120.tar.bz2 linux-27e6c7a3ce29ae5fa5bec4ed5917f8508bfac120.zip |
nilfs2: mark buffer heads as delayed until the data is written to disk
Nilfs does not allocate new blocks on disk until they are actually
written to. To implement fiemap, we need to deal with such blocks.
To allow successive fiemap patch to distinguish mapped but unallocated
regions, this marks buffer heads of those new blocks as delayed and
clears the flag after the blocks are written to disk.
Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
Diffstat (limited to 'fs/nilfs2/segment.c')
-rw-r--r-- | fs/nilfs2/segment.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/nilfs2/segment.c b/fs/nilfs2/segment.c index d3d2f4396f72..efc7d0a1bbf7 100644 --- a/fs/nilfs2/segment.c +++ b/fs/nilfs2/segment.c @@ -1763,6 +1763,7 @@ static void nilfs_clear_copied_buffers(struct list_head *list, int err) if (!err) { set_buffer_uptodate(bh); clear_buffer_dirty(bh); + clear_buffer_delay(bh); clear_buffer_nilfs_volatile(bh); } brelse(bh); /* for b_assoc_buffers */ @@ -1889,6 +1890,7 @@ static void nilfs_segctor_complete_write(struct nilfs_sc_info *sci) b_assoc_buffers) { set_buffer_uptodate(bh); clear_buffer_dirty(bh); + clear_buffer_delay(bh); clear_buffer_nilfs_volatile(bh); clear_buffer_nilfs_redirected(bh); if (bh == segbuf->sb_super_root) { |