diff options
author | Paolo Abeni <pabeni@redhat.com> | 2022-01-07 03:20:14 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2022-01-07 14:27:06 +0300 |
commit | 58cd405b83b388c75a4c24926e5d4aeae8d1eaf5 (patch) | |
tree | 31186773f148b0b7022ce019d1842ecdd0bcdad7 /net/mptcp/protocol.c | |
parent | 26abf15c49e0fbbcb6dbd70c52ecbde221f1b0fa (diff) | |
download | linux-58cd405b83b388c75a4c24926e5d4aeae8d1eaf5.tar.xz |
mptcp: keep snd_una updated for fallback socket
After shutdown, for fallback MPTCP sockets, we always have
write_seq == snd_una+1
The above will foul OUTQ ioctl(). Keep snd_una in sync with
write_seq even after shutdown.
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Mat Martineau <mathew.j.martineau@linux.intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/mptcp/protocol.c')
-rw-r--r-- | net/mptcp/protocol.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/net/mptcp/protocol.c b/net/mptcp/protocol.c index df5a0cf431c1..f6fc0f0f66f0 100644 --- a/net/mptcp/protocol.c +++ b/net/mptcp/protocol.c @@ -2666,6 +2666,7 @@ static void __mptcp_check_send_data_fin(struct sock *sk) * state now */ if (__mptcp_check_fallback(msk)) { + WRITE_ONCE(msk->snd_una, msk->write_seq); if ((1 << sk->sk_state) & (TCPF_CLOSING | TCPF_LAST_ACK)) { inet_sk_state_store(sk, TCP_CLOSE); mptcp_close_wake_up(sk); |