Re: [PATCH v3 10/36] net/intel: consolidate checksum mask definition

Bruce Richardson
2026-02-09T15:00:32Z

On Mon, Feb 09, 2026 at 11:40:45AM +0000, Bruce Richardson wrote:
> On Fri, Feb 06, 2026 at 11:25:36AM +0000, Loftus, Ciara wrote:
> > > Subject: [PATCH v3 10/36] net/intel: consolidate checksum mask definition
> > >
> > > Create a common definition for checksum masks across iavf, idpf, i40e
> > > and ice drivers.
> > >
> > > Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
> > > ---
> > > drivers/net/intel/common/tx.h | 8 ++++++++
> > > drivers/net/intel/i40e/i40e_rxtx.c | 7 +------
> > > drivers/net/intel/iavf/iavf_rxtx.c | 2 +-
> > > drivers/net/intel/iavf/iavf_rxtx.h | 8 --------
> > > drivers/net/intel/ice/ice_rxtx.c | 8 +-------
> > > drivers/net/intel/idpf/idpf_common_rxtx.c | 4 ++--
> > > drivers/net/intel/idpf/idpf_common_rxtx.h | 7 +------
> > > 7 files changed, 14 insertions(+), 30 deletions(-)
> > >
> > > diff --git a/drivers/net/intel/common/tx.h b/drivers/net/intel/common/tx.h
> > > index 01e42303b4..928fad1df5 100644
> > > --- a/drivers/net/intel/common/tx.h
> > > +++ b/drivers/net/intel/common/tx.h
> > > @@ -53,6 +53,14 @@
> > > /* Common maximum data per TX descriptor */
> > > #define CI_MAX_DATA_PER_TXD (CI_TXD_QW1_TX_BUF_SZ_M >>
> > > CI_TXD_QW1_TX_BUF_SZ_S)
> > >
> > > +/* Checksum offload mask to identify packets requesting offload */
> > > +#define CI_TX_CKSUM_OFFLOAD_MASK (RTE_MBUF_F_TX_IP_CKSUM |
> > > \
> > > + RTE_MBUF_F_TX_L4_MASK | \
> > > + RTE_MBUF_F_TX_TCP_SEG | \
> > > + RTE_MBUF_F_TX_UDP_SEG | \
> > > + RTE_MBUF_F_TX_OUTER_IP_CKSUM |
> > > \
> > > + RTE_MBUF_F_TX_OUTER_UDP_CKSUM)
> > > +
> > > /**
> >
> >
> > <snip>
> >
> > > diff --git a/drivers/net/intel/idpf/idpf_common_rxtx.h
> > > b/drivers/net/intel/idpf/idpf_common_rxtx.h
> > > index b88a87402d..fe7094d434 100644
> > > --- a/drivers/net/intel/idpf/idpf_common_rxtx.h
> > > +++ b/drivers/net/intel/idpf/idpf_common_rxtx.h
> > > @@ -39,13 +39,8 @@
> > > #define IDPF_RLAN_CTX_DBUF_S 7
> > > #define IDPF_RX_MAX_DATA_BUF_SIZE (16 * 1024 - 128)
> > >
> > > -#define IDPF_TX_CKSUM_OFFLOAD_MASK ( \
> > > - RTE_MBUF_F_TX_IP_CKSUM | \
> > > - RTE_MBUF_F_TX_L4_MASK | \
> > > - RTE_MBUF_F_TX_TCP_SEG)
> > > -
> > > #define IDPF_TX_OFFLOAD_MASK ( \
> > > - IDPF_TX_CKSUM_OFFLOAD_MASK | \
> > > + CI_TX_CKSUM_OFFLOAD_MASK | \
> >
> > With this change should the features in idpf.ini be updated to include
> > Inner L3/L4 checksum?
> > And IDPF_TX_SCALAR_OFFLOADS update to include
> > RTE_ETH_TX_OFFLOAD_OUTER_IPV4_CKSUM
> > RTE_ETH_TX_OFFLOAD_OUTER_UDP_CKSUM
> >
>
> I didn't add it because I hadn't tested it, but since it's using the same
> code as other drivers it's probably safe enough to add, I suppose.
>
Changed my mind here, as I am doing the rework on this set. Leaving this
as-is for now until I get to validate it.

/Bruce