diff options
author | Trond Myklebust <Trond.Myklebust@netapp.com> | 2011-10-19 15:17:29 -0400 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2011-10-19 16:58:30 -0400 |
commit | d00c5d43866720963a265fa3129f3203cac35b8e (patch) | |
tree | 0121c93156007c7764a818cc70b6864614e40536 /fs/nfs/nfs4proc.c | |
parent | b8ef70639b609c5d12c618f1d9ffae6ac13aebe3 (diff) |
NFS: Get rid of nfs_restart_rpc()
It can trivially be replaced with rpc_restart_call_prepare.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'fs/nfs/nfs4proc.c')
-rw-r--r-- | fs/nfs/nfs4proc.c | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index ba0da50865f..d2ae413c986 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c | |||
@@ -3191,7 +3191,7 @@ static int nfs4_read_done_cb(struct rpc_task *task, struct nfs_read_data *data) | |||
3191 | struct nfs_server *server = NFS_SERVER(data->inode); | 3191 | struct nfs_server *server = NFS_SERVER(data->inode); |
3192 | 3192 | ||
3193 | if (nfs4_async_handle_error(task, server, data->args.context->state) == -EAGAIN) { | 3193 | if (nfs4_async_handle_error(task, server, data->args.context->state) == -EAGAIN) { |
3194 | nfs_restart_rpc(task, server->nfs_client); | 3194 | rpc_restart_call_prepare(task); |
3195 | return -EAGAIN; | 3195 | return -EAGAIN; |
3196 | } | 3196 | } |
3197 | 3197 | ||
@@ -3241,7 +3241,7 @@ static int nfs4_write_done_cb(struct rpc_task *task, struct nfs_write_data *data | |||
3241 | struct inode *inode = data->inode; | 3241 | struct inode *inode = data->inode; |
3242 | 3242 | ||
3243 | if (nfs4_async_handle_error(task, NFS_SERVER(inode), data->args.context->state) == -EAGAIN) { | 3243 | if (nfs4_async_handle_error(task, NFS_SERVER(inode), data->args.context->state) == -EAGAIN) { |
3244 | nfs_restart_rpc(task, NFS_SERVER(inode)->nfs_client); | 3244 | rpc_restart_call_prepare(task); |
3245 | return -EAGAIN; | 3245 | return -EAGAIN; |
3246 | } | 3246 | } |
3247 | if (task->tk_status >= 0) { | 3247 | if (task->tk_status >= 0) { |
@@ -3298,7 +3298,7 @@ static int nfs4_commit_done_cb(struct rpc_task *task, struct nfs_write_data *dat | |||
3298 | struct inode *inode = data->inode; | 3298 | struct inode *inode = data->inode; |
3299 | 3299 | ||
3300 | if (nfs4_async_handle_error(task, NFS_SERVER(inode), NULL) == -EAGAIN) { | 3300 | if (nfs4_async_handle_error(task, NFS_SERVER(inode), NULL) == -EAGAIN) { |
3301 | nfs_restart_rpc(task, NFS_SERVER(inode)->nfs_client); | 3301 | rpc_restart_call_prepare(task); |
3302 | return -EAGAIN; | 3302 | return -EAGAIN; |
3303 | } | 3303 | } |
3304 | nfs_refresh_inode(inode, data->res.fattr); | 3304 | nfs_refresh_inode(inode, data->res.fattr); |
@@ -3838,7 +3838,7 @@ static void nfs4_delegreturn_done(struct rpc_task *task, void *calldata) | |||
3838 | default: | 3838 | default: |
3839 | if (nfs4_async_handle_error(task, data->res.server, NULL) == | 3839 | if (nfs4_async_handle_error(task, data->res.server, NULL) == |
3840 | -EAGAIN) { | 3840 | -EAGAIN) { |
3841 | nfs_restart_rpc(task, data->res.server->nfs_client); | 3841 | rpc_restart_call_prepare(task); |
3842 | return; | 3842 | return; |
3843 | } | 3843 | } |
3844 | } | 3844 | } |
@@ -4092,8 +4092,7 @@ static void nfs4_locku_done(struct rpc_task *task, void *data) | |||
4092 | break; | 4092 | break; |
4093 | default: | 4093 | default: |
4094 | if (nfs4_async_handle_error(task, calldata->server, NULL) == -EAGAIN) | 4094 | if (nfs4_async_handle_error(task, calldata->server, NULL) == -EAGAIN) |
4095 | nfs_restart_rpc(task, | 4095 | rpc_restart_call_prepare(task); |
4096 | calldata->server->nfs_client); | ||
4097 | } | 4096 | } |
4098 | } | 4097 | } |
4099 | 4098 | ||
@@ -4926,7 +4925,7 @@ static void nfs4_get_lease_time_done(struct rpc_task *task, void *calldata) | |||
4926 | task->tk_status = 0; | 4925 | task->tk_status = 0; |
4927 | /* fall through */ | 4926 | /* fall through */ |
4928 | case -NFS4ERR_RETRY_UNCACHED_REP: | 4927 | case -NFS4ERR_RETRY_UNCACHED_REP: |
4929 | nfs_restart_rpc(task, data->clp); | 4928 | rpc_restart_call_prepare(task); |
4930 | return; | 4929 | return; |
4931 | } | 4930 | } |
4932 | dprintk("<-- %s\n", __func__); | 4931 | dprintk("<-- %s\n", __func__); |
@@ -5767,7 +5766,7 @@ static void nfs4_layoutreturn_done(struct rpc_task *task, void *calldata) | |||
5767 | 5766 | ||
5768 | server = NFS_SERVER(lrp->args.inode); | 5767 | server = NFS_SERVER(lrp->args.inode); |
5769 | if (nfs4_async_handle_error(task, server, NULL) == -EAGAIN) { | 5768 | if (nfs4_async_handle_error(task, server, NULL) == -EAGAIN) { |
5770 | nfs_restart_rpc(task, lrp->clp); | 5769 | rpc_restart_call_prepare(task); |
5771 | return; | 5770 | return; |
5772 | } | 5771 | } |
5773 | spin_lock(&lo->plh_inode->i_lock); | 5772 | spin_lock(&lo->plh_inode->i_lock); |
@@ -5938,7 +5937,7 @@ nfs4_layoutcommit_done(struct rpc_task *task, void *calldata) | |||
5938 | } | 5937 | } |
5939 | 5938 | ||
5940 | if (nfs4_async_handle_error(task, server, NULL) == -EAGAIN) { | 5939 | if (nfs4_async_handle_error(task, server, NULL) == -EAGAIN) { |
5941 | nfs_restart_rpc(task, server->nfs_client); | 5940 | rpc_restart_call_prepare(task); |
5942 | return; | 5941 | return; |
5943 | } | 5942 | } |
5944 | 5943 | ||