dev_hold(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– dev_hold(9) πŸ’–

okay so bestie, welcome to the dev_hold page β€” that's the entry in the Kernel API Manual and honestly it's a short one, so grab your lil strawberry drink πŸ“ and let's go.


✨ NAME ✨

dev_hold β€” get a reference to a device 🫢


🌸 SYNOPSIS 🌸

void dev_hold (struct net_device *dev );

πŸŽ€ ARGUMENTS πŸŽ€

  • dev β€” the network device, bestie. that's it, that's the argument πŸ’…

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so what this does: it holds a reference to the device so it does not get freed while you're still out here using it. literally keeping it alive. main character protection energy πŸ‘‘

but listen β€” try using netdev_hold instead. fr fr, that's the recommendation, i don't make the rules πŸ™ˆ


πŸ‘‘ SEE ALSO πŸ‘‘

the whole friend group, no cap:


that's the whole page bestie, you ate that πŸ’…βœ¨

shoutout to ./include/linux for hosting this lil masterpiece, dated October 2026 β€” see u in the next manpage, mwah πŸŽ€πŸ’œ

πŸ“¦ where this page comes from