]> git.baikalelectronics.ru Git - kernel.git/commit
rxrpc: Need to produce an ACK for service op if op takes a long time
authorDavid Howells <dhowells@redhat.com>
Thu, 6 Oct 2016 07:11:50 +0000 (08:11 +0100)
committerDavid Howells <dhowells@redhat.com>
Thu, 6 Oct 2016 07:11:50 +0000 (08:11 +0100)
commitb62ab693eb4469bf56a719494caf7caa4964cacb
treedd35745be3708e1cd86c691e2b50e474eebfb43b
parent7711dd28e5c052442a9d2ff3e7a02f2bfd51e336
rxrpc: Need to produce an ACK for service op if op takes a long time

We need to generate a DELAY ACK from the service end of an operation if we
start doing the actual operation work and it takes longer than expected.
This will hard-ACK the request data and allow the client to release its
resources.

To make this work:

 (1) We have to set the ack timer and propose an ACK when the call moves to
     the RXRPC_CALL_SERVER_ACK_REQUEST and clear the pending ACK and cancel
     the timer when we start transmitting the reply (the first DATA packet
     of the reply implicitly ACKs the request phase).

 (2) It must be possible to set the timer when the caller is holding
     call->state_lock, so split the lock-getting part of the timer function
     out.

 (3) Add trace notes for the ACK we're requesting and the timer we clear.

Signed-off-by: David Howells <dhowells@redhat.com>
net/rxrpc/ar-internal.h
net/rxrpc/call_event.c
net/rxrpc/misc.c
net/rxrpc/recvmsg.c
net/rxrpc/sendmsg.c