batadv_iv_ogm_forward(9)
π batadv_iv_ogm_forward(9) β the Kernel API Manual, bestie edition
Okay so this page is from the Kernel API Manual and it's literally all about batadv_iv_ogm_forward, which is living over in ./net/batman-adv/bat_iv_ogm.c. Buckle up π
β¨ NAME β¨
batadv_iv_ogm_forward β rebroadcast a received OGM π¦
πΈ SYNOPSIS πΈ
void batadv_iv_ogm_forward (struct batadv_orig_node *orig_node , const
struct ethhdr *ethhdr , struct batadv_ogm_packet *batadv_ogm_packet ,
bool is_single_hop_neigh , bool is_from_best_next_hop , struct
batadv_hard_iface *if_incoming , struct batadv_hard_iface *if_outgoing
);
It returns void, so likeβ¦ no return value to obsess over. It just does the thing. π
π«Ά ARGUMENTS π«Ά
orig_nodeβ the originator that sent the OGM, aka the main character πethhdrβ the ethernet header of the OGM packetbatadv_ogm_packetβ the actual OGM packet that's about to get forwardedis_single_hop_neighβtrueif the OGM came in via a one-hop neighbouris_from_best_next_hopβtrueif the sender is the currently selected best next hop towardsorig_nodeβif_incomingβ the interface where the packet was receivedif_outgoingβ the interface we should consider for the retransmission
π₯ DESCRIPTION π₯
So what does it do? Three things, in order, no cap:
- Decrements the TTL
- Applies the hop penalty
- Queues the OGM for retransmission
And here's the nuance, iykyk: OGMs that don't arrive over the best next hop are only forwarded for link-quality measurement reasons, and they get marked accordingly. Not because we're being nice, it's literally for the measurements π
Fr fr, that "only forwarded for link-quality measurement" bit is the whole point β don't read into it as normal forwarding behaviour.
π SEE ALSO π
Kernel file ./net/batman-adv/bat_iv_ogm.c, plus the whole extended universe of friends:
- enum
batadv_dup_status(9) batadv_ring_buffer_set(9)batadv_ring_buffer_avg(9)batadv_iv_ogm_orig_get(9)batadv_iv_ogm_neigh_new(9)batadv_iv_ogm_iface_enable(9)batadv_iv_ogm_iface_disable(9)batadv_iv_ogm_iface_update_mac(9)batadv_iv_ogm_primary_iface_set(9)batadv_iv_ogm_emit_send_time(9)batadv_iv_ogm_fwd_send_time(9)batadv_hop_penalty(9)batadv_iv_ogm_aggr_packet(9)batadv_iv_ogm_send_to_if(9)batadv_iv_ogm_emit(9)batadv_iv_ogm_can_aggregate(9)batadv_iv_ogm_aggregate_new(9)batadv_iv_ogm_aggregate(9)batadv_iv_ogm_queue_add(9)batadv_iv_ogm_slide_own_bcast_window(9)batadv_iv_ogm_schedule_buff(9)batadv_iv_ogm_schedule(9)batadv_iv_ogm_reschedule(9)batadv_iv_orig_ifinfo_sum(9)batadv_iv_ogm_neigh_ifinfo_sum(9)batadv_iv_ogm_orig_update(9)batadv_iv_ogm_calc_tq(9)batadv_iv_ogm_update_seqnos(9)batadv_orig_to_direct_router(9)batadv_iv_ogm_process_per_outif(9)batadv_iv_ogm_process_reply(9)batadv_iv_ogm_process(9)batadv_iv_send_outstanding_bat_ogm_packet(9)batadv_iv_ogm_receive(9)batadv_iv_ogm_neigh_get_tq_avg(9)batadv_iv_ogm_orig_dump_subentry(9)batadv_iv_ogm_orig_dump_entry(9)batadv_iv_ogm_orig_dump_bucket(9)batadv_iv_ogm_orig_dump(9)batadv_iv_ogm_neigh_diff(9)batadv_iv_ogm_neigh_dump_neigh(9)batadv_iv_ogm_neigh_dump_hardif(9)batadv_iv_ogm_neigh_dump(9)batadv_iv_ogm_neigh_cmp(9)batadv_iv_ogm_neigh_is_sob(9)batadv_iv_iface_enabled(9)batadv_iv_init_sel_class(9)batadv_iv_gw_get_best_gw_node(9)batadv_iv_gw_is_eligible(9)batadv_iv_gw_dump_entry(9)batadv_iv_gw_dump(9)batadv_iv_init(9)batadv_iv_deinit(9)
And that's the whole page, bestie π§π Huge shoutout to the source path ./net/batman-adv and the October 2026 date stamp β they ate and left no crumbs. Periodt. πβ¨
π¦ 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