netdev_lowe...next_private(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… netdev_lower_get_next_private(9) πŸ’…

okay so this is a page from the Kernel API Manual, section 9, and it's all about walking a device's lower-neighbour list one ->private at a time. bestie, it's shorter than you'd think but lowkey important, so let's go 🫢


✨ NAME ✨

netdev_lower_get_next_private β€” grab the next ->private out of the lower neighbour list πŸ”₯


🌸 SYNOPSIS 🌸

void * netdev_lower_get_next_private (struct net_device *dev , struct list_head **iter );

like… that's the whole signature, no notes πŸ’…


πŸŽ€ ARGUMENTS πŸŽ€

  • dev β€” the device. yes, that device πŸ¦‹
  • iter β€” a list_head ** that points at your current position in the list. it's a pointer to a pointer, she's fancy like that ✨

πŸ‘‘ DESCRIPTION πŸ‘‘

okay so picture this: dev has a lower neighbour list, right? this function gets you the next netdev_adjacent->private from that list, starting from wherever iter is currently sitting. it's giving iterator energy, it's giving "walk the list" realness πŸšΆβ€β™€οΈπŸ’¨

⚠️ but here's the part where you gotta pay attention, bestie: the caller must either hold the RTNL lock, or hold its own locking that guarantees the neighbour lower list is gonna stay unchanged. no cap, if you skip this the list can shift under you and it's giving undefined chaos πŸ’€

πŸ’– SEE ALSO πŸ’–

kernel file ./net/core/dev.c β€” and the friend group is huge, so strap in πŸŽ€


and that's the whole page, bestie, we ate that ✨ this cutie lives under ./net/core, the Kernel API Manual edition, dated October 2026 β€” mwah, go hold that lock πŸ’‹πŸ‘‘

πŸ“¦ where this page comes from