MPTCP Linux Development
 help / color / mirror / Atom feed
* [PATCH mptcp-next v7 0/2] mptcp: add scheduler-owned subflow avoid flag
@ 2026-11-23 12:37 Kalpan Jani
  2026-11-23 12:37 ` [PATCH mptcp-next v7 1/2] mptcp: sched: add subflow avoid flag for BPF schedulers Kalpan Jani
  2026-11-23 12:37 ` [PATCH mptcp-next v7 2/2] selftests: mptcp: bpf: exercise the subflow avoid flag across rounds Kalpan Jani
  0 siblings, 2 replies; 5+ messages in thread
From: Kalpan Jani @ 2026-11-23 12:37 UTC (permalink / raw)
  To: mptcp; +Cc: shardul.b, janak, kalpanjani009, Kalpan Jani

The MPTCP scheduler needs a persistent way for BPF schedulers to
mark a subflow as one that should be avoided across scheduling
rounds.

The existing stale and scheduled states do not provide this
scheduler-owned behaviour.

This series introduces an avoid flag in mptcp_subflow_context,
exposes it to BPF struct_ops schedulers through a kfunc, and
exports its state through MPTCP diagnostics.

BPF schedulers can set the flag and must explicitly check it when
selecting subflows. The flag does not change the behaviour of the
default in-kernel scheduler.

The second patch adds a BPF struct_ops selftest that marks a
subflow as avoided once and verifies that it remains skipped
across subsequent scheduling rounds.

Changes since v6:
- Removed unreachable avoid checks from the default send and
  retransmission subflow pickers.
- Clarified that BPF schedulers must explicitly honour the
  avoid flag.
- Updated the first patch description to reflect BPF scheduler
  ownership.

Kalpan Jani (2):
  mptcp: sched: add subflow avoid flag for BPF schedulers
  selftests: mptcp: bpf: exercise the subflow avoid flag across rounds

 include/uapi/linux/mptcp.h                    |  1 +
 net/mptcp/bpf.c                               |  1 +
 net/mptcp/diag.c                              |  2 +
 net/mptcp/protocol.h                          |  3 +
 net/mptcp/sched.c                             |  6 ++
 .../testing/selftests/bpf/prog_tests/mptcp.c  | 15 ++++
 .../selftests/bpf/progs/mptcp_bpf_avoid.c     | 87 +++++++++++++++++++
 7 files changed, 115 insertions(+)
 create mode 100644 tools/testing/selftests/bpf/progs/mptcp_bpf_avoid.c

-- 
2.43.0


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-11-23 12:52 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-23 12:37 [PATCH mptcp-next v7 0/2] mptcp: add scheduler-owned subflow avoid flag Kalpan Jani
2026-11-23 12:37 ` [PATCH mptcp-next v7 1/2] mptcp: sched: add subflow avoid flag for BPF schedulers Kalpan Jani
2026-11-23 12:47   ` sashiko-bot
2026-11-23 12:37 ` [PATCH mptcp-next v7 2/2] selftests: mptcp: bpf: exercise the subflow avoid flag across rounds Kalpan Jani
2026-11-23 12:52   ` sashiko-bot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox