batadv_v_ogm_packet_recv(9)
π batadv_v_ogm_packet_recv β the OGM2 receiving handler, bestie π
okay so quick vibe check: you're in the Kernel API Manual (yes, the whole manual, we're fancy now π) and this page is all about batadv_v_ogm_packet_recv(9), aka the OGM2 receiving handler. it's giving "the person who answers the door when a packet shows up" energy, and honestly? iconic. β¨
πΈ SYNOPSIS πΈ
int batadv_v_ogm_packet_recv (struct sk_buff *skb , struct
batadv_hard_iface *if_incoming );
that's it. that's the whole function signature. short, sweet, and about to Handle Business π
π ARGUMENTS π
skbβ the received OGM π like, the actual packet that just rolled up. this is the main character of the whole operation, ngl.if_incomingβ the interface where this OGM has been received π¦ so we know which door it knocked on. very important for the plot.
β RETURN β
so here's how it goes down at the end:
NET_RX_SUCCESSand it consumes the skb on success π i.e. the skb gets eaten (respectfully) and everything slays.NET_RX_DROP(and it frees the skb) on failure π so like, the packet didn't make it, but at least it's freed and not just... floating around being a memory leak. we love a clean exit.
lowkey important: both paths deal with the skb β one consumes it, one frees it. no skb left behind, periodt π«Ά
π₯ SEE ALSO π₯
go check out the kernel file ./net/batman-adv/bat_v_ogm.c and all these sibling functions β the whole friend group, fr fr:
batadv_v_ogm_orig_get(9)batadv_v_ogm_start_queue_timer(9)batadv_v_ogm_start_timer(9)batadv_v_ogm_send_to_if(9)batadv_v_ogm_len(9)batadv_v_ogm_queue_left(9)batadv_v_ogm_aggr_list_free(9)batadv_v_ogm_aggr_send(9)batadv_v_ogm_queue_on_if(9)batadv_v_ogm_send_meshif(9)batadv_v_ogm_send(9)batadv_v_ogm_aggr_work(9)batadv_v_ogm_iface_enable(9)batadv_v_ogm_iface_disable(9)batadv_v_ogm_primary_iface_set(9)batadv_v_forward_penalty(9)batadv_v_ogm_forward(9)batadv_v_ogm_metric_update(9)batadv_v_ogm_route_update(9)batadv_v_ogm_process_per_outif(9)batadv_v_ogm_aggr_packet(9)batadv_v_ogm_process(9)batadv_v_ogm_init(9)batadv_v_ogm_free(9)
this page lives in ./net/batman-adv and it's stamped October 2026 π (the version/source vibes, if you were wondering β and you were wondering, iykyk). anyway that's the whole page bestie, go read some OGM2 code, you're gonna do amazing, no cap ππ§π¦
π¦ 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