Re: [PATCH] io_uring/net: don't charge the folio offset to truesize for managed frags
From: Jens Axboe
Date: Wed Nov 25 2026 - 12:26:11 EST
On Thu, 19 Nov 2026 23:29:35 +0000, Louis Thiery wrote:
> Registered buffers backed by huge pages are coalesced into one bvec per
> folio, so bv_offset is relative to the folio, not to a 4K page.
> io_sg_from_iter() adds PAGE_ALIGN(bv_len + bv_offset) to the skb
> truesize, which charges the socket for the whole run-up inside the
> folio. A 64K send from 1.5MB into a 2MB THP folio adds about 1.6MB of
> truesize, and sk_wmem_queued fills long before any real memory is used.
>
> [...]
Applied, thanks!
[1/1] io_uring/net: don't charge the folio offset to truesize for managed frags
commit: aaa55c8ff9147b1ce1ba50267aa9f080d469a963
Best regards,
--
Jens Axboe