Files
agnos-kernel-sdm845/net/ipv4
Eric Dumazet 5f63431093 tcp: remove poll() flakes with FastOpen
[ Upstream commit 0f9fa831aecfc297b7b45d4f046759bcefcf87f0 ]

When using TCP FastOpen for an active session, we send one wakeup event
from tcp_finish_connect(), right before the data eventually contained in
the received SYNACK is queued to sk->sk_receive_queue.

This means that depending on machine load or luck, poll() users
might receive POLLOUT events instead of POLLIN|POLLOUT

To fix this, we need to move the call to sk->sk_state_change()
after the (optional) call to tcp_rcv_fastopen_synack()

Signed-off-by: Eric Dumazet <edumazet@google.com>
Acked-by: Yuchung Cheng <ycheng@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-03-24 11:00:12 +01:00
..
2017-11-18 11:22:22 +01:00
2016-10-20 14:32:22 -04:00
2016-09-21 00:23:01 -04:00
2017-05-03 08:36:34 -07:00
2017-11-18 11:22:22 +01:00
2017-05-14 14:00:21 +02:00
2016-09-01 14:09:01 -07:00
2017-06-17 06:41:49 +02:00
2015-09-17 17:18:37 -07:00