diff options
author | Jan Kara <jack@suse.cz> | 2017-11-01 16:36:42 +0100 |
---|---|---|
committer | Dan Williams <dan.j.williams@intel.com> | 2017-11-03 06:26:25 -0700 |
commit | caa51d26f85c248f1c4f43a870ad3ef84bf9eb8f (patch) | |
tree | 1949315570cf10dc95ebf1dde715cc1abaf81a2f /include/linux/iomap.h | |
parent | b6fb293f2497a9841d94f6b57bd2bb2cd222da43 (diff) | |
download | blackbird-op-linux-caa51d26f85c248f1c4f43a870ad3ef84bf9eb8f.tar.gz blackbird-op-linux-caa51d26f85c248f1c4f43a870ad3ef84bf9eb8f.zip |
dax, iomap: Add support for synchronous faults
Add a flag to iomap interface informing the caller that inode needs
fdstasync(2) for returned extent to become persistent and use it in DAX
fault code so that we don't map such extents into page tables
immediately. Instead we propagate the information that fdatasync(2) is
necessary from dax_iomap_fault() with a new VM_FAULT_NEEDDSYNC flag.
Filesystem fault handler is then responsible for calling fdatasync(2)
and inserting pfn into page tables.
Reviewed-by: Ross Zwisler <ross.zwisler@linux.intel.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'include/linux/iomap.h')
-rw-r--r-- | include/linux/iomap.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/iomap.h b/include/linux/iomap.h index f64dc6ce5161..73e3b7085dbe 100644 --- a/include/linux/iomap.h +++ b/include/linux/iomap.h @@ -22,6 +22,11 @@ struct vm_fault; * Flags for all iomap mappings: */ #define IOMAP_F_NEW 0x01 /* blocks have been newly allocated */ +/* + * IOMAP_F_DIRTY indicates the inode has uncommitted metadata needed to access + * written data and requires fdatasync to commit them to persistent storage. + */ +#define IOMAP_F_DIRTY 0x02 /* * Flags that only need to be reported for IOMAP_REPORT requests: |