rdmacg_event_locked(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… rdmacg_event_locked β€” like, the Kernel API Manual one, bestie

okay so we're in the Kernel API Manual today and the star of the show is rdmacg_event_locked β€” say that five times fast, i actually can't 😭


✨ NAME ✨

rdmacg_event_locked β€” fire an event when a resource allocation goes over the limit πŸ”₯


🌸 SYNOPSIS 🌸

void rdmacg_event_locked (struct rdma_cgroup *cg , struct rdma_cgroup
*over_cg , struct rdmacg_device *device , enum rdmacg_resource_type
index );

like yes bestie it returns void, it's giving "i just do my thing and leave" πŸ’…


πŸŽ€ ARGUMENTS πŸŽ€

  • cg β€” the cgroup that's doing the requesting, aka the one asking for stuff 🫢
  • over_cg β€” the cgroup whose limit got exceeded, rip to her honestly πŸ’€
  • device β€” the rdma device, the whole reason we're here ✨
  • index β€” the resource type index, like which resource we're talking about πŸ¦‹

🌈 DESCRIPTION 🌈

okay so the one thing you cannot skip: this must be called under rdmacg_mutex. no cap. that's the vibe check and you have to pass it πŸ”’

once you're in there, here's the whole little routine she runs:

  • updates the event counters in the resource pools of cg and over_cg πŸ‘‘
  • propagates hierarchical max events from over_cg (including itself, yes, herself too, main character energy) upward ⬆️
  • notifies userspace via cgroup_file_notify πŸ“£

that's it, that's the whole function, and honestly? she ate πŸ’–


🧚 SEE ALSO 🧚

Kernel file ./kernel/cgroup/rdma.c

like go read those too, iykyk πŸ“


fr fr: if you're not holding rdmacg_mutex when you call this, you're doing it wrong and i will be judging you πŸ™ˆ

and that's the whole page bestie!! sourced from ./kernel/cgroup, dated October 2026, all wrapped up in rdmacg_event_locked(9) β€” mwah, slay, periodt πŸ’œπŸŽ€βœ¨

πŸ“¦ where this page comes from