net/enic: add support for TSO
PATCH 1/1 net/enic: add support for TSO
The enic TSO implementation requires that the length of the Eth/IP/TCP headers be passed to the NIC. Other than that, it's just a matter of setting the mss and offload mode on a per packet basis.
In TSO mode, IP and TCP checksums are offloaded even if not requested with mb->ol_flags.
--- drivers/net/enic/enic_ethdev.c | 3 +- drivers/net/enic/enic_rxtx.c | 93 ++++++++++++++++++++++++++++++++++++------ 2 files changed, 83 insertions(+), 13 deletions(-)
drivers/net/enic/enic_ethdev.c +2 -1
@@ -475,7 +475,8 @@ static void enicpmd_dev_info_get(struct rte_eth_dev *eth_dev,DEV_TX_OFFLOAD_VLAN_INSERT |DEV_TX_OFFLOAD_IPV4_CKSUM |DEV_TX_OFFLOAD_UDP_CKSUM | -DEV_TX_OFFLOAD_TCP_CKSUM ; +DEV_TX_OFFLOAD_TCP_CKSUM | +DEV_TX_OFFLOAD_TCP_TSO ; device_info->default_rxconf = (struct rte_eth_rxconf ) { .rx_free_thresh =ENIC_DEFAULT_RX_FREE_THRESH };
drivers/net/enic/enic_rxtx.c +81 -12
139 lines not on this page · raw message
Signature · 1 line
2.10.0
Hi John,
Quoted 8 lines · John Daley
The enic TSO implementation requires that the length of the Eth/IP/TCP headers be passed to the NIC. Other than that, it's just a matter of setting the mss and offload mode on a per packet basis.
In TSO mode, IP and TCP checksums are offloaded even if not requested with
mb->ol_flags.Signed-off-by John Daley <[email protected]>
Can you please update doc/guides/nics/features/enic.ini to document the TSO feature in this patch?
Thanks,
ferruh
Quoted 1 line
---
<...>
PATCH v2 1/1 net/enic: add support for TSO
The enic TSO implementation requires that the length of the Eth/IP/TCP headers be passed to the NIC. Other than that, it's just a matter of setting the mss and offload mode on a per packet basis.
In TSO mode, IP and TCP checksums are offloaded even if not requested with mb->ol_flags.
---
v2: document TSO feature for enic
doc/guides/nics/features/enic.ini | 1 + drivers/net/enic/enic_ethdev.c | 3 +- drivers/net/enic/enic_rxtx.c | 93 ++++++++++++++++++++++++++++++++++----- 3 files changed, 84 insertions(+), 13 deletions(-)
doc/guides/nics/features/enic.ini +1 -0
@@ -10,6 +10,7 @@ Queue start/stop = Y MTU update = Y Jumbo frame = Y Scattered Rx = Y +TSO = Y Promiscuous mode = Y Unicast MAC filter = Y Multicast MAC filter = Y
drivers/net/enic/enic_ethdev.c +2 -1
@@ -475,7 +475,8 @@ static void enicpmd_dev_info_get(struct rte_eth_dev *eth_dev,DEV_TX_OFFLOAD_VLAN_INSERT |DEV_TX_OFFLOAD_IPV4_CKSUM |DEV_TX_OFFLOAD_UDP_CKSUM | -DEV_TX_OFFLOAD_TCP_CKSUM ; +DEV_TX_OFFLOAD_TCP_CKSUM | +DEV_TX_OFFLOAD_TCP_TSO ; device_info->default_rxconf = (struct rte_eth_rxconf ) { .rx_free_thresh =ENIC_DEFAULT_RX_FREE_THRESH };
drivers/net/enic/enic_rxtx.c +81 -12
139 lines not on this page · raw message
Signature · 1 line
2.10.0
PATCH v3 1/1 net/enic: add support for TSO
In reply to Ferruh YigitThe enic TSO implementation requires that the length of the Eth/IP/TCP headers be passed to the NIC. Other than that, it's just a matter of setting the mss and offload mode on a per packet basis.
In TSO mode, IP and TCP checksums are offloaded even if not requested with mb->ol_flags.
---
v2: document TSO feature for enic
v3: initialize enic mss field on every packet
doc/guides/nics/features/enic.ini | 1 + drivers/net/enic/enic_ethdev.c | 3 +- drivers/net/enic/enic_rxtx.c | 90 ++++++++++++++++++++++++++++++++++----- 3 files changed, 83 insertions(+), 11 deletions(-)
doc/guides/nics/features/enic.ini +1 -0
@@ -10,6 +10,7 @@ Queue start/stop = Y MTU update = Y Jumbo frame = Y Scattered Rx = Y +TSO = Y Promiscuous mode = Y Unicast MAC filter = Y Multicast MAC filter = Y
drivers/net/enic/enic_ethdev.c +2 -1
@@ -475,7 +475,8 @@ static void enicpmd_dev_info_get(struct rte_eth_dev *eth_dev,DEV_TX_OFFLOAD_VLAN_INSERT |DEV_TX_OFFLOAD_IPV4_CKSUM |DEV_TX_OFFLOAD_UDP_CKSUM | -DEV_TX_OFFLOAD_TCP_CKSUM ; +DEV_TX_OFFLOAD_TCP_CKSUM | +DEV_TX_OFFLOAD_TCP_TSO ; device_info->default_rxconf = (struct rte_eth_rxconf ) { .rx_free_thresh =ENIC_DEFAULT_RX_FREE_THRESH };
drivers/net/enic/enic_rxtx.c +80 -10
127 lines not on this page · raw message
Signature · 1 line
2.10.0
Ferruh Yigit
AppliedQuoted 8 lines · John Daley
The enic TSO implementation requires that the length of the Eth/IP/TCP headers be passed to the NIC. Other than that, it's just a matter of setting the mss and offload mode on a per packet basis.
In TSO mode, IP and TCP checksums are offloaded even if not requested with
mb->ol_flags.Signed-off-by John Daley <[email protected]>
Applied to dpdk-next-net/master, thanks.