scx_bpf_select_cpu_and(9)
scx_bpf_select_cpu_and(9) π β¨
okay so bestie, welcome to the Kernel API Manual, section 9 β this is the page for scx_bpf_select_cpu_and, and it's lowkey just scheduler matchmaking. It picks an idle CPU usable by task @p. no cap. π¦
πΈ NAME πΈ
scx_bpf_select_cpu_and β Pick an idle CPU usable by task @p.
π SYNOPSIS π
here's the signature, exactly as it is, because we do not edit code in this group chat:
s32 scx_bpf_select_cpu_and (struct task_struct *p , s32 prev_cpu , u64
wake_flags , const struct cpumask *cpus_allowed , u64 flags );
π§ ARGUMENTS π§
okay so the cast of characters:
pβtask_structto select a CPU for. main character task energy πprev_cpuβ CPUpwas on previously.wake_flagsβSCX_WAKE_*flags.cpus_allowedβ cpumask of allowed CPUs.flagsβSCX_PICK_IDLE*flags.
π₯ DESCRIPTION π₯
This is an inline wrapper that packs scalar arguments into a struct and calls __scx_bpf_select_cpu_and. That's the whole move, bestie. See __scx_bpf_select_cpu_and for details. π
π SEE ALSO π
- Kernel file
./tools/sched_ext/include/scx/compat.bpf.h __COMPAT_is_enq_cpu_selected(9)scx_bpf_dsq_insert_vtime(9)
okay that's the page! source/version: ./tools/sched_ext/include/scx, date: October 2026. scx_bpf_select_cpu_and(9) out β mwah ππ«Ά
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms