skb_cow_data(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ skb_cow_data(9) ✨

okay bestie, this is the Kernel API Manual entry for skb_cow_data(9) β€” yes, the manual name is folded in right here, and we’re about to make socket-buffer writability make sense. 🫢

πŸ¦‹ NAME πŸ¦‹

skb_cow_data β€” check that a socket buffer’s data buffers are writable. ✨

πŸŽ€ SYNOPSIS πŸŽ€

int skb_cow_data (struct sk_buff *skb , int tailbits , struct sk_buff
       **trailer );

🌸 ARGUMENTS 🌸

  • skb β€” the socket buffer you’re checking, bestie.
  • tailbits β€” the amount of trailing space to be added.
  • trailer β€” returned pointer to the skb where the tailbits space begins.

πŸ’… DESCRIPTION πŸ’…

So the whole point: make sure the data buffers attached to a socket buffer are writable. If they’re not, private copies are made of the data buffers, and the socket buffer is set to use these instead. πŸ’–

If tailbits is given, make sure there’s space to write tailbits bytes of data beyond the current end of the socket buffer. Then trailer will be set to point to the skb in which this space begins. πŸŽ€

The number of scatterlist elements required to completely map the COW'd and extended socket buffer will be returned. That’s the return value, no cap. ✨

🌈 SEE ALSO 🌈

Kernel file ./net/core/skbuff.c, plus this entire icon squad of cross-references β€” every single one, periodt:


cute sign-off: source: ./net/core, date: October 2026, page: skb_cow_data(9). byeee πŸ’…πŸ¦‹

πŸ“¦ where this page comes from