public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Florian Westphal <fw@strlen.de>
To: Qingfang Deng <dqfext@gmail.com>
Cc: Pablo Neira Ayuso <pablo@netfilter.org>,
	Phil Sutter <phil@nwl.cc>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	Simon Horman <horms@kernel.org>,
	netfilter-devel@vger.kernel.org, coreteam@netfilter.org,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	Lorenzo Bianconi <lorenzo@kernel.org>
Subject: Re: [PATCH nf-next] netfilter: flowtable: dedicated slab for flow entry
Date: Thu, 29 Jan 2026 11:26:41 +0100	[thread overview]
Message-ID: <aXs14ZJGN3lDnMDc@strlen.de> (raw)
In-Reply-To: <20260129101213.74557-1-dqfext@gmail.com>

Qingfang Deng <dqfext@gmail.com> wrote:
> The size of `struct flow_offload` has grown beyond 256 bytes on 64-bit
> kernels (currently 280 bytes) because of the `flow_offload_tunnel`
> member added recently. So kmalloc() allocates from the kmalloc-512 slab,
> causing significant memory waste per entry.
> 
> Introduce a dedicated slab cache for flow entries to reduce memory
> footprint. Results in a reduction from 512 bytes to 320 bytes per entry
> on x86_64 kernels.

Ok, but please use KMEM_CACHE(), we've had a bunch of patches
that removed kmem_cache_create() in several places, I would like
to avoid a followup patch.

  reply	other threads:[~2026-01-29 10:26 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-01-29 10:12 [PATCH nf-next] netfilter: flowtable: dedicated slab for flow entry Qingfang Deng
2026-01-29 10:26 ` Florian Westphal [this message]
2026-01-29 12:06   ` Qingfang Deng
2026-01-29 12:21     ` Florian Westphal

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=aXs14ZJGN3lDnMDc@strlen.de \
    --to=fw@strlen.de \
    --cc=coreteam@netfilter.org \
    --cc=davem@davemloft.net \
    --cc=dqfext@gmail.com \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lorenzo@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=netfilter-devel@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=pablo@netfilter.org \
    --cc=phil@nwl.cc \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox