batadv_mcast_forw_push_dest(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… batadv_mcast_forw_push_dest(9) β€” the Kernel API Manual, bestie edition

okay so bestie, this is batadv_mcast_forw_push_dest β€” it lives in the Kernel API Manual, and the whole entire job of this function is literally just pushing an originator MAC address onto an skb. that's it. that's the gig. πŸŽ€


✨ SYNOPSIS ✨

bool batadv_mcast_forw_push_dest (struct batadv_priv *bat_priv , struct
       sk_buff *skb , unsigned short vid , struct batadv_orig_node *orig_node ,
       unsigned short *num_dests , unsigned short *tvlv_len );

it returns a bool, so you already know it's about to be a yes-or-no situation. πŸ’–


🫢 ARGUMENTS 🫢

  • bat_priv β€” the bat priv with all the mesh interface information. it's giving "holder of all the mesh lore". πŸ‘‘
  • skb β€” the skb you're pushing the destination address onto. the main character of this operation, ngl.
  • vid β€” the vlan identifier. yes, it's short. yes, it's iconic.
  • orig_node β€” the originator node you're getting the MAC address from. we're borrowing, bestie, not stealing.
  • num_dests β€” a pointer to store the number of pushed addresses in. it's a pointer, so it's storing something, not just vibing. πŸ¦‹
  • tvlv_len β€” stores the amount of currently pushed TVLV bytes. gotta keep that byte count cute and accurate. πŸ“

🌸 DESCRIPTION 🌸

here's the vibe check. if the orig_node is a BLA backbone gateway, or if there's not enough skb headroom available, or if num_dests is already at its maximum (that's 65535, no cap), then neither the skb nor num_dests is changed. nothing happens. zero movement. we respect the boundary. πŸ™ˆ

otherwise? the originator's MAC address gets pushed onto the given skb and num_dests gets incremented by one. slay. ✨

fr fr remember: all three of those conditions are "hands off the skb" territory β€” the function literally changes nothing in those cases. πŸ’€

πŸ”₯ RETURN πŸ”₯

  • returns true if the orig_node is a backbone gateway or if an orig address was pushed successfully πŸŽ‰
  • returns false otherwise πŸ’…

🌈 SEE ALSO 🌈

the kernel file in question:

  • ./net/batman-adv/multicast_forw.c

and the whole entire friend group (they all showed up, nobody cancelled):


and that's the whole page, bestie!! πŸ’–βœ¨πŸŽ€ this one shipped straight out of ./net/batman-adv with an October 2026 date stamp β€” so like, go forth and push those destination addresses responsibly. mwah. πŸ«ΆπŸ¦‹πŸŒΈ

πŸ“¦ where this page comes from