__SCX_CMASK_DEFINE(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ __SCX_CMASK_DEFINE ✨

okay bestie, gather round πŸ’– this is a page from the Kernel API Manual and it's genuinely so cute β€” it's all about defining an on-stack cmask with explicit storage capacity. no cap, it's a little macro with main character energy πŸ‘‘


πŸŽ€ SYNOPSIS πŸŽ€

__SCX_CMASK_DEFINE (NAME , BASE , NR_CIDS , ALLOC_CIDS );

🌸 ARGUMENTS 🌸

  • NAME β€” the variable name you're defining, periodt. that's literally its whole job πŸ’…
  • BASE β€” the first cid of the active range πŸ”₯
  • NR_CIDS β€” the length of the active range, iykyk πŸ“
  • ALLOC_CIDS β€” the storage capacity in cids, and it's gotta be at least NR_CIDS β€” no shrinking below that, fr fr ⚠️

πŸ¦‹ DESCRIPTION πŸ¦‹

so NAME aliases zero-initialized storage ✨ with the active range set to [BASE, BASE + NR_CIDS). that's it, that's the vibe 🫢

and then later, when you want a different shape? use scx_cmask_reframe to reshape it β€” up to ALLOC_CIDS, bestie πŸ’œ


🌈 SEE ALSO 🌈


lowkey obsessed with how tidy this macro is. go forth and define your cmasks, icon 🧚

and that's the whole page, bestie πŸ“ sign-off time: this one lives in ./kernel/sched/ext, and it's dated October 2026 β€” πŸ’– bye babes πŸ’–

πŸ“¦ where this page comes from