diff options
author | Alexander Aring <aahringo@redhat.com> | 2023-05-30 00:44:40 +0300 |
---|---|---|
committer | David Teigland <teigland@redhat.com> | 2023-06-14 18:17:33 +0300 |
commit | 1696c75f1864b338fccbc55f278039d199287ec3 (patch) | |
tree | 68004bc6b2076d4490f0a323654c3ca24271d438 /include/uapi/linux/vboxguest.h | |
parent | d00725cab226491fc347d9bc42b881a0a35419cf (diff) | |
download | linux-1696c75f1864b338fccbc55f278039d199287ec3.tar.xz |
fs: dlm: add send ack threshold and append acks to msgs
This patch changes the time when we sending an ack back to tell the
other side it can free some message because it is arrived on the
receiver node, due random reconnects e.g. TCP resets this is handled as
well on application layer to not let DLM run into a deadlock state.
The current handling has the following problems:
1. We end in situations that we only send an ack back message of 16
bytes out and no other messages. Whereas DLM has logic to combine
so much messages as it can in one send() socket call. This behaviour
can be discovered by "trace-cmd start -e dlm_recv" and observing the
ret field being 16 bytes.
2. When processing of DLM messages will never end because we receive a
lot of messages, we will not send an ack back as it happens when
the processing loop ends.
This patch introduces a likely and unlikely threshold case. The likely
case will send an ack back on a transmit path if the threshold is
triggered of amount of processed upper layer protocol. This will solve
issue 1 because it will be send when another normal DLM message will be
sent. It solves issue 2 because it is not part of the processing loop.
There is however a unlikely case, the unlikely case has a bigger
threshold and will be triggered when we only receive messages and do not
sent any message back. This case avoids that the sending node will keep
a lot of message for a long time as we send sometimes ack backs to tell
the sender to finally release messages.
The atomic cmpxchg() is there to provide a atomically ack send with
reset of the upper layer protocol delivery counter.
Signed-off-by: Alexander Aring <aahringo@redhat.com>
Signed-off-by: David Teigland <teigland@redhat.com>
Diffstat (limited to 'include/uapi/linux/vboxguest.h')
0 files changed, 0 insertions, 0 deletions