Re: [PATCH v1 3/3] net/af_packet: software checksum and tx poll control

Stephen Hemminger
2026-01-28T17:36:17Z

On Tue, 27 Jan 2026 23:05:54 -0800
Scott Mitchell <scott.k.mitch1@gmail.com> wrote:

> > I don't think each driver should be doing its own checksum helper.
> > It should be done at application or through libraries.
> > All modern hardware does checksum offload, so if it doesn't probably
> > a driver bug.
>
> The goal from the app perspective is to set rte_eth_txmode.offloads
> consistently across PMDs. Hardware devices are good but software
> devices like af_packet don't provide a consistent experience. The
> approach in this patch is similar to existing software eth devices tap
> [1] and vhost [2]. In v2 I will share checksum code with tap to avoid
> duplication and ensure they remain consistent.
>
> [1] https://github.com/DPDK/dpdk/blob/v25.11/drivers/net/tap/rte_eth_tap.c#L559-L624
> [2] https://github.com/DPDK/dpdk/blob/v25.11/drivers/net/vhost/rte_eth_vhost.c#L317-L357
>
> > Needs to be a separate patch. Don't do two things in one patch.
> > Not sure if some variant of the existing configure thresholds
> > could be used for this.
>
> ack, will split txpoll control. I'm not aware of any other way to
> prevent poll if dpdk tx is faster than kernel rx.

Well tap should NOT be doing software GSO and LRO in DPDK.
The kernel driver has ability to do that, and is better done there.