mptcp: Check connection state before attempting send
authorMat Martineau <mathew.j.martineau@linux.intel.com>
Fri, 28 Feb 2020 23:47:39 +0000 (15:47 -0800)
committerDavid S. Miller <davem@davemloft.net>
Wed, 4 Mar 2020 01:01:42 +0000 (17:01 -0800)
commit1954b86016cf8522970e1b7aba801233d777ec47
treee4c88f18cf8e12994126df67a317d7ec6b5be575
parent0a303214f8cb8e2043a03f7b727dba620e07e68d
mptcp: Check connection state before attempting send

MPTCP should wait for an active connection or skip sending depending on
the connection state, as TCP does. This happens before the possible
passthrough to a regular TCP sendmsg because the subflow's socket type
(MPTCP or TCP fallback) is not known until the connection is
complete. This is also relevent at disconnect time, where data should
not be sent in certain MPTCP-level connection states.

Signed-off-by: Mat Martineau <mathew.j.martineau@linux.intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/mptcp/protocol.c