Skip to content

Commit 65b0226

Browse files
matttbekuba-moo
authored andcommitted
mptcp: export mptcp_subflow_early_fallback()
This helper will be used outside protocol.h in the following commit. While at it, also add a 'pr_fallback()' debug print, to help identifying fallbacks. Signed-off-by: Matthieu Baerts (NGI0) <[email protected]> Link: https://patch.msgid.link/20240909-net-next-mptcp-fallback-x-mpc-v1-1-da7ebb4cd2a3@kernel.org Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 8b5d2e5 commit 65b0226

File tree

2 files changed

+8
-7
lines changed

2 files changed

+8
-7
lines changed

net/mptcp/protocol.c

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3717,13 +3717,6 @@ static int mptcp_ioctl(struct sock *sk, int cmd, int *karg)
37173717
return 0;
37183718
}
37193719

3720-
static void mptcp_subflow_early_fallback(struct mptcp_sock *msk,
3721-
struct mptcp_subflow_context *subflow)
3722-
{
3723-
subflow->request_mptcp = 0;
3724-
__mptcp_do_fallback(msk);
3725-
}
3726-
37273720
static int mptcp_connect(struct sock *sk, struct sockaddr *uaddr, int addr_len)
37283721
{
37293722
struct mptcp_subflow_context *subflow;

net/mptcp/protocol.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1215,6 +1215,14 @@ static inline void mptcp_do_fallback(struct sock *ssk)
12151215

12161216
#define pr_fallback(a) pr_debug("%s:fallback to TCP (msk=%p)\n", __func__, a)
12171217

1218+
static inline void mptcp_subflow_early_fallback(struct mptcp_sock *msk,
1219+
struct mptcp_subflow_context *subflow)
1220+
{
1221+
pr_fallback(msk);
1222+
subflow->request_mptcp = 0;
1223+
__mptcp_do_fallback(msk);
1224+
}
1225+
12181226
static inline bool mptcp_check_infinite_map(struct sk_buff *skb)
12191227
{
12201228
struct mptcp_ext *mpext;

0 commit comments

Comments
 (0)