scx_bpf_create_dsq(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… scx_bpf_create_dsq (9) β€” from the Kernel API Manual, bestie 🫢

okay so real talk, this is a kernel-level sched-ext function from the Kernel API Manual, and it's literally the "make me a brand new DSQ" button. custom queue, your own vibes, your own rules. let's get into it πŸ’–


✨ NAME ✨

scx_bpf_create_dsq β€” the one where you create a custom DSQ ✨


πŸ¦‹ SYNOPSIS πŸ¦‹

__bpf_kfunc s32 scx_bpf_create_dsq (u64 dsq_id , s32 node , const struct
       bpf_prog_aux *aux );

like... that's the whole signature, no cap. s32 coming back at you, three args going in 🌸


πŸŽ€ ARGUMENTS πŸŽ€

  • dsq_id β€” the DSQ you wanna create. that's the ID, that's the name tag, that's the whole identity πŸͺͺ
  • node β€” the NUMA node you're allocating from. pick your fave, it's literally a NUMA node choice moment ✨
  • aux β€” ok so this one's implicit. it's the BPF argument that gives you access to bpf_prog_aux, and it is hidden from BPF progs. so your prog doesn't see it, doesn't touch it, it's giving backstage pass energy πŸ™ˆ

πŸ‘‘ DESCRIPTION πŸ‘‘

so you call this, and it creates a custom DSQ identified by dsq_id. that's it, that's the whole flex πŸ’…

where can you call it from? glad you asked bestie:

  • any sleepable scx callback β€” yes, sleepable ones, go off 😴✨
  • any BPF_PROG_TYPE_SYSCALL prog β€” those count too, we love a syscall prog 🫢

and that's the entire description, no filler, no side quests. iconic behaviour honestly 🌈


πŸ’œ SEE ALSO πŸ’œ

okay this list is long long, so buckle up, we're going through all of it, every single one, i'm not skipping a crumb πŸ“

first up, the kernel file itself: ./kernel/sched/ext/ext.c β€” that's where the sauce lives, iykyk πŸ”₯

then the whole friend group:

like i said. everyone's here. the whole extended universe πŸŒŒπŸ’œ


and that's the tea β˜•βœ¨ go create your DSQ bestie, you got this πŸ’…πŸ¦‹

this little gem lives in ./kernel/sched/ext and it's stamped October 2026 β€” so yeah, save the date, screenshot it, whatever, mwah πŸŽ€πŸ’–

πŸ“¦ where this page comes from