batadv_tvlv_...ler_register(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– batadv_tvlv_handler_register(9) πŸ’–

okay so bestie, welcome to the kernel API manual for batadv_tvlv_handler_register β€” yes the header up top got squished down to batadv_tvlv_...ler_register(9) because it's long, we don't judge, we love a abbreviated queen πŸ‘‘


✨ NAME ✨

batadv_tvlv_handler_register β€” register a tvlv handler based on the provided type and version (both need to match, no exceptions bestie) for ogm tvlv payload and/or unicast payload πŸŽ€


🌸 SYNOPSIS 🌸

void batadv_tvlv_handler_register (struct batadv_priv *bat_priv , void
(*optr)(struct batadv_priv *bat_priv, struct batadv_orig_node *orig, u8
flags, void *tvlv_value, u16 tvlv_value_len) , int (*uptr)(struct batadv_priv
*bat_priv, u8 *src, u8 *dst, void *tvlv_value, u16 tvlv_value_len) , int
(*mptr)(struct batadv_priv *bat_priv, struct sk_buff *skb) , u8 type , u8
version , u8 flags );

it returns void, so like… she doesn't hand you a status back, she just does the thing πŸ’…


πŸ¦‹ ARGUMENTS πŸ¦‹

  • bat_priv β€” the bat priv with all the mesh interface information ✨ like, this is the main character struct holding everything you need to know about the mesh interface, periodt.
  • optr β€” ogm tvlv handler callback function. This function receives the orig node, flags and the tvlv content as argument to process 🫢 (yes, the callback gets handed the orig node and the flags and the tvlv content β€” she's thorough).
  • uptr β€” unicast tvlv handler callback function. This function receives the source & destination of the unicast packet as well as the tvlv content to process πŸ’Œ so like, src, dst, and the tvlv content all show up to the function.
  • mptr β€” multicast packet tvlv handler callback function. This function receives the full skb to process, with the skb network header pointing to the current tvlv and the skb transport header pointing to the first byte after the current tvlv πŸ”₯ (ngl this one is the detail-heavy icon, memorize those two header positions fr fr).
  • type β€” tvlv handler type to be registered 🏷️
  • version β€” tvlv handler version to be registered ⭐ (remember: type and version both need to match, that's the whole vibe check from NAME)
  • flags β€” flags to enable or disable TVLV API behavior 🎚️

🌈 SEE ALSO 🌈

kernel file ./net/batman-adv/tvlv.c β€” and honestly the whole friend group shows up here:


lowkey a whole tvlv cinematic universe going on in ./net/batman-adv πŸ‘‘

and that's the page bestie!! this one lives in ./net/batman-adv, dated October 2026, and it's filed under that iconic batadv_tvlv_...ler_register(9) name πŸ’œ go register a handler, slay, and stay hydrated πŸ“πŸ§šβœ¨

πŸ“¦ where this page comes from