devl_resource_register(9)
πΈ NAME πΈ
okay so bestie, <rainbow>devl_resource_register</rainbow> β it's literally the devlink resource register function π
like, that's the whole vibe, that's the name, periodt β¨
β¨ SYNOPSIS β¨
int devl_resource_register (struct devlink *devlink , const char
*resource_name , u64 resource_size , u64 resource_id , u64
parent_resource_id , const struct devlink_resource_size_params *params
);
like, look at her π six arguments, one int, no cap fr fr π«Ά
π ARGUMENTS π
devlinkβ thedevlinkπ¦ yep that's it, that's the whole description, she's self-explanatory iykykresource_nameβ the resource's name π like what you're calling this thingresource_sizeβ the resource's size πΈ how big it is, that's the tearesource_idβ the resource's id β her little number, her identifier, her whole identityparent_resource_idβ the resource's parent id π who she belongs to, the family tree situationparamsβ size parameters π the parameters, specifically of the size variety
π DESCRIPTION π
so, the way that generic resources work π bestie, they should reuse the same names across drivers β like, consistency is the moment, please don't make up a new name every single time, that's not the vibe check we're going for π
please see the generic resources list at:
Documentation/networking/devlink/devlink-resource.rst
literally go read it, it's giving required reading π β¨
π₯ RETURN π₯
0on success π slay- a negative error code otherwise π not slay, but that's what you get
π¦ SEE ALSO π¦
- Kernel file
./net/devlink/resource.cπ that's where she lives struct devlink_resource(9)π§devl_resources_unregister(9)πΈdevlink_resources_unregister(9)πdevl_resource_size_get(9)βdevl_resource_occ_get_register(9)πdevl_resource_occ_get_unregister(9)πdevl_port_resource_register(9)πdevl_port_resources_unregister(9)π«Ά
go read all of them, i'm obsessed with a complete cross-reference list ngl π
okay that's the whole page bestie, mwah π β this one's from ./net/devlink, dated October 2026, and it's devl_resource_register(9) if you needed the reminder, love u, go register some resources, bye πβ¨
π¦ 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