batadv_frag_create(9)
π batadv_frag_create(9) π
okay so we're in the Kernel API Manual today bestie, and this page is all about batadv_frag_create(9) β yes that's the title AND the manual name, we're keeping it cute and keeping it real β¨
πΈ NAME πΈ
batadv_frag_create β create a fragment from skb π
like literally, it makes a fragment. from an skb. that's the whole vibe.
π SYNOPSIS π
struct sk_buff * batadv_frag_create (struct net_device *net_dev , struct
sk_buff *skb , struct batadv_frag_packet *frag_head , unsigned int
fragment_size );
no cap, that's the whole signature π«Ά
β¨ ARGUMENTS β¨
net_devβ the outgoing device for the fragment. it's giving "where is this baby going" π¦skbβ the skb you wanna create the fragment from. the raw material, the main character π₯frag_headβ the header to use in the new fragment. gotta have a cute lil header, iykyk πfragment_sizeβ size of the new fragment. numbers matter, periodt β
π DESCRIPTION π
so here's the tea β β this function splits the passed skb into two fragments:
- a new one, with a size matching the passed mtu π
- the old one, which keeps the rest π
and the plot twist? the new skb contains data from the tail of the old skb. tail data. not head. the tail. don't get it twisted bestie π
π RETURN π
- the new fragment π
NULLon error π (we don't talk about the error case)
π§ SEE ALSO π§
kernel file ./net/batman-adv/fragmentation.c β go read it, it's iconic, fr fr:
batadv_frag_clear_chain(9)batadv_frag_purge_orig(9)batadv_frag_size_limit(9)batadv_frag_init_chain(9)batadv_frag_insert_packet(9)batadv_frag_merge_packets(9)batadv_skb_is_frag(9)batadv_frag_skb_buffer(9)batadv_frag_skb_fwd(9)batadv_frag_send_packet(9)
that's the whole friend group, they all ate π
ok that's the page!! mwah π«Ά from the source ./net/batman-adv, dated October 2026, batman-adv version, signing off β slay, bye bestie πβ¨π
π¦ 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