blkg_get(9)
π blkg_get(9) β the Kernel API Manual glow-up
Okay so bestie, welcome to blkg_get, a page straight outta the Kernel API Manual. It's short, it's sweet, and it's lowkey the reference-counting baddie you didn't know you needed. Let's get into it β¨
π NAME π
blkg_get β get a blkg reference. That's it. That's the whole vibe. Grab a ref, be the main character π«Ά
β SYNOPSIS β
void blkg_get (struct blkcg_gq *blkg );
Literally one line, no cap. Note the return type is void β she gives you nothing back except the ref itself, and honestly? Iconic π
πΈ ARGUMENTS πΈ
blkgβ the blkg you wanna get a reference on. That's the whole parameter, bestie. Hand it over and let her cook π
π DESCRIPTION π
Okay so here's the situation: the caller should be holding an existing reference.
That's the whole description. She's concise, she's a little mysterious, she knows her worth π The takeaway is you gotta already have a reference in hand before you go calling this β that's the rule, fr fr. Don't come in empty-handed π
π¦ SEE ALSO π¦
Kernel file ./block/blk-cgroup.h β plus the whole friend group, all invited to the function party:
bio_issue_as_root_blkg(9)blkg_lookup(9)blkg_to_pd(9)pd_to_blkg(9)blkg_tryget(9)blkg_put(9)blkg_for_each_descendant_pre(9)blkg_for_each_descendant_post(9)blkcg_set_delay(9)blkcg_clear_delay(9)blk_cgroup_mergeable(9)
Every single one, present and accounted for. Go read them, they're literally right there π§
Ngl the whole page is basically "you should already hold a reference" β so like, do that first? Please? For me? π₯Ί
And that's a wrap, bestie! This adorable little number lives in ./block, and she was blessed upon the world in October 2026, answering to the name blkg_get(9). Slay, stay ref-counted, and remember: hold your reference before you get another one πβ¨π
π¦ 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