csum_and_copy_from_user(9)
π¦ csum_and_copy_from_user(9) π¦
okay so bestie, welcome to the Kernel API Manual corner where we make kernel functions make sense. This one is literally about copying from user space and checksumming at the same time β main character energy fr fr. π
β¨ NAME β¨
csum_and_copy_from_user β copy and checksum from user space. π«Ά
π SYNOPSIS π
__wsum csum_and_copy_from_user (const void __user *src , void *dst , int
len );
π ARGUMENTS π
srcβ source address (user space) πΈdstβ destination address πlenβ number of bytes to be copied. π
πΈ DESCRIPTION πΈ
Okay so here's the vibe: it returns an 32bit unfolded checksum of the buffer. β¨
And the tea is that src and dst are best aligned to 64bits. π
π₯ SEE ALSO π₯
- Kernel file
./arch/x86/lib/csum-wrappers_64.cβ yes, that exact path, iykyk. π¦ csum_and_copy_to_user(9)πcsum_partial_copy_nocheck(9)β
mwah π β this page is signed off from ./arch/x86/lib, dated October 2026, and it's giving "kernel API but make it cute." ππ
π¦ 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