🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.kernel.netdev
Article #14800

Re: [PATCH net-next] net: ena: reuse the whole RX page on 64kB page kernels

#14800
From: Jakub Kicinski
Date: Thu, 12 Nov 2026 00:47
18 lines
8622 bytes
On Fri, 06 Nov 2026 03:17:11 +0000 Harry Yoo (Meta) wrote:
> This shows up when RX data stays in socket receive queues, as each
> queued skb keeps the whole 64kB page alive while at most 16kB of it
> holds data. On an EC2 t4g.large instance (64kB pages, 8GB memory) with
> 519MB left unread across 64 TCP sockets, RX pages pinned 2869MB of
> memory while the socket layer accounted only 687MB.

I'm not sure you're actually fixing the problem you're describing?
You optimize the memory use but the (unused) tail of the buffer is
still not charged to any skb, is it? Or does it now fit perfectly?

Normally when the page can no longer be chunked up we should charge
the tail to whoever happened to use it last (see the page pool code
which does that).

Either way, you have to respin this on top of Breno's fix which
was applied earlier today.
Technical Details
Message-ID: <20261111164751.5ac643fa@kernel.org>
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-361407-linux-kernel-netdev=dewy.ru
References: <20261106-ena-rx-reuse-64k-page-v1-1-ac75b20c5de8@kernel.org>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-361407-linux-kernel-netdev=dewy.ru
From: kuba@kernel.org (Jakub Kicinski)
Newsgroups: linux.kernel.netdev
Subject: Re: [PATCH net-next] net: ena: reuse the whole RX page on 64kB page
 kernels
Date: Wed, 11 Nov 2026 16:47:51 -0800
Organization: Usenet Network
Message-ID: <20261111164751.5ac643fa@kernel.org>
References: <20261106-ena-rx-reuse-64k-page-v1-1-ac75b20c5de8@kernel.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
Injection-Info: usenet.network;
	logging-data="977078"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:ymUwkS8qeLI76DcZDJ3QJYAE1HE= sha256:IKsbEhStB5EtYg3T7CvphTgPgj0pfijC2KFYLjj0zWc=
	sha1:Xei71n5ohIqwG15/Nvtu6iJADQM= sha256:iQcRK+TU/m7kTUxxRNZ3VeS8cee8zX6gtjFo5JvKN8k=
List-ID: <netdev.vger.kernel.org>
X-Mailpost-Empty-Hdrs: X-Spam-Level
X-Received: from localhost (localhost [127.0.0.1])
	by mail.dewy.ru (Postfix) with ESMTP id E71DE11409E; Thu, 12 Nov 2026 04:00:01 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -3.401
X-Spam-Status: No, score=-3.401 tagged_above=-9999 required=6.31
	tests=[DCC_REPUT_70_89=0.1, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1,
	DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,
	MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001,
	SPF_PASS=-0.001] autolearn=ham autolearn_force=no
X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key)
	header.d=kernel.org
X-Received: from mail.dewy.ru ([127.0.0.1])
	by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024)
	with ESMTP id zznFlU8acgA9;
	Thu, 12 Nov 2026 03:59:58 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=104.64.211.4; helo=sin.lore.kernel.org; envelope-from=netdev+bounces-361407-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> 
X-Authentication-Results: OpenDMARC; dmarc=pass (p=quarantine dis=none) header.from=kernel.org
X-Received: from sin.lore.kernel.org (sin.lore.kernel.org [104.64.211.4])
	by mail.dewy.ru (Postfix) with ESMTPS id 1DFA9113FAE; Thu, 12 Nov 2026 03:59:48 +0300 (MSK)
X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92])
	by sin.lore.kernel.org (Postfix) with ESMTP id 007823CB4E; Thu, 12 Nov 2026 00:50:39 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1
X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass;
	t=1794444478;
	b=mlTm39ooP2b2zRhU+UXv1ctrE9sKG4IwgPhv3ojeGAn4GrHVePgmxtNBtj+XA6CO26wn
	 72UR+eMougmukQOVZxUDkb/6LdHvIf90eGkBG4iLdJbhOBF9suyJh1UQh4qvBEXQzOwIo
	 Z3w97fVH0m6rFX4Grd6XjNb6mScVnPOBFmU40Rc4Igc1ww/667Z15UWFO+xcUnYfE6JQ2
	 ggGCNlArQHlRVoDbiT0gTAHzvtS9GT1ROs6fPJip1MlnOVzBDSy11irJjok4vIwQ2f3FM
	 fcRor3DjAMWS0p2xYQI9nhmJqQoWpDCBEHLqt1LdC4V+LoGOX1KjaLJb57UTyvqQjPQ==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1794444478;
	h=X-Original-To:Received:Received:DKIM-Signature:Date:From:To:Cc:
	 Subject:Message-ID:In-Reply-To:References:X-Mailing-List:List-Id:
	 List-Post:List-Help:List-Subscribe:List-Unsubscribe:List-Owner:
	 Precedence:MIME-Version:Content-Type:Content-Transfer-Encoding;
	bh=uTKOSeg4aAvBBM1vll13yP+n+RppAFS5rFjbzOj7VD8=;
	b=hs60a7xYGFnu6O/inBR4fq2Hne83YfJ66RwAvg8dCZ9/as5I6p6dOpfSNgMKgCjbUsRh
	 gVsg0yCxhEQ+lJ6R0aBOlfC2H1GCKeVtdmTNkQlEHXlR5BEqeDlyQdnFUtgIpf/3I51BB
	 SbX5XkFUPk9zUZOd1Yb5qWz/8YPCZTS8TgCZd16vvoB+43isDh+6BP6tJ+mIHb+SeC5Fw
	 m3p+dTsAZuAOEMjcAZRGJIvNC/wL+byIu580ppPa/jnTkvmKiFkpydgiWKxGkkcwGiKhP
	 /lBVVSmxOW9QVNeLIh+piAOKavkQw2Lnv5a8p+gxKZ8jVZrrg27Eu0dhaG+7/dag75w==
X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; 
	dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=Q+jfCoPk;
	arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1
X-Received: from localhost.localdomain (localhost [127.0.0.1])
	by smtp.subspace.kernel.org (Postfix) with ESMTP id 5C25260A2622;
	Thu, 12 Nov 2026 00:47:58 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org;
	dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=Q+jfCoPk
X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18
X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none;
	t=1794444472;
	b=W4rO/CG3wLr8k0w0m/FrNN3MpPDZbfsPM+WMftMq5QB/0x4AgHAQJ+6hwkQ+1FM46g3Z
	 iMMeWlH8i0wdiJIkOacOHsRsliYtC1pvvBZrrNrnEd+OyK8a5+QDpv6SrPb2QvCB2wY+0
	 UMkVZuCUaJV8sw5fZxuLZVXLx7bsxTZj276IZbJljgogVcu13ULZZcHPPsUvuCleLHEYQ
	 PBxuLgcGmtvWBdzgf8Y4gD+ZY0sHlLBAIZIJDSrtbDa3v7JCTWUIfb1CdINj0CzCYCEbr
	 RnzkIbM/n2xjp13q7sXmcEXT2XnAhmqs9dJZ/jk+HQYWX1/PI96aQlLLqKTQ442LmTQ==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1794444472;
	h=Received:DKIM-Signature:Date:From:To:Cc:Subject:Message-ID:
	 In-Reply-To:References:MIME-Version:Content-Type:
	 Content-Transfer-Encoding;
	bh=uTKOSeg4aAvBBM1vll13yP+n+RppAFS5rFjbzOj7VD8=;
	b=tlyUxlHr8bApK5X5XXUY2M+PsTqWn+AMzcknE5sX+D+TdEXijiJTJUefWokmpKRlhrfO
	 pobGHTXW2w4s4jLA6SEBy4fg7f+HntOrm5uTQpVBgI1JWOWgPrtaXr9FsFiLSduCkO/Fa
	 2gN16YOq9+6Q08EJXqKc9CBbG9wUtL+V4Un2wALTsvaNHx6kwQgLeyWsFbrvYKuk466OS
	 3HjKrhmdy4tNqiUGTz261CzAd9uQtmwjLOEp+r0JX262OIECMF1eFOAt+JbZvalYhEtlY
	 Mw3Q5NKwUYqdHVRfW3jPXFDCfYlMx3f+z3rq5gfB86Cwp5CsofRaF/E9vffQjIBwbKA==
X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; 
	dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=Q+jfCoPk;
	arc=none smtp.remote-ip=100.103.45.18
X-Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature ECDSA (prime256v1))
	(No client certificate requested)
	by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7A84E606BB54;
	Thu, 12 Nov 2026 00:47:52 +0000 (UTC)
X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id B16CB1F00A05;
	Thu, 12 Nov 2026 00:47:51 +0000 (UTC)
X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org;
	s=k20260515; t=1794444472;
	bh=uTKOSeg4aAvBBM1vll13yP+n+RppAFS5rFjbzOj7VD8=;
	h=Date:From:To:Cc:Subject:In-Reply-To:References;
	b=Q+jfCoPkjYjUKDJnGYffEq0JBEUMsBQoZ33/AnsaDxLopny9QwL4403rcfX1l91/R
	 urDyObVp4tp3dh+aWK+zLvE3/9+75OJXOKjYwlhkKoEhsBjkhGkiToh159/OPKkEre
	 TTFnWgsBXBlq6xxeozFZamCJC1xTjPvaI5qjq30i3ifMpE2VrqxX7IJ9OX3ddOPrUE
	 2Ka29TPCVvcD2ymv4eflHezA4EF1MKHXwFP4VlbebTpM6BFyQrACiZGn/vHNPOXGN2
	 zRZKUTCpFwRx0ibqvNrsei2zJN6Hm2Hy9XtuftrLdnypQjBMLjoc/5rc8avSvoceYh
	 gJ7pu1/Eor8rQ==
X-Cc: Arthur Kiyanovski <akiyano@amazon.com>, David Arinzon
 <darinzon@amazon.com>, Andrew Lunn <andrew+netdev@lunn.ch>, "David S.
 Miller" <davem@davemloft.net>, Eric Dumazet <edumazet@kernel.org>, Paolo
 Abeni <pabeni@redhat.com>, Breno Leitao <leitao@debian.org>,
 kernel-team@meta.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org
X-In-Reply-To: <20261106-ena-rx-reuse-64k-page-v1-1-ac75b20c5de8@kernel.org>
X-Mailing-List: netdev@vger.kernel.org
X-List-Post: <mailto:netdev@vger.kernel.org>
X-List-Help: <mailto:netdev+help@vger.kernel.org>
X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org>
X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org>
X-List-Owner: <mailto:netdev+owner@vger.kernel.org>
X-Precedence: list