skb_copy_an...atagram_iter(9)
β¨ NAME β¨
skb_copy_and_crc32c_datagram_iter β the function formally known as skb_copy_an...atagram_iter(9) in the Kernel API Manual π β copies a datagram over to an iovec iterator and updates a CRC32C value at the same time. Two jobs, one function, main character energy fr fr πΈ
π¦ SYNOPSIS π¦
int skb_copy_and_crc32c_datagram_iter (const struct sk_buff *skb , int
offset , struct iov_iter *to , int len , u32 *crcp );
π ARGUMENTS π
skbβ the buffer you're copying from, bestie. This is the source of truth, okay?offsetβ where in the buffer you start copying from. Like, not from the top, from this far in πtoβ the iovec iterator you're copying to. It's giving destination. It's giving target. It's giving "put it here please" π«Άlenβ how much data gets copied out of the buffer and into the iovec. Exactly this much, no cap πcrcpβ pointer to the CRC32C value you're updating. Yes, it gets updated in place. Yes, that's the whole point π
β RETURN β
0on success β slay, we love a clean return π-EFAULTif there was a fault during the copy β not the vibe, something went wrong mid-copy π
Heads up, babe: those are the only two options listed.0or-EFAULT. That's it. Don't be out here inventing other return values, that's not the move π«
π SEE ALSO π
- Kernel file
./net/core/datagram.cπ __skb_try_recv_datagram(9)skb_kill_datagram(9)skb_copy_datagram_iter(9)skb_copy_datagram_from_iter(9)zerocopy_sg_from_iter(9)skb_copy_and_csum_datagram(9)skb_copy_and_csum_datagram_msg(9)datagram_poll_queue(9)datagram_poll(9)
All of these are literally right there in ./net/core/datagram.c, so go read the whole squad, iykyk πβ¨
Friendly reminder that this whole little page lives under ./net/core and it's dated October 2026 β mark your calendars, bestie ποΈπ«
Okay that's the whole page!! Go copy some datagrams and update that CRC32C, you absolute icon ππ This has been your girl, signing off from the Kernel API Manual, ./net/core, October 2026 edition ππ¦
π¦ 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