[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <151937028128.18973.18029610933124841542.stgit@dwillia2-desk3.amr.corp.intel.com>
Date: Thu, 22 Feb 2018 23:18:01 -0800
From: Dan Williams <dan.j.williams@...el.com>
To: linux-nvdimm@...ts.01.org
Cc: Jan Kara <jack@...e.cz>, linux-kernel@...r.kernel.org,
linux-mm@...ck.org, Alexander Viro <viro@...iv.linux.org.uk>,
linux-fsdevel@...r.kernel.org, Christoph Hellwig <hch@....de>
Subject: [PATCH v2 4/5] dax: short circuit vma_is_fsdax() in the
CONFIG_FS_DAX=n case
Do not bother looking up the file type in the case when Filesystem-DAX
is disabled at build time.
Cc: Alexander Viro <viro@...iv.linux.org.uk>
Cc: linux-fsdevel@...r.kernel.org
Cc: Christoph Hellwig <hch@....de>
Cc: Jan Kara <jack@...e.cz>
Signed-off-by: Dan Williams <dan.j.williams@...el.com>
---
include/linux/fs.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/include/linux/fs.h b/include/linux/fs.h
index b2fa9b4c1e51..8f80d9fff86d 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -3195,6 +3195,8 @@ static inline bool vma_is_fsdax(struct vm_area_struct *vma)
if (!vma->vm_file)
return false;
+ if (!IS_ENABLED(CONFIG_FS_DAX))
+ return false;
if (!vma_is_dax(vma))
return false;
inode = file_inode(vma->vm_file);
Powered by blists - more mailing lists