@@ -3636,6 +3636,7 @@ struct nfs4_closedata {
36363636 } lr ;
36373637 struct nfs_fattr fattr ;
36383638 unsigned long timestamp ;
3639+ unsigned short retrans ;
36393640};
36403641
36413642static void nfs4_free_closedata (void * data )
@@ -3664,6 +3665,7 @@ static void nfs4_close_done(struct rpc_task *task, void *data)
36643665 .state = state ,
36653666 .inode = calldata -> inode ,
36663667 .stateid = & calldata -> arg .stateid ,
3668+ .retrans = calldata -> retrans ,
36673669 };
36683670
36693671 if (!nfs4_sequence_done (task , & calldata -> res .seq_res ))
@@ -3711,6 +3713,7 @@ static void nfs4_close_done(struct rpc_task *task, void *data)
37113713 default :
37123714 task -> tk_status = nfs4_async_handle_exception (task ,
37133715 server , task -> tk_status , & exception );
3716+ calldata -> retrans = exception .retrans ;
37143717 if (exception .retry )
37153718 goto out_restart ;
37163719 }
@@ -5593,9 +5596,11 @@ static int nfs4_read_done_cb(struct rpc_task *task, struct nfs_pgio_header *hdr)
55935596 .inode = hdr -> inode ,
55945597 .state = hdr -> args .context -> state ,
55955598 .stateid = & hdr -> args .stateid ,
5599+ .retrans = hdr -> retrans ,
55965600 };
55975601 task -> tk_status = nfs4_async_handle_exception (task ,
55985602 server , task -> tk_status , & exception );
5603+ hdr -> retrans = exception .retrans ;
55995604 if (exception .retry ) {
56005605 rpc_restart_call_prepare (task );
56015606 return - EAGAIN ;
@@ -5709,10 +5714,12 @@ static int nfs4_write_done_cb(struct rpc_task *task,
57095714 .inode = hdr -> inode ,
57105715 .state = hdr -> args .context -> state ,
57115716 .stateid = & hdr -> args .stateid ,
5717+ .retrans = hdr -> retrans ,
57125718 };
57135719 task -> tk_status = nfs4_async_handle_exception (task ,
57145720 NFS_SERVER (inode ), task -> tk_status ,
57155721 & exception );
5722+ hdr -> retrans = exception .retrans ;
57165723 if (exception .retry ) {
57175724 rpc_restart_call_prepare (task );
57185725 return - EAGAIN ;
@@ -6726,6 +6733,7 @@ struct nfs4_delegreturndata {
67266733 struct nfs_fh fh ;
67276734 nfs4_stateid stateid ;
67286735 unsigned long timestamp ;
6736+ unsigned short retrans ;
67296737 struct {
67306738 struct nfs4_layoutreturn_args arg ;
67316739 struct nfs4_layoutreturn_res res ;
@@ -6746,6 +6754,7 @@ static void nfs4_delegreturn_done(struct rpc_task *task, void *calldata)
67466754 .inode = data -> inode ,
67476755 .stateid = & data -> stateid ,
67486756 .task_is_privileged = data -> args .seq_args .sa_privileged ,
6757+ .retrans = data -> retrans ,
67496758 };
67506759
67516760 if (!nfs4_sequence_done (task , & data -> res .seq_res ))
@@ -6817,6 +6826,7 @@ static void nfs4_delegreturn_done(struct rpc_task *task, void *calldata)
68176826 task -> tk_status = nfs4_async_handle_exception (task ,
68186827 data -> res .server , task -> tk_status ,
68196828 & exception );
6829+ data -> retrans = exception .retrans ;
68206830 if (exception .retry )
68216831 goto out_restart ;
68226832 }
@@ -7093,6 +7103,7 @@ struct nfs4_unlockdata {
70937103 struct file_lock fl ;
70947104 struct nfs_server * server ;
70957105 unsigned long timestamp ;
7106+ unsigned short retrans ;
70967107};
70977108
70987109static struct nfs4_unlockdata * nfs4_alloc_unlockdata (struct file_lock * fl ,
@@ -7147,6 +7158,7 @@ static void nfs4_locku_done(struct rpc_task *task, void *data)
71477158 struct nfs4_exception exception = {
71487159 .inode = calldata -> lsp -> ls_state -> inode ,
71497160 .stateid = & calldata -> arg .stateid ,
7161+ .retrans = calldata -> retrans ,
71507162 };
71517163
71527164 if (!nfs4_sequence_done (task , & calldata -> res .seq_res ))
@@ -7180,6 +7192,7 @@ static void nfs4_locku_done(struct rpc_task *task, void *data)
71807192 task -> tk_status = nfs4_async_handle_exception (task ,
71817193 calldata -> server , task -> tk_status ,
71827194 & exception );
7195+ calldata -> retrans = exception .retrans ;
71837196 if (exception .retry )
71847197 rpc_restart_call_prepare (task );
71857198 }
0 commit comments