NFS: Create a common initiate_pgio() function

Most of this code is the same for both the read and write paths, so
combine everything and use the rw_ops when necessary.

Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
This commit is contained in:
Anna Schumaker 2014-05-06 09:12:37 -04:00 committed by Trond Myklebust
parent ef2c488c07
commit 1ed26f3300
6 changed files with 66 additions and 94 deletions

View file

@ -59,6 +59,8 @@ struct nfs_rw_ops {
void (*rw_release)(struct nfs_pgio_data *);
int (*rw_done)(struct rpc_task *, struct nfs_pgio_data *, struct inode *);
void (*rw_result)(struct rpc_task *, struct nfs_pgio_data *);
void (*rw_initiate)(struct nfs_pgio_data *, struct rpc_message *,
struct rpc_task_setup *, int);
};
struct nfs_pageio_descriptor {