batadv_find_best_neighbor(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ batadv_find_best_neighbor ✨

okay so bestie, pull up a chair πŸŽ€ this one lives in the Kernel API Manual and it's called batadv_find_best_neighbor β€” and yes the name lowkey spoils the whole plot: it finds the best neighbor after purging. icon behavior, honestly πŸ’…


🌸 SYNOPSIS 🌸

struct batadv_neigh_node * batadv_find_best_neighbor (struct batadv_priv
*bat_priv , struct batadv_orig_node *orig_node , struct
batadv_hard_iface *if_outgoing );

she returns a struct batadv_neigh_node *, no cap πŸ¦‹


πŸ’– ARGUMENTS πŸ’–

  • bat_priv β€” the bat priv with all the mesh interface information. it's giving "the main character who holds everyone's info" πŸ‘‘
  • orig_node β€” orig node which is to be checked. like, the one we're side-eyeing πŸ™ˆ
  • if_outgoing β€” the interface for which the metric should be compared. this is the vibe check interface, fr fr ✨

⭐ RETURN ⭐

the current best neighbor, with refcount increased. not me reminding you that the refcount goes UP β€” pls don't leak it, bestie 😭🫢


πŸ¦‹ SEE ALSO πŸ¦‹

Kernel file ./net/batman-adv/originator.c, plus the whole friend group:


and that's the whole page, bestie πŸ’œ sourced from ./net/batman-adv, dated October 2026, filed under batadv_find_best_neighbor(9) β€” slay, go read your kernel source now, iykyk πŸŒˆπŸ‘‘

πŸ“¦ where this page comes from