summaryrefslogtreecommitdiffstats
path: root/include/linux/fs.h
diff options
context:
space:
mode:
authorAmir Goldstein <amir73il@gmail.com>2018-08-27 08:56:02 -0400
committerMiklos Szeredi <mszeredi@redhat.com>2018-08-30 11:08:35 -0400
commit45cd0faae3715e305bc46e23b34c5ed4d185ceb8 (patch)
treebe01e26c488ebd3cb7943136a0805563e311d117 /include/linux/fs.h
parent17ef445f9befdc5c9adac270b18240ad24ee50ec (diff)
vfs: add the fadvise() file operation
This is going to be used by overlayfs and possibly useful for other filesystems. Signed-off-by: Amir Goldstein <amir73il@gmail.com> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Diffstat (limited to 'include/linux/fs.h')
-rw-r--r--include/linux/fs.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/fs.h b/include/linux/fs.h
index 33322702c910..6c0b4a1c22ff 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -1763,6 +1763,7 @@ struct file_operations {
1763 u64); 1763 u64);
1764 int (*dedupe_file_range)(struct file *, loff_t, struct file *, loff_t, 1764 int (*dedupe_file_range)(struct file *, loff_t, struct file *, loff_t,
1765 u64); 1765 u64);
1766 int (*fadvise)(struct file *, loff_t, loff_t, int);
1766} __randomize_layout; 1767} __randomize_layout;
1767 1768
1768struct inode_operations { 1769struct inode_operations {
@@ -3459,4 +3460,8 @@ static inline bool dir_relax_shared(struct inode *inode)
3459extern bool path_noexec(const struct path *path); 3460extern bool path_noexec(const struct path *path);
3460extern void inode_nohighmem(struct inode *inode); 3461extern void inode_nohighmem(struct inode *inode);
3461 3462
3463/* mm/fadvise.c */
3464extern int vfs_fadvise(struct file *file, loff_t offset, loff_t len,
3465 int advice);
3466
3462#endif /* _LINUX_FS_H */ 3467#endif /* _LINUX_FS_H */