diff options
Diffstat (limited to 'include/linux/nfs_fs.h')
-rw-r--r-- | include/linux/nfs_fs.h | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/include/linux/nfs_fs.h b/include/linux/nfs_fs.h index db867b04ac3c..fdffb413b192 100644 --- a/include/linux/nfs_fs.h +++ b/include/linux/nfs_fs.h | |||
@@ -166,8 +166,7 @@ struct nfs_inode { | |||
166 | */ | 166 | */ |
167 | struct radix_tree_root nfs_page_tree; | 167 | struct radix_tree_root nfs_page_tree; |
168 | 168 | ||
169 | unsigned long ncommit, | 169 | unsigned long npages; |
170 | npages; | ||
171 | 170 | ||
172 | /* Open contexts for shared mmap writes */ | 171 | /* Open contexts for shared mmap writes */ |
173 | struct list_head open_files; | 172 | struct list_head open_files; |
@@ -186,6 +185,9 @@ struct nfs_inode { | |||
186 | fmode_t delegation_state; | 185 | fmode_t delegation_state; |
187 | struct rw_semaphore rwsem; | 186 | struct rw_semaphore rwsem; |
188 | #endif /* CONFIG_NFS_V4*/ | 187 | #endif /* CONFIG_NFS_V4*/ |
188 | #ifdef CONFIG_NFS_FSCACHE | ||
189 | struct fscache_cookie *fscache; | ||
190 | #endif | ||
189 | struct inode vfs_inode; | 191 | struct inode vfs_inode; |
190 | }; | 192 | }; |
191 | 193 | ||
@@ -207,6 +209,9 @@ struct nfs_inode { | |||
207 | #define NFS_INO_STALE (1) /* possible stale inode */ | 209 | #define NFS_INO_STALE (1) /* possible stale inode */ |
208 | #define NFS_INO_ACL_LRU_SET (2) /* Inode is on the LRU list */ | 210 | #define NFS_INO_ACL_LRU_SET (2) /* Inode is on the LRU list */ |
209 | #define NFS_INO_MOUNTPOINT (3) /* inode is remote mountpoint */ | 211 | #define NFS_INO_MOUNTPOINT (3) /* inode is remote mountpoint */ |
212 | #define NFS_INO_FLUSHING (4) /* inode is flushing out data */ | ||
213 | #define NFS_INO_FSCACHE (5) /* inode can be cached by FS-Cache */ | ||
214 | #define NFS_INO_FSCACHE_LOCK (6) /* FS-Cache cookie management lock */ | ||
210 | 215 | ||
211 | static inline struct nfs_inode *NFS_I(const struct inode *inode) | 216 | static inline struct nfs_inode *NFS_I(const struct inode *inode) |
212 | { | 217 | { |
@@ -260,6 +265,11 @@ static inline int NFS_STALE(const struct inode *inode) | |||
260 | return test_bit(NFS_INO_STALE, &NFS_I(inode)->flags); | 265 | return test_bit(NFS_INO_STALE, &NFS_I(inode)->flags); |
261 | } | 266 | } |
262 | 267 | ||
268 | static inline int NFS_FSCACHE(const struct inode *inode) | ||
269 | { | ||
270 | return test_bit(NFS_INO_FSCACHE, &NFS_I(inode)->flags); | ||
271 | } | ||
272 | |||
263 | static inline __u64 NFS_FILEID(const struct inode *inode) | 273 | static inline __u64 NFS_FILEID(const struct inode *inode) |
264 | { | 274 | { |
265 | return NFS_I(inode)->fileid; | 275 | return NFS_I(inode)->fileid; |
@@ -415,7 +425,7 @@ extern const struct inode_operations nfs_dir_inode_operations; | |||
415 | extern const struct inode_operations nfs3_dir_inode_operations; | 425 | extern const struct inode_operations nfs3_dir_inode_operations; |
416 | #endif /* CONFIG_NFS_V3 */ | 426 | #endif /* CONFIG_NFS_V3 */ |
417 | extern const struct file_operations nfs_dir_operations; | 427 | extern const struct file_operations nfs_dir_operations; |
418 | extern struct dentry_operations nfs_dentry_operations; | 428 | extern const struct dentry_operations nfs_dentry_operations; |
419 | 429 | ||
420 | extern void nfs_force_lookup_revalidate(struct inode *dir); | 430 | extern void nfs_force_lookup_revalidate(struct inode *dir); |
421 | extern int nfs_instantiate(struct dentry *dentry, struct nfs_fh *fh, struct nfs_fattr *fattr); | 431 | extern int nfs_instantiate(struct dentry *dentry, struct nfs_fh *fh, struct nfs_fattr *fattr); |
@@ -506,6 +516,8 @@ extern int nfs_readpages(struct file *, struct address_space *, | |||
506 | struct list_head *, unsigned); | 516 | struct list_head *, unsigned); |
507 | extern int nfs_readpage_result(struct rpc_task *, struct nfs_read_data *); | 517 | extern int nfs_readpage_result(struct rpc_task *, struct nfs_read_data *); |
508 | extern void nfs_readdata_release(void *data); | 518 | extern void nfs_readdata_release(void *data); |
519 | extern int nfs_readpage_async(struct nfs_open_context *, struct inode *, | ||
520 | struct page *); | ||
509 | 521 | ||
510 | /* | 522 | /* |
511 | * Allocate nfs_read_data structures | 523 | * Allocate nfs_read_data structures |
@@ -583,6 +595,7 @@ extern void * nfs_root_data(void); | |||
583 | #define NFSDBG_CALLBACK 0x0100 | 595 | #define NFSDBG_CALLBACK 0x0100 |
584 | #define NFSDBG_CLIENT 0x0200 | 596 | #define NFSDBG_CLIENT 0x0200 |
585 | #define NFSDBG_MOUNT 0x0400 | 597 | #define NFSDBG_MOUNT 0x0400 |
598 | #define NFSDBG_FSCACHE 0x0800 | ||
586 | #define NFSDBG_ALL 0xFFFF | 599 | #define NFSDBG_ALL 0xFFFF |
587 | 600 | ||
588 | #ifdef __KERNEL__ | 601 | #ifdef __KERNEL__ |