Re: [PATCH net v1] net: skb: fix cross-cache free of KFENCE-allocated skb head

From: Jiayuan Chen

Date: Thu Apr 02 2026 - 04:44:39 EST



On 4/2/26 4:03 PM, Eric Dumazet wrote:
On Wed, Apr 1, 2026 at 9:15 PM Jiayuan Chen <jiayuan.chen@xxxxxxxxx> wrote:
If we no longer care about the cost of accessing a struct page in the
free path, which the original commit was trying to avoid, this is
indeed the simplest fix — kfree() correctly handles objects via
virt_to_slab.
We only have SLUB in modern kernels, kmem_cache_free() needs to touch it.

Using is_kfence_address() in net/core/skbuff.c is pushing too hard in
my opinion.
Thanks, I understand.