public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Nicolai Buchwitz <nb@tipi-net.de>
To: Florian Fainelli <florian.fainelli@broadcom.com>
Cc: "Andrew Lunn" <andrew+netdev@lunn.ch>,
	"David S . Miller" <davem@davemloft.net>,
	"Eric Dumazet" <edumazet@google.com>,
	"Jakub Kicinski" <kuba@kernel.org>,
	"Paolo Abeni" <pabeni@redhat.com>,
	"Doug Berger" <opendmb@gmail.com>,
	"Broadcom internal kernel review list"
	<bcm-kernel-feedback-list@broadcom.com>,
	"Vikas Gupta" <vikas.gupta@broadcom.com>,
	"Bhargava Marreddy" <bhargava.marreddy@broadcom.com>,
	"Rajashekar Hudumula" <rajashekar.hudumula@broadcom.com>,
	"Eric Biggers" <ebiggers@kernel.org>,
	"Heiner Kallweit" <hkallweit1@gmail.com>,
	"Markus Blöchl" <mbloch@rooftopnetworks.de>,
	"Arnd Bergmann" <arnd@arndb.de>,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH net-next 3/6] net: bcmgenet: add basic XDP support (PASS/DROP)
Date: Sat, 14 Mar 2026 20:48:07 +0100	[thread overview]
Message-ID: <efdd4208d96c720e34bf314dd1ba5d28@tipi-net.de> (raw)
In-Reply-To: <e3d33a3e-9552-4f2d-99b6-76a1e203603d@broadcom.com>

On 13.3.2026 23:48, Florian Fainelli wrote:
> On 3/13/26 02:20, Nicolai Buchwitz wrote:
>> Add XDP program attachment via ndo_bpf and execute XDP programs in the
>> RX path. Supported actions:
>> 
>>    - XDP_PASS: build SKB from the (possibly modified) xdp_buff and 
>> pass
>>      to the network stack, handling xdp_adjust_head/tail correctly
>>    - XDP_DROP: return the page to page_pool, no SKB allocated
>>    - XDP_ABORTED: same as DROP with trace_xdp_exception
>> 
>> XDP_TX and XDP_REDIRECT are not yet supported and will return
>> XDP_ABORTED.
>> 
>> The XDP hook runs after the HW error checks but before SKB 
>> construction,
>> so dropped packets avoid all SKB allocation overhead.
>> 
>> Advertise NETDEV_XDP_ACT_BASIC in xdp_features.
>> 
>> Signed-off-by: Nicolai Buchwitz <nb@tipi-net.de>
>> ---
> 
> [snip]
> 
>> @@ -2345,12 +2397,6 @@ static unsigned int bcmgenet_desc_rx(struct 
>> bcmgenet_rx_ring *ring,
>>   		hard_start = page_address(rx_page) + rx_off;
>>   		status = (struct status_64 *)hard_start;
>>   		dma_length_status = status->length_status;
>> -		if (dev->features & NETIF_F_RXCSUM) {
>> -			rx_csum = (__force __be16)(status->rx_csum & 0xffff);
>> -			if (rx_csum) {
>> -				/* defer csum setup to after skb is built */
>> -			}
>> -		}
> 
> Did you intend for that hunk to be deleted?

Yes, (kinda) intentional. Patch 1 moved the csum setup after SKB 
construction
(since we no longer have an SKB at that point), but left the early read
as a dead no-op - patch 3 then removed it. I'll clean this up in v2 by
dropping the dead block directly in patch 1 instead.

Nicolai

  reply	other threads:[~2026-03-14 19:48 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-13  9:20 [PATCH net-next 0/6] net: bcmgenet: add XDP support Nicolai Buchwitz
2026-03-13  9:20 ` [PATCH net-next 1/6] net: bcmgenet: convert RX path to page_pool Nicolai Buchwitz
2026-03-13  9:20 ` [PATCH net-next 2/6] net: bcmgenet: register xdp_rxq_info for each RX ring Nicolai Buchwitz
2026-03-13  9:20 ` [PATCH net-next 3/6] net: bcmgenet: add basic XDP support (PASS/DROP) Nicolai Buchwitz
2026-03-13 22:48   ` Florian Fainelli
2026-03-14 19:48     ` Nicolai Buchwitz [this message]
2026-03-13  9:20 ` [PATCH net-next 4/6] net: bcmgenet: add XDP_TX support Nicolai Buchwitz
2026-03-13 11:37   ` Subbaraya Sundeep
2026-03-13 12:45     ` Nicolai Buchwitz
2026-03-13  9:21 ` [PATCH net-next 5/6] net: bcmgenet: add XDP_REDIRECT and ndo_xdp_xmit support Nicolai Buchwitz
2026-03-13  9:21 ` [PATCH net-next 6/6] net: bcmgenet: add XDP statistics counters Nicolai Buchwitz
2026-03-13 23:01 ` [PATCH net-next 0/6] net: bcmgenet: add XDP support Florian Fainelli
2026-03-14  0:13   ` Florian Fainelli
2026-03-14 19:51   ` Nicolai Buchwitz
2026-03-14 15:52 ` Jakub Kicinski
2026-03-14 19:52   ` Nicolai Buchwitz

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=efdd4208d96c720e34bf314dd1ba5d28@tipi-net.de \
    --to=nb@tipi-net.de \
    --cc=andrew+netdev@lunn.ch \
    --cc=arnd@arndb.de \
    --cc=bcm-kernel-feedback-list@broadcom.com \
    --cc=bhargava.marreddy@broadcom.com \
    --cc=davem@davemloft.net \
    --cc=ebiggers@kernel.org \
    --cc=edumazet@google.com \
    --cc=florian.fainelli@broadcom.com \
    --cc=hkallweit1@gmail.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mbloch@rooftopnetworks.de \
    --cc=netdev@vger.kernel.org \
    --cc=opendmb@gmail.com \
    --cc=pabeni@redhat.com \
    --cc=rajashekar.hudumula@broadcom.com \
    --cc=vikas.gupta@broadcom.com \
    /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