aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfs/nfs4filelayout.c
diff options
context:
space:
mode:
authorAnna Schumaker <Anna.Schumaker@netapp.com>2014-05-06 09:12:37 -0400
committerTrond Myklebust <trond.myklebust@primarydata.com>2014-05-29 11:11:40 -0400
commit1ed26f33008e954a8e91d26f97d4380dea8145db (patch)
treea187a1fb9658ee39d5c00e71fd6105b7cb6d3f56 /fs/nfs/nfs4filelayout.c
parentef2c488c073f4f0b3a200745dd8d608c01d69c39 (diff)
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>
Diffstat (limited to 'fs/nfs/nfs4filelayout.c')
-rw-r--r--fs/nfs/nfs4filelayout.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/nfs/nfs4filelayout.c b/fs/nfs/nfs4filelayout.c
index e6936147ad95..7954e16a6d83 100644
--- a/fs/nfs/nfs4filelayout.c
+++ b/fs/nfs/nfs4filelayout.c
@@ -568,8 +568,8 @@ filelayout_read_pagelist(struct nfs_pgio_data *data)
568 data->mds_offset = offset; 568 data->mds_offset = offset;
569 569
570 /* Perform an asynchronous read to ds */ 570 /* Perform an asynchronous read to ds */
571 nfs_initiate_read(ds_clnt, data, 571 nfs_initiate_pgio(ds_clnt, data,
572 &filelayout_read_call_ops, RPC_TASK_SOFTCONN); 572 &filelayout_read_call_ops, 0, RPC_TASK_SOFTCONN);
573 return PNFS_ATTEMPTED; 573 return PNFS_ATTEMPTED;
574} 574}
575 575
@@ -613,7 +613,7 @@ filelayout_write_pagelist(struct nfs_pgio_data *data, int sync)
613 data->args.offset = filelayout_get_dserver_offset(lseg, offset); 613 data->args.offset = filelayout_get_dserver_offset(lseg, offset);
614 614
615 /* Perform an asynchronous write */ 615 /* Perform an asynchronous write */
616 nfs_initiate_write(ds_clnt, data, 616 nfs_initiate_pgio(ds_clnt, data,
617 &filelayout_write_call_ops, sync, 617 &filelayout_write_call_ops, sync,
618 RPC_TASK_SOFTCONN); 618 RPC_TASK_SOFTCONN);
619 return PNFS_ATTEMPTED; 619 return PNFS_ATTEMPTED;