batadv_neigh_node_create(9)
π¦ batadv_neigh_node_create(9) β the Kernel API Manual files π
okay so bestie, we're in the Kernel API Manual today and this one's a little function from the batman-adv originator world. it's called batadv_neigh_node_create and honestly? it's giving "i make the friend object" energy. let's get into it β¨
πΈ NAME πΈ
batadv_neigh_node_create β create a neigh node object π«Ά
β SYNOPSIS β
struct batadv_neigh_node * batadv_neigh_node_create (struct
batadv_orig_node *orig_node , struct batadv_hard_iface *hard_iface ,
const u8 *neigh_addr );
like, that's the whole signature. no cap, that's it π₯
π ARGUMENTS π
orig_nodeβ the originator object that represents the neighbour π like, this is who we're talking about, the main character of the neighbour situation.hard_ifaceβ the interface where the neighbour is connected to π¦ i.e. the physical-ish doorway they came in through.neigh_addrβ the mac address of the neighbour interface πΈ the literal address of the neighbour's face, basically.
π DESCRIPTION π
so what does it actually do? it allocates a new neigh_node object and initialises all the generic fields π« that's it, that's the job. it's a builder. it's a fresh-start queen. it hands you a shiny new neighbour node with all the boring generic bits already filled in π
β¨ RETURN β¨
it returns the neighbour node if it was found or created, or NULL otherwise π so like... check it, bestie. don't just raw-dog that pointer. respect the NULL.
π₯ SEE ALSO π₯
the kernel file is over in ./net/batman-adv/originator.c and here's the whole friend group, no one left out π
batadv_orig_hash_find(9)batadv_compare_orig(9)batadv_orig_node_vlan_get(9)batadv_vlan_id_valid(9)batadv_orig_node_vlan_new(9)batadv_orig_node_vlan_release(9)batadv_originator_init(9)batadv_neigh_ifinfo_release(9)batadv_hardif_neigh_release(9)batadv_neigh_node_release(9)batadv_orig_router_get(9)batadv_orig_to_router(9)batadv_orig_ifinfo_get(9)batadv_orig_ifinfo_new(9)batadv_neigh_ifinfo_get(9)batadv_neigh_ifinfo_new(9)batadv_neigh_node_get(9)batadv_hardif_neigh_create(9)batadv_hardif_neigh_get_or_create(9)batadv_hardif_neigh_get(9)batadv_neigh_node_get_or_create(9)batadv_hardif_neigh_dump(9)batadv_orig_ifinfo_release(9)batadv_orig_node_free_rcu(9)batadv_orig_node_release(9)batadv_originator_free(9)batadv_orig_node_new(9)batadv_purge_neigh_ifinfo(9)batadv_purge_orig_ifinfo(9)batadv_purge_orig_neighbors(9)batadv_find_best_neighbor(9)batadv_purge_orig_node(9)batadv_purge_orig_ref(9)batadv_purge_orig(9)batadv_orig_dump(9)
lowkey that's a big SEE ALSO list but every single one of them is living in ./net/batman-adv/originator.c and honestly? iconic behaviour. go read them. iykyk π
and that's the page bestie!! brought to you by the <rainbow>./net/batman-adv</rainbow> gang, dated October 2026 π mwah, go create some neighbour nodes responsibly π
π¦ 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