On Thu, Aug 24, 2023 at 2:04 PM Ilya Maximets <[email protected]> wrote:
>
> On 8/22/23 10:11, David Marchand wrote:
> > OVS current sets RTE_MBUF_F_TX_IPV[46] flags in early stages of the
> > packet reception and keeps track of the IP packet type as the packet
> > goes through OVS pipeline.
> > When a packet leaves OVS and hits a DPDK driver, OVS may not request IP
> > checksum offloading but leaves one of this packet type flag in ol_flags.
> >
> > Setting RTE_MBUF_F_TX_IPV4 without RTE_MBUF_F_TX_IPSUM is not defined
> > in the DPDK api.
>
> I'd re-phrase this, because it seems clear to me from the DPDK API
> description that these flags are only meaningful if offload is
> requested, i.e. drivers should not act on them if offload is not
> requested.

Let's see if my v2 is better.

[snip]

> > @@ -2431,6 +2431,7 @@ netdev_dpdk_prep_hwol_packet(struct netdev_dpdk *dev, 
> > struct rte_mbuf *mbuf)
> >
> >      if (!(mbuf->ol_flags & (RTE_MBUF_F_TX_IP_CKSUM | RTE_MBUF_F_TX_L4_MASK
> >                              | RTE_MBUF_F_TX_TCP_SEG))) {
> > +        mbuf->ol_flags &= ~(RTE_MBUF_F_TX_IPV4|RTE_MBUF_F_TX_IPV6);
>
> This line needs some spaces.

Sure.


>
> Also, it's an extra write per packet.  Does it have any measurable
> performance impact?

I tested before/after with two CX6 ports (5 runs of zeroloss tests
with basic OF rules in=dpdk0,out=dpdk1) and I see no meaningful
difference (under 0.1% difference).


-- 
David Marchand

_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to