batadv_mcast_forw_want_rtr(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… batadv_mcast_forw_want_rtr β€” Kernel API Manual realness

Okay so bestie, buckle up, because we're diving into batadv_mcast_forw_want_rtr from the Kernel API Manual, fr fr. This is a batman-adv multicast forwarding function and it's giving "quietly important" main character energy, iykyk. πŸ¦‹


✨ NAME ✨

batadv_mcast_forw_want_rtr β€” forward packet to nodes in a want-all-rtr list

No cap, that's literally the whole vibe. It forwards a packet to the nodes chillin' on the want-all-rtr list. πŸ’–


🌸 SYNOPSIS 🌸

int batadv_mcast_forw_want_rtr (struct batadv_priv *bat_priv , struct
       sk_buff *skb , unsigned short vid );

Three args, one int coming back. Slay. ✨


πŸŽ€ ARGUMENTS πŸŽ€

  • bat_priv β€” the bat priv with all the mesh interface information. Like, it's the whole registry of mesh interface tea. πŸ‘‘
  • skb β€” the multicast packet to transmit. This is the actual cargo we're shipping out. πŸ“¦
  • vid β€” the vlan identifier. Yep, need to know which VLAN we're repping. 🏷️

πŸ¦‹ DESCRIPTION πŸ¦‹

So here's what's happening: this function sends copies of a frame with a multicast destination to any node with a BATADV_MCAST_WANT_NO_RTR4 or BATADV_MCAST_WANT_NO_RTR6 flag unset. Read that again β€” unset. Those are the nodes that actually want it. πŸ™ˆ

And the way it does it? A transmission is performed via a batman-adv unicast packet for each such destination node. One copy, one unicast packet, per node. Periodt. πŸ’…

Not me making sure you caught the "unset" part β€” if the flag were set, they'd be saying "no thanks, I don't want the router stuff," and they wouldn't be getting a copy. Vibe check passed. βœ…

πŸ”₯ RETURN πŸ”₯

  • NET_XMIT_DROP β€” returned on memory allocation failure 😭, or if the protocol family is neither IPv4 nor IPv6. Like, if it's not one of those two, we're not doing it, bestie. πŸ’€
  • NET_XMIT_SUCCESS β€” returned otherwise. That's the win. 🌈⭐

πŸ’œ SEE ALSO πŸ’œ

Kernel file ./net/batman-adv/multicast.c, plus this absolute constellation of friends:


Okay that's the page!! 🫢 This one came out of ./net/batman-adv in October 2026, and the whole thing is filed under batadv_mcast_forw_want_rtr(9) β€” go read the friends list, it's lowkey iconic. Go off, kernel docs. πŸ‘‘βœ¨

πŸ“¦ where this page comes from