[4/4] net/iavf: enable UDP fragmentation offload
Checks
Commit Message
This commit enables transmit segmentation offload for UDP, including both
non-tunneled and tunneled packets.
The command "tso set <tso_segsz> <port_id>" or
"tunnel_tso set <tso_segsz> <port_id>" is used to enable UFO.
Signed-off-by: Zhichao Zeng <zhichaox.zeng@intel.com>
---
drivers/net/iavf/iavf_rxtx.c | 2 +-
drivers/net/iavf/iavf_rxtx.h | 2 ++
2 files changed, 3 insertions(+), 1 deletion(-)
Comments
> From: Zeng, ZhichaoX <zhichaox.zeng@intel.com>
> Sent: Thursday, April 13, 2023 1:35 PM
> To: dev@dpdk.org
> Cc: Zhang, Qi Z <qi.z.zhang@intel.com>; Xu, Ke1 <ke1.xu@intel.com>; Zeng,
> ZhichaoX <zhichaox.zeng@intel.com>; Wu, Jingjing <jingjing.wu@intel.com>;
> Xing, Beilei <beilei.xing@intel.com>
> Subject: [PATCH 4/4] net/iavf: enable UDP fragmentation offload
>
> This commit enables transmit segmentation offload for UDP, including both
> non-tunneled and tunneled packets.
>
> The command "tso set <tso_segsz> <port_id>" or "tunnel_tso set <tso_segsz>
> <port_id>" is used to enable UFO.
>
> Signed-off-by: Zhichao Zeng <zhichaox.zeng@intel.com>
Verified and Passed.
Two extra issues exists found blocking very limited part of validation.
1. On QEMU DCF not able to enable rx_vxlan.
2. IPv6 Tunneled UDP packets triggers MDD event.
Tested-by: Ke Xu <ke1.xu@intel.com>
> ---
> drivers/net/iavf/iavf_rxtx.c | 2 +-
> drivers/net/iavf/iavf_rxtx.h | 2 ++
> 2 files changed, 3 insertions(+), 1 deletion(-)
>
> -----Original Message-----
> From: Xu, Ke1 <ke1.xu@intel.com>
> Sent: Wednesday, May 24, 2023 1:21 PM
> To: Zeng, ZhichaoX <zhichaox.zeng@intel.com>; dev@dpdk.org
> Cc: Zhang, Qi Z <qi.z.zhang@intel.com>; Wu, Jingjing
> <jingjing.wu@intel.com>; Xing, Beilei <beilei.xing@intel.com>; Xu, Ke1
> <ke1.xu@intel.com>
> Subject: RE: [PATCH 4/4] net/iavf: enable UDP fragmentation offload
>
> > From: Zeng, ZhichaoX <zhichaox.zeng@intel.com>
> > Sent: Thursday, April 13, 2023 1:35 PM
> > To: dev@dpdk.org
> > Cc: Zhang, Qi Z <qi.z.zhang@intel.com>; Xu, Ke1 <ke1.xu@intel.com>;
> > Zeng, ZhichaoX <zhichaox.zeng@intel.com>; Wu, Jingjing
> > <jingjing.wu@intel.com>; Xing, Beilei <beilei.xing@intel.com>
> > Subject: [PATCH 4/4] net/iavf: enable UDP fragmentation offload
> >
> > This commit enables transmit segmentation offload for UDP, including
> > both non-tunneled and tunneled packets.
> >
> > The command "tso set <tso_segsz> <port_id>" or "tunnel_tso set
> > <tso_segsz> <port_id>" is used to enable UFO.
> >
> > Signed-off-by: Zhichao Zeng <zhichaox.zeng@intel.com>
>
> Verified and Passed.
>
> Two extra issues exists found blocking very limited part of validation.
> 1. On QEMU DCF not able to enable rx_vxlan.
> 2. IPv6 Tunneled UDP packets triggers MDD event.
>
> Tested-by: Ke Xu <ke1.xu@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
Applied to dpdk-next-net-intel.
Thanks
Qi
@@ -3622,7 +3622,7 @@ iavf_prep_pkts(__rte_unused void *tx_queue, struct rte_mbuf **tx_pkts,
ol_flags = m->ol_flags;
/* Check condition for nb_segs > IAVF_TX_MAX_MTU_SEG. */
- if (!(ol_flags & RTE_MBUF_F_TX_TCP_SEG)) {
+ if (!(ol_flags & (RTE_MBUF_F_TX_TCP_SEG | RTE_MBUF_F_TX_UDP_SEG))) {
if (m->nb_segs > IAVF_TX_MAX_MTU_SEG) {
rte_errno = EINVAL;
return i;
@@ -73,6 +73,7 @@
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)
@@ -85,6 +86,7 @@
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_TUNNEL_MASK | \
RTE_MBUF_F_TX_OUTER_IP_CKSUM | \
RTE_MBUF_F_TX_OUTER_UDP_CKSUM | \