[dpdk-dev] [PATCH v6 1/2] ethdev: introduce generic IP/UDP tunnel checksum and TSO

Thomas Monjalon thomas at monjalon.net
Wed Apr 18 20:02:35 CEST 2018


18/04/2018 18:45, Ananyev, Konstantin:
> From: Thomas Monjalon
> > 18/04/2018 15:58, Xueming Li:
> > > The new flag PKT_TX_TUNNEL_IP is redundant with PKT_TX_OUTER_IP_CKSUM.
> > > The old flag PKT_TX_OUTER_IP_CKSUM can be deprecated and removed in
> > > later release.
> > >
> > > Signed-off-by: Xueming Li <xuemingl at mellanox.com>
> > 
> > Except a small comment below, it looks OK.
> > 
> > Acked-by: Thomas Monjalon <thomas at monjalon.net>
> > 
> > Please send a deprecation notice for PKT_TX_OUTER_IP_CKSUM.
> 
> I probably missed something, but why PKT_TX_OUTER_IP_CKSUM
> is supposed to be deprecated?

Because PKT_TX_TUNNEL_* flags sepersede it. I think we need to discuss it.

We use the offload flags PKT_TX_TUNNEL_* when we request some offloads
in the outer and the inner headers at the same time.
When setting a tunnel flag PKT_TX_TUNNEL_*, it can be expected that
the outer checksums will be offloaded, otherwise it is almost
impossible to request an offload in the inner header.
In the case of an UDP tunnel, any change in the inner packet will
require an UDP checksum update.
In the case of an IP tunnel, a change of the inner packet size
(like TSO) will require an IP checksum update.

If we really require PKT_TX_OUTER_IP_CKSUM to be set in addition to
PKT_TX_TUNNEL_* flags, then we should add more PKT_TX_OUTER_*_CKSUM,
like PKT_TX_OUTER_UDP_CKSUM which is missing.

Opinions?




More information about the dev mailing list