Lines Matching refs:task
85 static int filelayout_async_handle_error(struct rpc_task *task, in filelayout_async_handle_error() argument
93 if (task->tk_status >= 0) in filelayout_async_handle_error()
97 switch (task->tk_status) { in filelayout_async_handle_error()
119 "flags 0x%x\n", __func__, task->tk_status, in filelayout_async_handle_error()
126 rpc_delay(task, FILELAYOUT_POLL_RETRY_MAX); in filelayout_async_handle_error()
132 task->tk_status); in filelayout_async_handle_error()
137 task->tk_status = 0; in filelayout_async_handle_error()
140 rpc_sleep_on(&mds_client->cl_rpcwaitq, task, NULL); in filelayout_async_handle_error()
142 rpc_wake_up_queued_task(&mds_client->cl_rpcwaitq, task); in filelayout_async_handle_error()
148 static int filelayout_read_done_cb(struct rpc_task *task, in filelayout_read_done_cb() argument
155 if (filelayout_async_handle_error(task, data->args.context->state, in filelayout_read_done_cb()
161 nfs4_reset_read(task, data); in filelayout_read_done_cb()
163 rpc_restart_call_prepare(task); in filelayout_read_done_cb()
192 static void filelayout_read_prepare(struct rpc_task *task, void *data) in filelayout_read_prepare() argument
200 task)) in filelayout_read_prepare()
203 rpc_call_start(task); in filelayout_read_prepare()
206 static void filelayout_read_call_done(struct rpc_task *task, void *data) in filelayout_read_call_done() argument
210 dprintk("--> %s task->tk_status %d\n", __func__, task->tk_status); in filelayout_read_call_done()
213 rdata->mds_ops->rpc_call_done(task, data); in filelayout_read_call_done()
216 static void filelayout_read_count_stats(struct rpc_task *task, void *data) in filelayout_read_count_stats() argument
220 rpc_count_iostats(task, NFS_SERVER(rdata->inode)->client->cl_metrics); in filelayout_read_count_stats()
231 static int filelayout_write_done_cb(struct rpc_task *task, in filelayout_write_done_cb() argument
236 if (filelayout_async_handle_error(task, data->args.context->state, in filelayout_write_done_cb()
242 nfs4_reset_write(task, data); in filelayout_write_done_cb()
244 rpc_restart_call_prepare(task); in filelayout_write_done_cb()
257 data->task.tk_status = 0; in prepare_to_resend_writes()
263 static int filelayout_commit_done_cb(struct rpc_task *task, in filelayout_commit_done_cb() argument
268 if (filelayout_async_handle_error(task, data->args.context->state, in filelayout_commit_done_cb()
276 rpc_restart_call_prepare(task); in filelayout_commit_done_cb()
283 static void filelayout_write_prepare(struct rpc_task *task, void *data) in filelayout_write_prepare() argument
289 task)) in filelayout_write_prepare()
292 rpc_call_start(task); in filelayout_write_prepare()
295 static void filelayout_write_call_done(struct rpc_task *task, void *data) in filelayout_write_call_done() argument
300 wdata->mds_ops->rpc_call_done(task, data); in filelayout_write_call_done()
303 static void filelayout_write_count_stats(struct rpc_task *task, void *data) in filelayout_write_count_stats() argument
307 rpc_count_iostats(task, NFS_SERVER(wdata->inode)->client->cl_metrics); in filelayout_write_count_stats()