Skip to content

Commit

Permalink
mptcp: try to push pending data on snd una updates
Browse files Browse the repository at this point in the history
After the previous patch we may end-up with unsent data
in the write buffer. If such buffer is full, the writer
will block for unlimited time.

We need to trigger the MPTCP xmit path even for the
subflow rx path, on MPTCP snd_una updates.

Keep things simple and just schedule the work queue if
needed.

Signed-off-by: Paolo Abeni <pabeni@redhat.com>
  • Loading branch information
Paolo Abeni authored and jenkins-tessares committed Oct 24, 2020
1 parent 4ffa002 commit 02822d3
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions net/mptcp/protocol.c
Original file line number Diff line number Diff line change
Expand Up @@ -721,6 +721,7 @@ void mptcp_data_acked(struct sock *sk)
mptcp_reset_timer(sk);

if ((!test_bit(MPTCP_SEND_SPACE, &mptcp_sk(sk)->flags) ||
mptcp_send_head(sk) ||
(inet_sk_state_load(sk) != TCP_ESTABLISHED)))
mptcp_schedule_work(sk);
}
Expand Down Expand Up @@ -1821,6 +1822,8 @@ static void mptcp_worker(struct work_struct *work)
__mptcp_close_subflow(msk);

__mptcp_move_skbs(msk);
if (mptcp_send_head(sk))
mptcp_push_pending(sk, 0);

if (msk->pm.status)
pm_work(msk);
Expand Down

0 comments on commit 02822d3

Please sign in to comment.