aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/nfs_fs.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/nfs_fs.h')
-rw-r--r--include/linux/nfs_fs.h19
1 files changed, 8 insertions, 11 deletions
diff --git a/include/linux/nfs_fs.h b/include/linux/nfs_fs.h
index 229a1755842a..deef9567788a 100644
--- a/include/linux/nfs_fs.h
+++ b/include/linux/nfs_fs.h
@@ -112,8 +112,8 @@ struct nfs_inode {
112 /* 112 /*
113 * Various flags 113 * Various flags
114 */ 114 */
115 unsigned int flags; 115 unsigned long flags; /* atomic bit ops */
116 unsigned long cache_validity; 116 unsigned long cache_validity; /* bit mask */
117 117
118 /* 118 /*
119 * read_cache_jiffies is when we started read-caching this inode, 119 * read_cache_jiffies is when we started read-caching this inode,
@@ -175,8 +175,6 @@ struct nfs_inode {
175 /* Open contexts for shared mmap writes */ 175 /* Open contexts for shared mmap writes */
176 struct list_head open_files; 176 struct list_head open_files;
177 177
178 wait_queue_head_t nfs_i_wait;
179
180#ifdef CONFIG_NFS_V4 178#ifdef CONFIG_NFS_V4
181 struct nfs4_cached_acl *nfs4_acl; 179 struct nfs4_cached_acl *nfs4_acl;
182 /* NFSv4 state */ 180 /* NFSv4 state */
@@ -199,11 +197,11 @@ struct nfs_inode {
199#define NFS_INO_REVAL_PAGECACHE 0x0020 /* must revalidate pagecache */ 197#define NFS_INO_REVAL_PAGECACHE 0x0020 /* must revalidate pagecache */
200 198
201/* 199/*
202 * Legal values of flags field 200 * Bit offsets in flags field
203 */ 201 */
204#define NFS_INO_REVALIDATING 0x0001 /* revalidating attrs */ 202#define NFS_INO_REVALIDATING (0) /* revalidating attrs */
205#define NFS_INO_ADVISE_RDPLUS 0x0002 /* advise readdirplus */ 203#define NFS_INO_ADVISE_RDPLUS (1) /* advise readdirplus */
206#define NFS_INO_STALE 0x0004 /* possible stale inode */ 204#define NFS_INO_STALE (2) /* possible stale inode */
207 205
208static inline struct nfs_inode *NFS_I(struct inode *inode) 206static inline struct nfs_inode *NFS_I(struct inode *inode)
209{ 207{
@@ -229,8 +227,7 @@ static inline struct nfs_inode *NFS_I(struct inode *inode)
229#define NFS_ATTRTIMEO_UPDATE(inode) (NFS_I(inode)->attrtimeo_timestamp) 227#define NFS_ATTRTIMEO_UPDATE(inode) (NFS_I(inode)->attrtimeo_timestamp)
230 228
231#define NFS_FLAGS(inode) (NFS_I(inode)->flags) 229#define NFS_FLAGS(inode) (NFS_I(inode)->flags)
232#define NFS_REVALIDATING(inode) (NFS_FLAGS(inode) & NFS_INO_REVALIDATING) 230#define NFS_STALE(inode) (test_bit(NFS_INO_STALE, &NFS_FLAGS(inode)))
233#define NFS_STALE(inode) (NFS_FLAGS(inode) & NFS_INO_STALE)
234 231
235#define NFS_FILEID(inode) (NFS_I(inode)->fileid) 232#define NFS_FILEID(inode) (NFS_I(inode)->fileid)
236 233
@@ -252,7 +249,7 @@ static inline int nfs_server_capable(struct inode *inode, int cap)
252 249
253static inline int NFS_USE_READDIRPLUS(struct inode *inode) 250static inline int NFS_USE_READDIRPLUS(struct inode *inode)
254{ 251{
255 return NFS_FLAGS(inode) & NFS_INO_ADVISE_RDPLUS; 252 return test_bit(NFS_INO_ADVISE_RDPLUS, &NFS_FLAGS(inode));
256} 253}
257 254
258/** 255/**