Ryusuke Konishi ab44ef4352 lib/nilfs: revise nilfs_get_segment() and nilfs_put_segment()
Rewrite nilfs_get_segment() and nilfs_put_segment() so that
nilfs_get_segment() stores related information (segment size, start
block number, number of blocks, memory address, etc) in a new data
structure, nilfs_segment, and nilfs_put_segment() releases the memory
allocated or mapped by nilfs_get_segment() based on the information in
nilfs_segment.

This also simplifies nilfs_psegment struct and functions wrt iterator
for partial segment, that is, nilfs_psegment_init(),
nilfs_psegment_is_end(), nilfs_psegment_next(), and
nilfs_psegment_for_each().

Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
2016-09-18 17:45:57 +09:00
..
2016-08-24 21:31:01 +09:00