]> git.baikalelectronics.ru Git - kernel.git/commit
dm log writes: add support for DAX
authorRoss Zwisler <ross.zwisler@linux.intel.com>
Fri, 20 Oct 2017 05:24:04 +0000 (23:24 -0600)
committerMike Snitzer <snitzer@redhat.com>
Fri, 10 Nov 2017 20:44:51 +0000 (15:44 -0500)
commitad0b81165fd0dbddae31dd271c708638ff080fdf
tree05d32dc5ad91f6d22e21bcba40fde515964fa128
parent87b3091fd5d8546b52cc4bf97ec087e43fe720ee
dm log writes: add support for DAX

Now that we have the ability log filesystem writes using a flat buffer, add
support for DAX.

The motivation for this support is the need for an xfstest that can test
the new MAP_SYNC DAX flag.  By logging the filesystem activity with
dm-log-writes we can show that the MAP_SYNC page faults are writing out
their metadata as they happen, instead of requiring an explicit
msync/fsync.

Unfortunately we can't easily track data that has been written via
mmap() now that the dax_flush() abstraction was removed by commit
e3a4735b9c0e ("dax: remove the pmem_dax_ops->flush abstraction").
Otherwise we could just treat each flush as a big write, and store the
data that is being synced to media.  It may be worthwhile to add the
dax_flush() entry point back, just as a notifier so we can do this
logging.

Signed-off-by: Ross Zwisler <ross.zwisler@linux.intel.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
drivers/md/dm-log-writes.c