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

From: Eric Dumazet

Date: Thu Apr 02 2026 - 04:08:51 EST


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.