Skip to content
Commit d68be71e authored by Davide Caratti's avatar Davide Caratti Committed by David S. Miller
Browse files

tcp: fix access to sk->sk_state in tcp_poll()



avoid direct access to sk->sk_state when tcp_poll() is called on a socket
using active TCP fastopen with deferred connect. Use local variable
'state', which stores the result of sk_state_load(), like it was done in
commit 00fd38d9 ("tcp: ensure proper barriers in lockless contexts").

Fixes: 19f6d3f3 ("net/tcp-fastopen: Add new API support")
Signed-off-by: default avatarDavide Caratti <dcaratti@redhat.com>
Acked-by: default avatarWei Wang <weiwan@google.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent d1f496fd
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment