hammer2 - Implement more of the hammer2_chain infrastructure
authorMatthew Dillon <dillon@apollo.backplane.com>
Sun, 12 Feb 2012 19:23:17 +0000 (11:23 -0800)
committerMatthew Dillon <dillon@apollo.backplane.com>
Sun, 12 Feb 2012 19:23:17 +0000 (11:23 -0800)
commit5c23d7f1813b9afaf43149bbe25b4d3b8097f456
treee2292fec5da77a956e3ce50b9174fdadd482fa84
parent82be12267420daca4cc6e5f39555e0b18a9c1732
hammer2 - Implement more of the hammer2_chain infrastructure

* Allocate system structures through their chain type.

* Implement core lookup and iteration code

* Non-terminal media objects which are smaller than HAMMER2_PBUFSIZE (64K)
  cannot hold onto their buffer cache buffer without deadlocking against
  or interfering with the chain.

  This is just inodes for now.  An embedded copy of the media data is
  retained (I had removed it before thinking I could just map the bp but
  it doesn't work, so it goes back in).

* Data references for other media objects can be temporary and allocated.
  The chain locking and unlocking code will instantiate and destroy the
  allocated copy as needed.

  This also enforces the chain locking requirement for media data access.

* hammer2_chain_create() skeleton added (cannot create indirect blocks yet).

* hammer2_chain_delete() does nothing atm.

* tested with mount/umount.
sys/vfs/hammer2/Makefile
sys/vfs/hammer2/hammer2.h
sys/vfs/hammer2/hammer2_chain.c
sys/vfs/hammer2/hammer2_disk.h
sys/vfs/hammer2/hammer2_freemap.c [new file with mode: 0644]
sys/vfs/hammer2/hammer2_inode.c
sys/vfs/hammer2/hammer2_subr.c
sys/vfs/hammer2/hammer2_vfsops.c