From: Jakub Kicinski <jakub.kicin...@netronome.com> Date: Thu, 1 Aug 2019 14:36:01 -0700
> Looks like we were slightly overzealous with the shutdown() > cleanup. Even though the sock->sk_state can reach CLOSED again, > socket->state will not got back to SS_UNCONNECTED once > connections is ESTABLISHED. Meaning we will see EISCONN if > we try to reconnect, and EINVAL if we try to listen. > > Only listen sockets can be shutdown() and reused, but since > ESTABLISHED sockets can never be re-connected() or used for > listen() we don't need to try to clean up the ULP state early. > > Fixes: 32857cf57f92 ("net/tls: fix transition through disconnect with close") > Signed-off-by: Jakub Kicinski <jakub.kicin...@netronome.com> Applied and queued up for -stable.