Skip to content

Commit

Permalink
Squash-to: "mptcp: handle consistently DSS corruption"
Browse files Browse the repository at this point in the history
Instead of re-inventing the wheel, use the flag we already
track to easily check if fallback is allowed.

Note that we could not check conn_list in a reliable way,
as the call side is not under the msk socket lock.

Signed-off-by: Paolo Abeni <[email protected]>
  • Loading branch information
Paolo Abeni authored and intel-lab-lkp committed Oct 2, 2024
1 parent ecea735 commit abaa958
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/mptcp/protocol.c
Original file line number Diff line number Diff line change
Expand Up @@ -622,7 +622,7 @@ static bool mptcp_check_data_fin(struct sock *sk)

static void mptcp_dss_corruption(struct mptcp_sock *msk, struct sock *ssk)
{
if (list_is_singular(&msk->conn_list) && msk->first == ssk) {
if (READ_ONCE(msk->allow_infinite_fallback)) {
MPTCP_INC_STATS(sock_net(ssk),
MPTCP_MIB_DSSCORRUPTIONFALLBACK);
mptcp_do_fallback(ssk);
Expand Down

0 comments on commit abaa958

Please sign in to comment.