]> www.infradead.org Git - users/hch/xfs.git/commit
mptcp: don't always assume copied data in mptcp_cleanup_rbuf()
authorPaolo Abeni <pabeni@redhat.com>
Mon, 30 Dec 2024 18:12:31 +0000 (19:12 +0100)
committerJakub Kicinski <kuba@kernel.org>
Fri, 3 Jan 2025 02:44:03 +0000 (18:44 -0800)
commit551844f26da2a9f76c0a698baaffa631d1178645
tree3077e1393ba2f7d3ce48590133e90e69aa366d3f
parent449e6912a2522af672e99992e1201a454910864e
mptcp: don't always assume copied data in mptcp_cleanup_rbuf()

Under some corner cases the MPTCP protocol can end-up invoking
mptcp_cleanup_rbuf() when no data has been copied, but such helper
assumes the opposite condition.

Explicitly drop such assumption and performs the costly call only
when strictly needed - before releasing the msk socket lock.

Fixes: fd8976790a6c ("mptcp: be careful on MPTCP-level ack.")
Cc: stable@vger.kernel.org
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Reviewed-by: Mat Martineau <martineau@kernel.org>
Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
Link: https://patch.msgid.link/20241230-net-mptcp-rbuf-fixes-v1-2-8608af434ceb@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
net/mptcp/protocol.c