[PATCH mptcp-next 0/4] BPF 'force to MPTCP'

Geliang Tang posted 4 patches 10 months, 1 week ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/multipath-tcp/mptcp_net-next tags/patchew/cover.1688004307.git.geliang.tang@suse.com
Maintainers: Alexei Starovoitov <ast@kernel.org>, Daniel Borkmann <daniel@iogearbox.net>, John Fastabend <john.fastabend@gmail.com>, Andrii Nakryiko <andrii@kernel.org>, Martin KaFai Lau <martin.lau@linux.dev>, Song Liu <song@kernel.org>, Yonghong Song <yhs@fb.com>, KP Singh <kpsingh@kernel.org>, Stanislav Fomichev <sdf@google.com>, Hao Luo <haoluo@google.com>, Jiri Olsa <jolsa@kernel.org>, Steven Rostedt <rostedt@goodmis.org>, Masami Hiramatsu <mhiramat@kernel.org>, "David S. Miller" <davem@davemloft.net>, Eric Dumazet <edumazet@google.com>, Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>, Mykola Lysenko <mykolal@fb.com>, Shuah Khan <shuah@kernel.org>, Matthieu Baerts <matthieu.baerts@tessares.net>, Mat Martineau <martineau@kernel.org>
There is a newer version of this series
include/linux/bpf.h                           |   1 +
include/uapi/linux/bpf.h                      |   7 +
kernel/bpf/verifier.c                         |   1 +
kernel/trace/bpf_trace.c                      |   2 +
net/core/filter.c                             |  21 +++
scripts/bpf_doc.py                            |   1 +
tools/include/uapi/linux/bpf.h                |   7 +
tools/testing/selftests/bpf/bpf_tcp_helpers.h |   1 +
.../testing/selftests/bpf/prog_tests/mptcp.c  | 123 +++++++++++++++---
tools/testing/selftests/bpf/progs/mptcpify.c  |  32 +++++
10 files changed, 176 insertions(+), 20 deletions(-)
create mode 100644 tools/testing/selftests/bpf/progs/mptcpify.c
[PATCH mptcp-next 0/4] BPF 'force to MPTCP'
Posted by Geliang Tang 10 months, 1 week ago
This series depends on the two netns patches, should be inserted before
the BPF scheduler series:
  selftests/bpf: use random netns name for mptcp
  selftests/bpf: add two mptcp netns helpers
  bpf: Add bpf_mptcpify helper
  selftests/bpf: Test bpf_mptcpify helper
  selftests/bpf: Add mptcpify selftest
  mptcp: refactor push_pending logic

Closes: https://github.com/multipath-tcp/mptcp_net-next/issues/79

Geliang Tang (4):
  Squash to "selftests/bpf: add two mptcp netns helpers"
  bpf: Add bpf_mptcpify helper
  selftests/bpf: Test bpf_mptcpify helper
  selftests/bpf: Add mptcpify selftest

 include/linux/bpf.h                           |   1 +
 include/uapi/linux/bpf.h                      |   7 +
 kernel/bpf/verifier.c                         |   1 +
 kernel/trace/bpf_trace.c                      |   2 +
 net/core/filter.c                             |  21 +++
 scripts/bpf_doc.py                            |   1 +
 tools/include/uapi/linux/bpf.h                |   7 +
 tools/testing/selftests/bpf/bpf_tcp_helpers.h |   1 +
 .../testing/selftests/bpf/prog_tests/mptcp.c  | 123 +++++++++++++++---
 tools/testing/selftests/bpf/progs/mptcpify.c  |  32 +++++
 10 files changed, 176 insertions(+), 20 deletions(-)
 create mode 100644 tools/testing/selftests/bpf/progs/mptcpify.c

-- 
2.35.3
Re: [PATCH mptcp-next 0/4] BPF 'force to MPTCP'
Posted by Paolo Abeni 10 months ago
Hi Geliang,

On Thu, 2023-06-29 at 10:12 +0800, Geliang Tang wrote:
> This series depends on the two netns patches, should be inserted before
> the BPF scheduler series:
>   selftests/bpf: use random netns name for mptcp
>   selftests/bpf: add two mptcp netns helpers
>   bpf: Add bpf_mptcpify helper
>   selftests/bpf: Test bpf_mptcpify helper
>   selftests/bpf: Add mptcpify selftest
>   mptcp: refactor push_pending logic
> 
> Closes: https://github.com/multipath-tcp/mptcp_net-next/issues/79

Again sorry for the possibly late feedback.

Before investing more time on this topic, are there any issues with the
current tools available (mainly: 'mptcpize') that need to be addressed?

Otherwise we would possibly better off not adding more code to the
kernel for such goal.

/P
Re: [PATCH mptcp-next 0/4] BPF 'force to MPTCP'
Posted by Matthieu Baerts 10 months ago
Hi Paolo,

On 03/07/2023 17:18, Paolo Abeni wrote:
> Hi Geliang,
> 
> On Thu, 2023-06-29 at 10:12 +0800, Geliang Tang wrote:
>> This series depends on the two netns patches, should be inserted before
>> the BPF scheduler series:
>>   selftests/bpf: use random netns name for mptcp
>>   selftests/bpf: add two mptcp netns helpers
>>   bpf: Add bpf_mptcpify helper
>>   selftests/bpf: Test bpf_mptcpify helper
>>   selftests/bpf: Add mptcpify selftest
>>   mptcp: refactor push_pending logic
>>
>> Closes: https://github.com/multipath-tcp/mptcp_net-next/issues/79
> 
> Again sorry for the possibly late feedback.
> 
> Before investing more time on this topic, are there any issues with the
> current tools available (mainly: 'mptcpize') that need to be addressed?

I don't have specific use cases for having bpf_mptcpize but I know the
"original" mptcpize doesn't not work in some cases:

- if the application is not using libc (e.g. GoLang apps)
- in some envs, it might not be easy to set env vars, e.g. on Android
- it needs to be launched with all apps that wants MPTCP: we can have
more control from BPF to enable MPTCP only for some apps or all the ones
of a netns or a cgroup, etc.
- it is not in BPF, we cannot talk about it at netdev conf (:-D)

Even if I agree mptcpize can help a lot, having bpf_mptcpize seems to
help in some other cases.

Cheers,
Matt
-- 
Tessares | Belgium | Hybrid Access Solutions
www.tessares.net