Article View: linux.kernel.netdev
Article #26540Re: [PATCH net-next] eth: fbnic: Support XDP redirect
From: Björn Töpel
Date: Thu, 03 Dec 2026 17:59
Date: Thu, 03 Dec 2026 17:59
40 lines
9706 bytes
9706 bytes
Alexander Duyck <alexanderduyck@meta.com> writes:
> On Thu, Nov 26, 2026 at 9:53 PM Björn Töpel <bjorn@kernel.org> wrote:
>
> ...
>
>> diff --git a/drivers/net/ethernet/meta/fbnic/fbnic_txrx.h b/drivers/net/ethernet/meta/fbnic/fbnic_txrx.h
>> index 6ee3cce3d942..7bc0c25ac50b 100644
>> --- a/drivers/net/ethernet/meta/fbnic/fbnic_txrx.h
>> +++ b/drivers/net/ethernet/meta/fbnic/fbnic_txrx.h
>> @@ -173,6 +173,7 @@ struct fbnic_napi_vector {
>> u16 v_idx;
>> u8 txt_count;
>> u8 rxt_count;
>> + bool xdp_flush; /* An XDP redirect awaits xdp_do_flush() */
>
> Please make this a u8 rather than a bool. The other members of this
> struct are fixed width, and coding-style.rst asks that structures laid
> out for size avoid bool.
>
> The rest looks good to me. The xdp_buff already holds the page_pool
> references for the header and each frag, so a successful redirect
> hands them to the target, and a failed one is dropped through the
> fbnic_put_pkt_buff function as XDP_DROP is. The flush at the end of
> the fbnic_clean_rcq function runs on every pass, so nothing stays
> queued past the poll.
>
> With the u8 change:
> Reviewed-by: Alexander Duyck <alexanderduyck@fb.com>
Thank you, Alex! And thanks for taking a look.
pw-bot: cr
Björn
Technical Details
Message-ID:
<87qzfy1bzz.fsf@all.your.base.are.belong.to.us>Path:
mbox-mo1.pugleaf.net!feed-eu-txt.newsdeef.eu!feed-eu-ch.newsdeef.eu!srl.newsdeef.eu!news.mb-net.net!open-news-network.org!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-376806-linux-kernel-netdev=dewy.ruReferences:
<20261127055334.3156389-1-bjorn@kernel.org> <CAOqJK25whvfAP-UGjcJwsMkcaVmq_e0sdo=8YLuRU=T7+WWzDg@mail.gmail.com>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!feed-eu-txt.newsdeef.eu!feed-eu-ch.newsdeef.eu!srl.newsdeef.eu!news.mb-net.net!open-news-network.org!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-376806-linux-kernel-netdev=dewy.ru From: bjorn@kernel.org (Björn Töpel) Newsgroups: linux.kernel.netdev Subject: Re: [PATCH net-next] eth: fbnic: Support XDP redirect Date: Thu, 03 Dec 2026 18:59:28 +0100 Organization: Usenet Network Message-ID: <87qzfy1bzz.fsf@all.your.base.are.belong.to.us> References: <20261127055334.3156389-1-bjorn@kernel.org> <CAOqJK25whvfAP-UGjcJwsMkcaVmq_e0sdo=8YLuRU=T7+WWzDg@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: usenet.network; logging-data="2559964"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:l7mmaI9kbd9spym7ZOQ0bwvIcAE= sha256:URlCJ5e5ZSSCEiuEG/C4mryasnoiY76WUU7vXGczQHM= sha1:Vh4yu8utrbUXEyP4T8P+3RKPIuU= sha256:hLvdfwjbsU1B5BIj59FyZ25MqF/LTYtMhbubV8pgPvw= 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 B5E381179FE; Thu, 3 Dec 2026 20:59:51 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -3.64 X-Spam-Status: No, score=-3.64 tagged_above=-9999 required=6.31 tests=[DCC_REPUT_70_89=0.1, DKIMWL_WL_HIGH=-0.24, 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 o9PoHUylud7M; Thu, 3 Dec 2026 20:59:49 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=netdev+bounces-376806-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 sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10]) by mail.dewy.ru (Postfix) with ESMTPS id DA3CF1179B9; Thu, 3 Dec 2026 20:59:37 +0300 (MSK) X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92]) by sea.lore.kernel.org (Postfix) with ESMTP id 1BBBC289D7; Thu, 3 Dec 2026 17:59:35 +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=1796320773; b=poqElO4HT+7ZS3RqmogqFToS/Em5tvq8jQt2vNyjXwuoPTOyvOtylGccx5ROqjvQ9Olx asPTwMRa5LY5yT5Gdq9411eC/kZd/dYD6H/Dg0iUftvceSl9wNSsDiBciFJT9t0QIbH8E iR2rKb4nzyvxEjGVwpnOVKBi+ZL8E/Iaxd3MNELBoDmVZjmHmIMFF0PJpKsRStGmuOgId eJHNR6cND83rRTOJKAN0QknLme8dcPAXXhepfbHBGQnsCubPWuGv8h/O8E27j0X4Mpmsw 2Rnf6xpaWiwee05gj6k6E5QLbkSsFXxv21JvOM6gtfPnQ1lSCv08ibg/CDU8rtJ4EPA== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796320773; h=X-Original-To:Received:Received:DKIM-Signature:From:To:Cc:Subject: In-Reply-To:References:Date:Message-ID:X-Mailing-List:List-Id: List-Post:List-Help:List-Subscribe:List-Unsubscribe:List-Owner: Precedence:MIME-Version:Content-Type:Content-Transfer-Encoding; bh=pcSFS0NwUrC3Cgu2lMUtykWDU0bY8uONQXiO9W4KA08=; b=EHG/0V+T1M2+Qmi7hC5rpQWQbnPTyjdTecE1h66UJomfSzCAmtqJ440HWjV0nj7FfDJo SOO4Y4jBhwQvOG4475ebm8q0dbN8p32Rp4u06dc/0BLobMH6B8K9zFxkBswreYBvrjy+h arH1BSNcPRkGhqZLfI4EFlMKFJ4KHAD3OrTBvjm5ihjvGFbWJs1y+t4K3zJygkMcW0Ymv k9pp+H5SaoiCO3zltnEL3VtHqax/VnkX3EPYSd5GxGK49Q8Bvzx/NU0kxYQYcvAFtbBh2 Ba6LoUUVN9/ARMJVFlKq/7pVovTbH/uVFmR0wIEXnB/wkSKFBjHgRR/8BbOK9g0frdA== 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=dJy9Xvqh; 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 CB5D8606A693; Thu, 3 Dec 2026 17:59:33 +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=dJy9Xvqh 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=1796320773; b=x0NUKG/AETH7WRixYpf7oKPh4JwsAVX21eDCFCYDP1lx4TM93GwZcDkrmK2HvK2OK96e +b4+rVmgjv7YlD7ARPsoY3M4L0poNK6DYkBSfwO28Rm+4cZSNMHA+D+EQcCVODrSGv4sD csgnOkHcVSldOQZJvlRh1gSDDHkkIQYLXs32U/bw4e26tQmkwjournFR8magwz8vtvuko Gv3VwR+8WX7SUdv4ND5b1ZEPTgRcqfqz2ELzpmfGgvjYimEwMT0564UlR2OHnLTEY9wJx gGrDMapXpjP9kSgbxb239+vFqRl+J7rssL+pRGuw6DucGbr8if1rkK4mEhzRGQpce9Q== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796320773; h=Received:DKIM-Signature:From:To:Cc:Subject:In-Reply-To:References: Date:Message-ID:MIME-Version:Content-Type:Content-Transfer-Encoding; bh=pcSFS0NwUrC3Cgu2lMUtykWDU0bY8uONQXiO9W4KA08=; b=fmChMcngiUYzBh3Z5eLcF2R4dmylDViPVr0Z/zQo4ioxMYxlBoVJvqCVxgMNLthLAs+U UGofn5asIzf/LpuyL2EVBeLeTv9VDIwVMWt1Wcc7CbkgHO2WnLieLsrDfp0DA95zq2iYm IyRoLwOG1xai8A7BFLWZW4dEIe8+zsBNZSNT+2L0U/h5etpBTZvFFxiTlZ8FxH4+buaLi 1gaNHH6KvOhEjdoY/jlExq2ZGJcUcivfdoVYPYSKWqrnAr+u56/3t546ky/myl+hF9057 LxXrPPbXqUFwjGbhS9+PgKVcUAuW46tINpnpXckl4BW9GqpUREKzgZMVM3YHlVgPzSw== 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=dJy9Xvqh; 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 E7C27606A681; Thu, 3 Dec 2026 17:59:32 +0000 (UTC) X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id 017EC1F00898; Thu, 3 Dec 2026 17:59:31 +0000 (UTC) X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796320772; bh=pcSFS0NwUrC3Cgu2lMUtykWDU0bY8uONQXiO9W4KA08=; h=From:To:Cc:Subject:In-Reply-To:References:Date; b=dJy9XvqhS3MIrw6+Pv00eTBEaS7KH8qC0uMVESX2/KmBAM98WZ0rG2Bkj6tDDiIJ9 ZOvYFoigZdAmnnAP1w9CS4khAdEpfRqQkBASb0QhA2tRG/8Un0q9yhAsshbQ2DqKb2 JtoLs89tpqoYSiiUQihi/BGoWywIyNyzHm+flkSujapXi2WMh+Q8l3QxwlorF/xUnq K4Z4q89V8pD3wsSQwXb7ri+ELTmVPvNw7RHlUtEfw6yTU76AD3NiNO+3sDSDURKpXt 3WO7gF2x4AkTvcZi//MWacKy3/niaXah6StQc3pYfyjSXIlJwEXeuSyyjO1+X0A0Jv xU82n4gIx4oLQ== X-Cc: Alexander Duyck <alexanderduyck@fb.com>, Jakub Kicinski <kuba@kernel.org>, Andrew Lunn <andrew+netdev@lunn.ch>, "David S. Miller" <davem@davemloft.net>, Eric Dumazet <edumazet@kernel.org>, Paolo Abeni <pabeni@redhat.com>, Alexei Starovoitov <ast@kernel.org>, Daniel Borkmann <daniel@iogearbox.net>, Jesper Dangaard Brouer <hawk@kernel.org>, John Fastabend <john.fastabend@gmail.com>, netdev@vger.kernel.org, bpf@vger.kernel.org, kernel-team@meta.com, Stanislav Fomichev <sdf@fomichev.me>, Simon Horman <horms@kernel.org>, Dimitri Daskalakis <dimitri.daskalakis1@gmail.com>, Bobby Eshleman <bobbyeshleman@meta.com>, Daniel Zahka <daniel.zahka@gmail.com>, "Mike Marciniszyn (Meta)" <mike.marciniszyn@gmail.com>, Mohsin Bashir <hmohsin@meta.com>, Breno Leitao <leitao@debian.org> X-In-Reply-To: <CAOqJK25whvfAP-UGjcJwsMkcaVmq_e0sdo=8YLuRU=T7+WWzDg@mail.gmail.com> 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