hammer2 - Flush ordering fixes
authorMatthew Dillon <dillon@apollo.backplane.com>
Sat, 19 May 2012 02:18:14 +0000 (19:18 -0700)
committerMatthew Dillon <dillon@apollo.backplane.com>
Sat, 19 May 2012 02:26:30 +0000 (19:26 -0700)
commit90ea1e359ba3186ea419ac0476b1091979c858f0
tree19ad22383843b1d8306cababf365593637904e68
parent004f88b45de50f4b39b539be43b90529b027b4e5
hammer2 - Flush ordering fixes

* The flush code is required to write out modified chains, not just bdwrite()
  them.  Otherwise the disk synchronization and volume header write will be
  mis-ordered.

* Don't re-write indirect blocks that the OS had already written out.  This
  check is already being made for data blocks, and inode modifications are
  embedded and thus must always be written out.

* This fixes issues where 'hammer2 show <device>' would find corrupt
  topology during concurrent filesystem write activity.  The disk media
  is always supposed to be consistent.

  We don't care about block-reuse cases for this debug command but we do
  care that, sans block-reuse, a dump will produce a consistent topology.
sys/vfs/hammer2/hammer2_chain.c