fs/xfs: Create function xfs_inode_should_enable_dax()
authorIra Weiny <ira.weiny@intel.com>
Mon, 4 May 2020 16:02:42 +0000 (09:02 -0700)
committerDarrick J. Wong <darrick.wong@oracle.com>
Mon, 4 May 2020 16:03:43 +0000 (09:03 -0700)
commit32dbc5655f1ccb3bffa5785523146f60fa4bf905
treed39349e49c8a869fc61a8cc3e37543ce218b1961
parent8d6c3446ec23ecd97bc089ed224342baf9426c30
fs/xfs: Create function xfs_inode_should_enable_dax()

xfs_inode_supports_dax() should reflect if the inode can support DAX not
that it is enabled for DAX.

Change the use of xfs_inode_supports_dax() to reflect only if the inode
and underlying storage support dax.

Add a new function xfs_inode_should_enable_dax() which reflects if the
inode should be enabled for DAX.

Reviewed-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Ira Weiny <ira.weiny@intel.com>
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
fs/xfs/xfs_iops.c