Re: [RFC PATCH 3/3] x86/lib: Use EGPRs in 64-bit checksum copy loop
From: Chang S. Bae
Date: Mon Dec 01 2025 - 16:39:50 EST
On 11/25/2025 2:37 AM, david laight wrote:
This code (or something very similar) gets used to checksum data
during copy_to/from_user for sockets.
This goes back a long way and I suspect the 'killer ap' was nfsd
running over UDP (with 8k+ UDP datagrams).
Modern NICs all (well all anyone cares about) to IP checksum offload.
So you don't need to checksum on send() - I'm sure that is still
enabled even though you pretty much never want it.
The checksum on recv() can only happen for UDP, but massively
complicates the code paths and will normally not be needed.
It sounds like this optimization wouldn't provide practical benefit. I
don't see a strong case for pursuing this further either, so I'd drop this.
Thanks,
Chang