diff options
| author | Linus Torvalds <torvalds@home.transmeta.com> | 2002-10-11 05:18:23 -0700 |
|---|---|---|
| committer | Linus Torvalds <torvalds@home.transmeta.com> | 2002-10-11 05:18:23 -0700 |
| commit | 3ef3aca57ca39c2827aec85a8c878eed0288debc (patch) | |
| tree | 41110d3b8a25eeb2e3289df61e044bd22ee05ba4 /include/linux | |
| parent | 7c05bbf9ea019d85b8df7dbb60052bc1872254e5 (diff) | |
| parent | f55b6cfbc3c94fdf443d0ce9b3d10be3f904b0ae (diff) | |
Merge bk://bk.arm.linux.org.uk
into home.transmeta.com:/home/torvalds/v2.5/linux
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/nfs_fs.h | 29 | ||||
| -rw-r--r-- | include/linux/nfs_xdr.h | 24 |
2 files changed, 31 insertions, 22 deletions
diff --git a/include/linux/nfs_fs.h b/include/linux/nfs_fs.h index c352fcbc956d..4c35f7cbb97c 100644 --- a/include/linux/nfs_fs.h +++ b/include/linux/nfs_fs.h @@ -323,6 +323,14 @@ extern void nfs_complete_unlink(struct dentry *); extern int nfs_writepage(struct page *); extern int nfs_flush_incompatible(struct file *file, struct page *page); extern int nfs_updatepage(struct file *, struct page *, unsigned int, unsigned int); +extern void nfs_writeback_done(struct rpc_task *task, int stable, + unsigned int arg_count, unsigned int res_count); +extern void nfs_writedata_release(struct rpc_task *task); + +#if defined(CONFIG_NFS_V3) || defined(CONFIG_NFS_V4) +extern void nfs_commit_done(struct rpc_task *); +#endif + /* * Try to write back everything synchronously (but check the * return value!) @@ -462,28 +470,7 @@ extern void * nfs_root_data(void); __retval; \ }) -#ifdef CONFIG_NFS_V3 - #define NFS_JUKEBOX_RETRY_TIME (5 * HZ) -static inline int -nfs_async_handle_jukebox(struct rpc_task *task) -{ - if (task->tk_status != -EJUKEBOX) - return 0; - task->tk_status = 0; - rpc_restart_call(task); - rpc_delay(task, NFS_JUKEBOX_RETRY_TIME); - return 1; -} - -#else - -static inline int -nfs_async_handle_jukebox(struct rpc_task *task) -{ - return 0; -} -#endif /* CONFIG_NFS_V3 */ #endif /* __KERNEL__ */ diff --git a/include/linux/nfs_xdr.h b/include/linux/nfs_xdr.h index eb65418342d2..b71b1b217c70 100644 --- a/include/linux/nfs_xdr.h +++ b/include/linux/nfs_xdr.h @@ -67,6 +67,7 @@ struct nfs_fsinfo { __u64 afiles; /* # of files available to user */ __u32 linkmax;/* max # of hard links */ __u32 namelen;/* max name length */ + __u32 lease_time; /* in seconds */ }; /* @@ -326,6 +327,25 @@ struct nfs_read_data { } u; }; +struct nfs_write_data { + struct rpc_task task; + struct inode *inode; + struct rpc_cred *cred; + struct nfs_fattr fattr; + struct nfs_writeverf verf; + struct list_head pages; /* Coalesced requests we wish to flush */ + struct page *pagevec[NFS_WRITE_MAXIOV]; + union { + struct { + struct nfs_writeargs args; + struct nfs_writeres res; + } v3; +#ifdef CONFIG_NFS_V4 + /* NFSv4 data to come here... */ +#endif + } u; +}; + /* * RPC procedure vector for NFSv2/NFSv3 demuxing */ @@ -356,7 +376,7 @@ struct nfs_rpc_ops { int (*remove) (struct inode *, struct qstr *); int (*unlink_setup) (struct rpc_message *, struct dentry *, struct qstr *); - void (*unlink_done) (struct dentry *, struct rpc_message *); + int (*unlink_done) (struct dentry *, struct rpc_task *); int (*rename) (struct inode *, struct qstr *, struct inode *, struct qstr *); int (*link) (struct inode *, struct inode *, struct qstr *); @@ -374,6 +394,8 @@ struct nfs_rpc_ops { struct nfs_fsinfo *); u32 * (*decode_dirent)(u32 *, struct nfs_entry *, int plus); void (*read_setup) (struct nfs_read_data *, unsigned int count); + void (*write_setup) (struct nfs_write_data *, unsigned int count, int how); + void (*commit_setup) (struct nfs_write_data *, u64 start, u32 len, int how); }; /* |
