OSDN Git Service

net/smc: correct state change for peer closing
authorUrsula Braun <ubraun@linux.ibm.com>
Mon, 4 Feb 2019 12:44:47 +0000 (13:44 +0100)
committerDavid S. Miller <davem@davemloft.net>
Mon, 4 Feb 2019 17:11:19 +0000 (09:11 -0800)
commit84b799a292ebc03de388f8573a169de6eb12c340
treef49331673908a7f6d271c643a9203db7fd106d92
parenta5e04318c83a31925300af1ce358dbc1a708b732
net/smc: correct state change for peer closing

If some kind of closing is received from the peer while still in
state SMC_INIT, it means the peer has had an active connection and
closed the socket quickly before listen_work finished. This should
not result in a shortcut from state SMC_INIT to state SMC_CLOSED.
This patch adds the socket to the accept queue in state
SMC_APPCLOSEWAIT1. The socket reaches state SMC_CLOSED once being
accepted and closed with smc_release().

Signed-off-by: Ursula Braun <ubraun@linux.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/smc/smc_close.c