diff options
author | David Howells <dhowells@redhat.com> | 2023-01-31 21:40:18 +0000 |
---|---|---|
committer | David Howells <dhowells@redhat.com> | 2023-02-07 23:11:21 +0000 |
commit | 5a2c5a5b0829ef8bcb5d868145c1d8c1221c5637 (patch) | |
tree | 441da5c8f36a3c989c34f698746e1a00ff993976 /tools/perf/scripts/python/export-to-postgresql.py | |
parent | f789bff2deb3ddae08950f8e4a1e6f41b916c520 (diff) |
rxrpc: Reduce unnecessary ack transmission
rxrpc_recvmsg_data() schedules an ACK to be transmitted every time at least
two packets have been consumed and any time it runs out of data and would
return -EAGAIN to the caller. Both events may occur within a single loop,
however, and if the I/O thread is quick enough it may send duplicate ACKs.
The ACKs are sent to inform the peer that more space has been made in the
local Rx window, but the I/O thread is going to send an ACK every couple of
DATA packets anyway, so we end up sending a lot more ACKs than we really
need to.
So reduce the rate at which recvmsg() schedules ACKs, such that if the I/O
thread sends ACKs at its normal faster rate, recvmsg() won't actually
schedule ACKs until the Rx flow stops (call->rx_consumed is cleared any
time we transmit an ACK for that call, resetting the counter used by
recvmsg).
Signed-off-by: David Howells <dhowells@redhat.com>
cc: Marc Dionne <marc.dionne@auristor.com>
cc: linux-afs@lists.infradead.org
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions