Skip to content

Commit

Permalink
tcp: consistently disable header prediction for mptcp
Browse files Browse the repository at this point in the history
The MPTCP receive path is hooked only into the TCP slow-path.
The DSS presence allows plain MPTCP traffic to hit that
consistently.

Since commit e1ff9e8 ("net: mptcp: improve fallback to TCP"),
when and MPTCP socket falls back to TCP, we can the receive
fast path, and delay or stop triggering the event notification.

Address the issue explicitly disabling the header prediction
for MPTCP sockets.

Closes: #200
Fixes: e1ff9e8 ("net: mptcp: improve fallback to TCP")
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
  • Loading branch information
Paolo Abeni authored and jenkins-tessares committed Jul 1, 2021
1 parent 513b48d commit fac3dbc
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions include/net/tcp.h
Original file line number Diff line number Diff line change
Expand Up @@ -686,6 +686,10 @@ static inline u32 __tcp_set_rto(const struct tcp_sock *tp)

static inline void __tcp_fast_path_on(struct tcp_sock *tp, u32 snd_wnd)
{
/* mptcp hooks are only on the slow path */
if (sk_is_mptcp((struct sock *)tp))
return;

tp->pred_flags = htonl((tp->tcp_header_len << 26) |
ntohl(TCP_FLAG_ACK) |
snd_wnd);
Expand Down

0 comments on commit fac3dbc

Please sign in to comment.