Skip to content

Commit 6c98cd4

Browse files
Koji Satotorvalds
authored andcommitted
nilfs2: segment usage file
This adds a meta data file which stores the allocation state of segments. [[email protected]: fix wrong counting of checkpoints and dirty segments] Signed-off-by: Koji Sato <[email protected]> Signed-off-by: Ryusuke Konishi <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
1 parent 2961980 commit 6c98cd4

File tree

3 files changed

+682
-1
lines changed

3 files changed

+682
-1
lines changed

fs/nilfs2/cpfile.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -357,7 +357,7 @@ int nilfs_cpfile_delete_checkpoints(struct inode *cpfile,
357357
kaddr = kmap_atomic(header_bh->b_page, KM_USER0);
358358
header = nilfs_cpfile_block_get_header(cpfile, header_bh,
359359
kaddr);
360-
le64_add_cpu(&header->ch_ncheckpoints, -tnicps);
360+
le64_add_cpu(&header->ch_ncheckpoints, -(u64)tnicps);
361361
nilfs_mdt_mark_buffer_dirty(header_bh);
362362
nilfs_mdt_mark_dirty(cpfile);
363363
kunmap_atomic(kaddr, KM_USER0);

0 commit comments

Comments
 (0)