Sched_ext development
 help / color / mirror / Atom feed
* [GIT PULL] sched_ext changes for v7.2
@ 2026-06-15 22:56 Tejun Heo
  2026-06-17 11:19 ` Linus Torvalds
  2026-06-17 11:25 ` pr-tracker-bot
  0 siblings, 2 replies; 4+ messages in thread
From: Tejun Heo @ 2026-06-15 22:56 UTC (permalink / raw)
  To: Linus Torvalds
  Cc: sched-ext, David Vernet, Andrea Righi, Changwoo Min,
	Emil Tsalapatis, linux-kernel

Hello,

The following changes since commit 53cc12a2dc88c2c6f62f507548640885a70a56a8:

  bpf/arena: Add bpf_arena_map_kern_vm_start() and bpf_prog_arena() (2026-05-23 01:50:33 -0700)

are available in the Git repository at:

  https://git.kernel.org/pub/scm/linux/kernel/git/tj/sched_ext.git tags/sched_ext-for-7.2

for you to fetch changes up to 2e05f2fd0dd72aa8aa56cf355e1e39a3f565b4ca:

  sched_ext: Add scx_arena_to_kaddr() / scx_kaddr_to_arena() (2026-06-03 23:57:03 -1000)

----------------------------------------------------------------
sched_ext: Changes for v7.2

This depends on the BPF arena work in bpf-next and should be pulled after
it. for-7.1-fixes was merged in a few times to avoid conflicts with the
feature changes.

- Most of this continues the in-development sub-scheduler support, which
  lets a root BPF scheduler delegate to nested sub-schedulers. The
  dispatch-path building blocks landed in 7.1. A follow-up patchset in
  development will complete enqueue-path support for hierarchical
  scheduling. This cycle adds most of that infrastructure:

  - Topological CPU IDs (cids): a dense, topology-ordered CPU numbering
    where the CPUs of a core, LLC, or NUMA node form contiguous ranges,
    so a topology unit becomes a (start, length) slice. Raw CPU numbers
    are sparse and don't track topological closeness, which makes them
    clumsy for sharding work across sub-schedulers and awkward in BPF.

  - cmask: bitmaps windowed over a slice of cid space, so a sub-scheduler
    can track, for example, the idle cids of its shard without a full
    NR_CPUS cpumask.

  - A struct_ops variant that cid-form sub-schedulers register with,
    along with the cid-form kfuncs they call.

  - BPF arena integration, which sub-scheduler support is built on. The
    bpf-next additions let the kernel read and write the BPF scheduler's
    arena directly, turning it into a real kernel/BPF shared-memory
    channel. Shared state like the per-CPU cmask now lives there.

  - scx_qmap is reworked to exercise the new arena and cid interfaces.

- Exit-dump improvements: dump the faulting CPU first, expose the exit
  CPU to BPF and userspace, and normalize the dump header.

- Misc kfuncs and cleanups: a task-ID lookup kfunc, __printf checking on
  the error and dump formatters, header reorganization, and assorted
  fixes.

----------------------------------------------------------------
Andrea Righi (1):
      sched_ext: Replace tryget_task_struct() with get_task_struct()

Changwoo Min (3):
      sched_ext: Extract scx_dump_cpu() from scx_dump_state()
      sched_ext: Dump the exit CPU first
      sched_ext: Expose exit_cpu to BPF and userspace

Cheng-Yang Chou (9):
      tools/sched_ext: Handle migration-disabled tasks in scx_central
      tools/sched_ext: Remove dead -d option in scx_flatcg
      sched_ext: Documentation: clarify arena-backed doubly-linked lists in scx_qmap
      tools/sched_ext: Remove unused nr_cpus in scx_cpu0
      sched_ext: Normalize exit dump header to "on CPU N"
      selftests/sched_ext: Fix select_cpu_dfl link leak on early return
      tools/sched_ext: scx_qmap: Fix qa arena placement
      sched_ext: idle: Fix errno loss in scx_idle_init()
      selftests/sched_ext: Fix dsq_move_to_local check

Kuba Piecuch (1):
      sched_ext: Documentation: add note about multiple ops.enqueue() calls in a row

Tejun Heo (50):
      sched_ext: scx_qmap: rename tctx to taskc
      sched_ext: scx_qmap: move globals and cpu_ctx into a BPF arena map
      sched_ext: scx_qmap: move task_ctx into a BPF arena slab
      sched_ext: scx_qmap: replace FIFO queue maps with arena-backed lists
      sched_ext: Document the ops compat strategy in compat.h/compat.bpf.h
      Merge branch 'for-7.1-fixes' into for-7.2
      sched_ext: add p->scx.tid and SCX_OPS_TID_TO_TASK lookup
      Merge branch 'for-7.1-fixes' into for-7.2
      Merge branch 'for-7.1-fixes' into for-7.2
      Merge branch 'for-7.1-fixes' into for-7.2
      Merge branch 'for-7.1-fixes' into for-7.2
      sched_ext: Collect ext_*.c include headers in build_policy.c
      sched_ext: Add ext_types.h for early subsystem-wide defs
      sched_ext: Rename ops_cpu_valid() to scx_cpu_valid() and expose it
      sched_ext: Move scx_exit(), scx_error() and friends to ext_internal.h
      sched_ext: Shift scx_kick_cpu() validity check to scx_bpf_kick_cpu()
      sched_ext: Relocate cpu_acquire/cpu_release to end of struct sched_ext_ops
      sched_ext: Make scx_enable() take scx_enable_cmd
      sched_ext: Add topological CPU IDs (cids)
      sched_ext: Add scx_bpf_cid_override() kfunc
      tools/sched_ext: Add struct_size() helpers to common.bpf.h
      sched_ext: Add cmask, a base-windowed bitmap over cid space
      sched_ext: Add cid-form kfunc wrappers alongside cpu-form
      sched_ext: Add bpf_sched_ext_ops_cid struct_ops type
      sched_ext: Forbid cpu-form kfuncs from cid-form schedulers
      tools/sched_ext: scx_qmap: Restart on hotplug instead of cpu_online/offline
      tools/sched_ext: scx_qmap: Add cmask-based idle tracking and cid-based idle pick
      tools/sched_ext: scx_qmap: Port to cid-form struct_ops
      sched_ext: Require cid-form struct_ops for sub-sched support
      sched_ext: Add __printf format attributes to scx_vexit() and bstr formatters
      sched_ext: Use offsetofend on both sides of the ops_cid layout assert
      sched_ext: Fix ops_cid layout assert
      sched_ext: Add scx_task_iter_relock() and use it in scx_root_enable_workfn()
      Merge branch 'for-7.1-fixes' into for-7.2
      sched_ext: Mark !CONFIG_EXT_SUB_SCHED dummy stubs static inline
      Merge branch 'for-7.1-fixes' into for-7.2
      Merge branch 'for-7.1-fixes' into for-7.2
      sched_ext: Rename scx_cmask.nr_bits to nr_cids
      sched_ext: Track bits[] storage size in struct scx_cmask
      sched_ext: Add cmask mask ops
      Merge branch 'arena_direct_access' of git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next into for-7.2
      sched_ext: Require an arena for cid-form schedulers
      sched_ext: Sub-allocator over kernel-claimed BPF arena pages
      sched_ext: Convert ops.set_cmask() to arena-resident cmask
      sched_ext: Guard BPF arena helper calls to fix 32-bit build
      sched_ext: Order single-cid cmask helpers as (cid, mask)
      tools/sched_ext: Order single-cid cmask helpers as (cid, mask)
      sched_ext: Add scx_cmask_test() and scx_cmask_for_each_cid()
      sched_ext: Make scx_bpf_kick_cid() return s32
      sched_ext: Add scx_arena_to_kaddr() / scx_kaddr_to_arena()

Zhao Mengmeng (3):
      tools/sched_ext: Add missing -c option in scx_qmap help
      sched_ext: Print sub-scheduler disabled log and reason
      selftests/sched_ext: Include common.bpf.h to avoid build failure

Zqiang (1):
      sched_ext: Remove redundant rcu_read_lock/unlock() in sysrq_handle_sched_ext_reset()

 Documentation/scheduler/sched-ext.rst              |    7 +-
 include/linux/sched/ext.h                          |    9 +
 kernel/sched/build_policy.c                        |    9 +
 kernel/sched/ext.c                                 | 1261 ++++++++++++++++----
 kernel/sched/ext_arena.c                           |  131 ++
 kernel/sched/ext_arena.h                           |   18 +
 kernel/sched/ext_cid.c                             |  707 +++++++++++
 kernel/sched/ext_cid.h                             |  271 +++++
 kernel/sched/ext_idle.c                            |   23 +-
 kernel/sched/ext_internal.h                        |  280 ++++-
 kernel/sched/ext_types.h                           |  144 +++
 tools/sched_ext/README.md                          |    6 +-
 tools/sched_ext/include/scx/cid.bpf.h              |  678 +++++++++++
 tools/sched_ext/include/scx/common.bpf.h           |   28 +
 tools/sched_ext/include/scx/compat.bpf.h           |   30 +-
 tools/sched_ext/include/scx/compat.h               |   23 +-
 tools/sched_ext/include/scx/user_exit_info.bpf.h   |    3 +
 tools/sched_ext/include/scx/user_exit_info.h       |    2 +
 .../sched_ext/include/scx/user_exit_info_common.h  |    5 +
 tools/sched_ext/scx_central.bpf.c                  |   10 +-
 tools/sched_ext/scx_cpu0.bpf.c                     |    2 -
 tools/sched_ext/scx_cpu0.c                         |    2 -
 tools/sched_ext/scx_flatcg.c                       |   12 +-
 tools/sched_ext/scx_qmap.bpf.c                     |  890 ++++++++------
 tools/sched_ext/scx_qmap.c                         |  107 +-
 tools/sched_ext/scx_qmap.h                         |   73 ++
 .../selftests/sched_ext/non_scx_kfunc_deny.bpf.c   |    7 +-
 tools/testing/selftests/sched_ext/peek_dsq.bpf.c   |    2 +-
 tools/testing/selftests/sched_ext/select_cpu_dfl.c |   54 +-
 29 files changed, 4090 insertions(+), 704 deletions(-)
 create mode 100644 kernel/sched/ext_arena.c
 create mode 100644 kernel/sched/ext_arena.h
 create mode 100644 kernel/sched/ext_cid.c
 create mode 100644 kernel/sched/ext_cid.h
 create mode 100644 kernel/sched/ext_types.h
 create mode 100644 tools/sched_ext/include/scx/cid.bpf.h
 create mode 100644 tools/sched_ext/scx_qmap.h

--
tejun

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

end of thread, other threads:[~2026-06-17 16:55 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-15 22:56 [GIT PULL] sched_ext changes for v7.2 Tejun Heo
2026-06-17 11:19 ` Linus Torvalds
2026-06-17 16:55   ` Tejun Heo
2026-06-17 11:25 ` pr-tracker-bot

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