__skb_flow_dissect_batadv(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… __skb_flow_dissect_batadv(9) πŸ’…

okay so this is a page from the Kernel API Manual, bestie β€” it's __skb_flow_dissect_batadv(9) and it's literally all about dissecting the batman-adv header ✨ (yes, batman-adv, not the superhero, but honestly? main character energy anyway πŸ¦‡)


✨ NAME ✨

__skb_flow_dissect_batadv β€” dissect batman-adv header πŸŽ€


πŸ¦‹ SYNOPSIS πŸ¦‹

enum flow_dissect_ret __skb_flow_dissect_batadv (const struct sk_buff
*skb , struct flow_dissector_key_control *key_control , const void *data
, __be16 *p_proto , int *p_nhoff , int hlen , unsigned int flags );

no cap, that's the whole signature β€” copy it exactly, do not come for me about the line breaks 😭


🌸 ARGUMENTS 🌸

  • skb β€” the sk_buff that's carrying the batman-adv header. yeah. that one. 🫢
  • key_control β€” the flow dissector's control key, iconic little guy
  • data β€” raw buffer pointer to the packet. heads up: if it's NULL, it falls back to using skb->data πŸ’–
  • p_proto β€” pointer that gets updated with the protocol to process next
  • p_nhoff β€” pointer that gets updated with the inner network header offset
  • hlen β€” the packet header length
  • flags β€” any combination of FLOW_DISSECTOR_F_* ⭐

🧚 DESCRIPTION 🧚

so like, packets tagged ETH_P_BATMAN get tried for dissection. the tea is that only struct batadv_unicast packets actually get processed β€” because those are the ones that contain an inner ethernet header and are usually followed by an actual network header πŸ’… which is lowkey the whole point: it lets the flow dissector keep processing the packet. slay.


πŸ’€ RETURN πŸ’€

  • FLOW_DISSECT_RET_PROTO_AGAIN β€” returned when struct batadv_unicast was found πŸ‘‘
  • FLOW_DISSECT_RET_OUT_GOOD β€” returned when the dissector should stop after encapsulation
  • otherwise you get FLOW_DISSECT_RET_OUT_BAD πŸ™ˆ (not the vibe, but okay)

🌈 SEE ALSO 🌈

check out the kernel file ./net/core/flow_dissector.c, plus these absolute legends:


bestie please note: this is a kernel API page, so everything is exactly as written β€” i'm not out here inventing flags or guessing at behaviour, iykyk πŸ’œ

okay that's the whole page, mwah πŸ’‹ it lives in ./net/core, version dating October 2026 β€” so mark your calendars, set a reminder, whatever you gotta do. bye bestie, go dissect some packets πŸŽ€βœ¨πŸ¦‹

πŸ“¦ where this page comes from