batadv_interface_rx(9)
π batadv_interface_rx(9)
okay so bestie, buckle up β this one's from the Kernel API Manual and it's literally the function that catches ethernet frames coming in on your local batman-adv interface π¦
β¨ NAME β¨
batadv_interface_rx β receive ethernet frame on local batman-adv interface π
β¨ SYNOPSIS β¨
void batadv_interface_rx (struct net_device *mesh_iface , struct sk_buff
*skb , int hdr_size , struct batadv_orig_node *orig_node );
π«Ά ARGUMENTS π«Ά
mesh_ifaceβ the local interface that's gonna receive the ethernet frame, iykyk πskbβ the ethernet frame destined formesh_ifaceπ¦hdr_sizeβ the size of the batman-adv header that's already been parsed πorig_nodeβ the originator that sent the batman-adv packet, no cap β
πΈ DESCRIPTION πΈ
So what this does is send an ethernet frame to the receive path of the local mesh_iface β that's the whole vibe π
Now here's the part you cannot skip: skb->data must still point to the batman-adv header, with the size hdr_size. Not "should" β must. And the caller has to have already parsed this header itself, plus made sure that at least hdr_size bytes are still available for pull in skb. Like, that's on you, not on this function π
fair warning bestie π β the packet can still get dropped. That's just how it is.
It gets dropped when:
- the encapsulated ethernet frame is invalid, or
- it contains again a batman-adv packet (inception energy, we don't stan)
Also, unicast packets get dropped directly when they were sent between two isolated clients. no notes, that's the rule π
π₯ SEE ALSO π₯
Kernel file ./net/batman-adv/mesh-interface.c β and the whole friend group:
batadv_skb_head_push(9)batadv_sum_counter(9)batadv_interface_stats(9)batadv_interface_set_mac_addr(9)batadv_interface_change_mtu(9)batadv_interface_set_rx_mode(9)batadv_interface_tx(9)batadv_meshif_vlan_release(9)batadv_meshif_vlan_get(9)batadv_meshif_create_vlan(9)batadv_meshif_destroy_vlan(9)batadv_interface_add_vid(9)batadv_interface_kill_vid(9)batadv_set_lockdep_class_one(9)batadv_set_lockdep_class(9)batadv_meshif_init_late(9)batadv_meshif_slave_add(9)batadv_meshif_slave_del(9)batadv_get_drvinfo(9)batadv_get_strings(9)batadv_get_ethtool_stats(9)batadv_get_sset_count(9)batadv_meshif_free(9)batadv_meshif_init_early(9)batadv_meshif_validate(9)batadv_meshif_newlink(9)batadv_meshif_destroy_netlink(9)batadv_meshif_is_valid(9)
β¨ that's the whole page, bestie β¨ it lives under ./net/batman-adv, dated October 2026, and the manual name up top is batadv_interface_rx(9). go forth and receive those frames ππ¦π
π¦ 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