diff options
author | Dave Chinner <dchinner@redhat.com> | 2016-01-04 16:44:15 +1100 |
---|---|---|
committer | Dave Chinner <david@fromorbit.com> | 2016-01-04 16:44:15 +1100 |
commit | 58f88ca2df7270881de2034c8286233a89efe71c (patch) | |
tree | 216088a0e082b5458f570a31f5507fb63053de1a /include/uapi/linux | |
parent | e7b89481017b2111d188afd70bbd0da9e9b94cc9 (diff) | |
download | blackbird-op-linux-58f88ca2df7270881de2034c8286233a89efe71c.tar.gz blackbird-op-linux-58f88ca2df7270881de2034c8286233a89efe71c.zip |
xfs: introduce per-inode DAX enablement
Rather than just being able to turn DAX on and off via a mount
option, some applications may only want to enable DAX for certain
performance critical files in a filesystem.
This patch introduces a new inode flag to enable DAX in the v3 inode
di_flags2 field. It adds support for setting and clearing flags in
the di_flags2 field via the XFS_IOC_FSSETXATTR ioctl, and sets the
S_DAX inode flag appropriately when it is seen.
When this flag is set on a directory, it acts as an "inherit flag".
That is, inodes created in the directory will automatically inherit
the on-disk inode DAX flag, enabling administrators to set up
directory heirarchies that automatically use DAX. Setting this flag
on an empty root directory will make the entire filesystem use DAX
by default.
Signed-off-by: Dave Chinner <dchinner@redhat.com>
Diffstat (limited to 'include/uapi/linux')
-rw-r--r-- | include/uapi/linux/fs.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/uapi/linux/fs.h b/include/uapi/linux/fs.h index df175dddd07f..4cad4c8ab6b2 100644 --- a/include/uapi/linux/fs.h +++ b/include/uapi/linux/fs.h @@ -138,6 +138,7 @@ struct fsxattr { #define FS_XFLAG_EXTSZINHERIT 0x00001000 /* inherit inode extent size */ #define FS_XFLAG_NODEFRAG 0x00002000 /* do not defragment */ #define FS_XFLAG_FILESTREAM 0x00004000 /* use filestream allocator */ +#define FS_XFLAG_DAX 0x00008000 /* use DAX for IO */ #define FS_XFLAG_HASATTR 0x80000000 /* no DIFLAG for this */ /* the read-only stuff doesn't really belong here, but any other place is |