devlink_port_region_create(9)
π devlink_port_region_create(9)
okay so welcome to the Kernel API Manual, bestie β this is the page for devlink_port_region_create, and it's lowkey iconic. It's all about making a brand new address region for a port. That's it. That's the whole vibe. β¨
πΈ NAME πΈ
devlink_port_region_create β create a new address region for a port
Like, literally just spawn a fresh region. Main character behavior fr fr. π«Ά
β¨ SYNOPSIS β¨
struct devlink_region * devlink_port_region_create (struct devlink_port
*port , const struct devlink_port_region_ops *ops , u32
region_max_snapshots , u64 region_size );
okay so it hands you back a struct devlink_region * and takes four things. No cap, that's the whole signature. π
π ARGUMENTS π
portβ the devlink port. your port. the one you're doing all this for. π¦opsβ the region operations and the name. yes bestie, both. it's giving multitasking. πregion_max_snapshotsβ the maximum supported number of snapshots for the region (it's au32, and it is NOT here to be exceeded, iykyk).region_sizeβ size of region. au64. the actual size. the big one. β
π₯ CONTEXT π₯
So here's the tea: it takes and release devlink->lock <mutex>.
Bestie pls note β the lock gets taken and released in here. so don't come in already holding it and expect a cute little time. π
π SEE ALSO π
Kernel file ./net/devlink/region.c πΈ β and then the whole friend group:
__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)devl_region_destroy(9)devlink_region_destroy(9)devlink_region_snapshot_id_get(9)devlink_region_snapshot_id_put(9)devlink_region_snapshot_create(9)
that's the page, bestie, go create some regions and slay π
β signed off from ./net/devlink, October 2026, and yeah the page name is devlink_port_region_create(9) in case you forgot already π π
π¦ 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