diff options
author | Trond Myklebust <trond.myklebust@primarydata.com> | 2016-06-25 17:24:46 -0400 |
---|---|---|
committer | Trond Myklebust <trond.myklebust@primarydata.com> | 2016-07-05 19:11:06 -0400 |
commit | 651b0e702981304f77091b82870a01480705f4fe (patch) | |
tree | 27c5134920cb995716b419e9b6a4635e03b639c9 /fs/nfs/internal.h | |
parent | be527494e02b89e03485955b30de6c1e976a07eb (diff) |
NFS: Do not aggressively cache file attributes in the case of O_DIRECT
A file that is open for O_DIRECT is by definition not obeying
close-to-open cache consistency semantics, so let's not cache
the attributes too aggressively either.
Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Diffstat (limited to 'fs/nfs/internal.h')
-rw-r--r-- | fs/nfs/internal.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/nfs/internal.h b/fs/nfs/internal.h index 159b64ede82a..01dccf18da0a 100644 --- a/fs/nfs/internal.h +++ b/fs/nfs/internal.h | |||
@@ -419,6 +419,11 @@ extern void nfs_end_io_write(struct inode *inode); | |||
419 | extern void nfs_start_io_direct(struct inode *inode); | 419 | extern void nfs_start_io_direct(struct inode *inode); |
420 | extern void nfs_end_io_direct(struct inode *inode); | 420 | extern void nfs_end_io_direct(struct inode *inode); |
421 | 421 | ||
422 | static inline bool nfs_file_io_is_buffered(struct nfs_inode *nfsi) | ||
423 | { | ||
424 | return test_bit(NFS_INO_ODIRECT, &nfsi->flags) == 0; | ||
425 | } | ||
426 | |||
422 | /* namespace.c */ | 427 | /* namespace.c */ |
423 | #define NFS_PATH_CANONICAL 1 | 428 | #define NFS_PATH_CANONICAL 1 |
424 | extern char *nfs_path(char **p, struct dentry *dentry, | 429 | extern char *nfs_path(char **p, struct dentry *dentry, |