skb_orphan_frags(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… skb_orphan_frags β€” Kernel API Manual ✨

okay bestie, this one's from the <pink>Kernel API Manual</pink> (section 9, kernel dev girly stuff), and it's honestly such a niche little function but like, lowkey crucial? let's get into it 🫢


🌸 NAME 🌸

skb_orphan_frags β€” orphan the frags contained in a buffer πŸ’”


✨ SYNOPSIS ✨

int skb_orphan_frags (struct sk_buff *skb , gfp_t gfp_mask );

that's it. that's the whole vibe check. returns an int, takes two args, slays. πŸ‘‘


πŸŽ€ ARGUMENTS πŸŽ€

  • skb β€” the buffer we're orphan frags from, bestie. this is the SKB we're operating on ✨
  • gfp_mask β€” the allocation mask used for the replacement pages 🌸 (yes the mask matters, don't @ me)

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so here's the tea β˜• β€” for each frag in the SKB which needs a destructor (i.e. it has an owner), this function will:

  1. create a copy of that frag πŸŽ€
  2. release the original page by calling the destructor πŸ’€

that's literally it. copy the frag, yeet the original through its destructor, move on to the next one. no cap, that's the whole personality. it's giving "responsible about memory" main character energy πŸ’…βœ¨


πŸ”₯ SEE ALSO πŸ”₯

the reference list on this one is absolutely unhinged in the best way β€” like girl really said "here's my whole contact list" 😭😭 so buckle up:

like I said. the whole contact list. 😭🫢 go read them, they're all iconic in their own way.


ngl bestie, the SEE ALSO section here is longer than the actual function description. that's not a bug, that's just skb lore. πŸ’€

mwah πŸ’œ that's the page! brought to you courtesy of ./include/linux β€” October 2026 edition πŸ—“οΈβœ¨ hope this helped, now go orphan some frags responsibly, ily, bye!! πŸ’–πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from