git: hammer2 hammer2 - Initial media flush implementation
Matthew Dillon
dillon at crater.dragonflybsd.org
Mon Feb 13 00:58:41 PST 2012
commit b7926f310b7b7a02b46070c92b13540dd2c482e3
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date: Mon Feb 13 00:52:21 2012 -0800
hammer2 - Initial media flush implementation
* Implement hammer2_chain_flush(), hammer2_vfs_sync(), and hammer2_vop_fsync().
The flush code currently handles inodes but not data.
* hammer2_chain_flush() recursively flushes a chain structure, handing the
parent the updated blockref. When flushing downward pending chain elements
will allocate new blocks for copy-on-write.
* Survives mount/mkdir/umount/mount
NOTES: fsync currently stops at the inode and does not currently flush
through to the volume root. We need to implement a short-cut for
fsync using currently reserved volume header fields to avoid having
to flush out the entire chain.
We haven't implemented data blocks yet.
Summary of changes:
sys/vfs/hammer2/hammer2.h | 14 +-
sys/vfs/hammer2/hammer2_chain.c | 387 ++++++++++++++++++++++++++++++++++---
sys/vfs/hammer2/hammer2_freemap.c | 4 +
sys/vfs/hammer2/hammer2_vfsops.c | 137 +++++++++++---
sys/vfs/hammer2/hammer2_vnops.c | 21 ++-
5 files changed, 506 insertions(+), 57 deletions(-)
http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/b7926f310b7b7a02b46070c92b13540dd2c482e3
--
DragonFly BSD source repository
More information about the Commits
mailing list