devlink_regi...pshot_id_put(9)
π devlink_region_snapshot_id_put(9) β from the Kernel API Manual β¨
okay so bestie, welcome to the kernel API manual, and specifically to devlink_region_snapshot_id_put(9) β yes the title's a little truncated in the header (devlink_regi...pshot_id_put(9)), she's just being mysterious, it's her brand π. This is the page that tells you how to put a snapshot ID reference down. Gently. Responsibly. Like putting your emotional baggage down after therapy π¦.
πΈ NAME πΈ
devlink_region_snapshot_id_put β put snapshot ID reference
Like, "put" as in release, not "put" as in "put it on the shelf". Think of it as the anti-get. The vibe is closure π
.
β SYNOPSIS β
void devlink_region_snapshot_id_put (struct devlink *devlink , u32 id );
That's the whole function, no cap. Returns void, so she's not giving you any feedback. Iconic, honestly.
π ARGUMENTS π
devlinkβ devlink. (Yeah bestie, that's genuinely it β it's thestruct devlink *you're working with. She's not complicated, she's just there π«Ά)idβ id to release reference on. That's theu32snapshot ID you're done with, and by "done" I mean you've finished creating snapshots with it and you're letting the reference go π.
β¨ DESCRIPTION β¨
okay so here's the tea π₯: this should be called by a driver after finishing creating snapshots with an id. That's the moment. That's the whole assignment.
And the way that this slays is: doing so ensures that the ID can later be released in the event that all snapshots using it have been destroyed. So you're not releasing the ID yourself right now β you're setting it up so that later, when every single snapshot using it is gone, the ID can be released. It's giving β¨responsible bookkeepingβ¨. It's giving "I closed the loop, you're welcome" π.
ngl, the important part is the ordering: call it after you've finished creating snapshots with the id. Don't be out here doing it first, bestie π.
π SEE ALSO π
Kernel file ./net/devlink/region.c, plus all her friends in the region.c cinematic universe π:
__devlink_snapshot_id_increment(9)__devlink_snapshot_id_decrement(9)__devlink_snapshot_id_insert(9)__devlink_region_snapshot_id_get(9)__devlink_region_snapshot_create(9)devl_region_create(9)devlink_region_create(9)devlink_port_region_create(9)devl_region_destroy(9)devlink_region_destroy(9)devlink_region_snapshot_id_get(9)devlink_region_snapshot_create(9)
fr fr, go read them, they're literally the same friend group π§.
π cute little sign-off: this page lives under ./net/devlink, and it's dated October 2026 β so she's from the future, or at least from a very confident version of the present. Either way, slay πβ¨
periodt. go put that reference down responsibly π
π¦ 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