* [PATCH] examples/ipsec-secgw: fix Tx checksum offload flag
@ 2022-09-30 12:40 Radu Nicolau
2022-10-18 15:39 ` Medvedkin, Vladimir
0 siblings, 1 reply; 5+ messages in thread
From: Radu Nicolau @ 2022-09-30 12:40 UTC (permalink / raw)
To: Radu Nicolau, Akhil Goyal; +Cc: dev, ndabilpuram
Fix a typo in computing port mask for Tx checksum offload capability.
Fixes: 4edcee19fc20 ("examples/ipsec-secgw: use Tx checksum offload conditionally")
Cc: ndabilpuram@marvell.com
Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
---
examples/ipsec-secgw/ipsec-secgw.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/examples/ipsec-secgw/ipsec-secgw.c b/examples/ipsec-secgw/ipsec-secgw.c
index 8a25b83535..75ba359e69 100644
--- a/examples/ipsec-secgw/ipsec-secgw.c
+++ b/examples/ipsec-secgw/ipsec-secgw.c
@@ -3042,7 +3042,7 @@ main(int32_t argc, char **argv)
port_init(portid, req_rx_offloads[portid],
req_tx_offloads[portid]);
if ((req_tx_offloads[portid] & RTE_ETH_TX_OFFLOAD_IPV4_CKSUM))
- ipv4_cksum_port_mask = 1U << portid;
+ ipv4_cksum_port_mask |= 1U << portid;
}
for (lcore_id = 0; lcore_id < RTE_MAX_LCORE; lcore_id++) {
--
2.25.1
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] examples/ipsec-secgw: fix Tx checksum offload flag
2022-09-30 12:40 [PATCH] examples/ipsec-secgw: fix Tx checksum offload flag Radu Nicolau
@ 2022-10-18 15:39 ` Medvedkin, Vladimir
0 siblings, 0 replies; 5+ messages in thread
From: Medvedkin, Vladimir @ 2022-10-18 15:39 UTC (permalink / raw)
To: Radu Nicolau, Akhil Goyal; +Cc: dev, ndabilpuram
Acked-by: Vladimir Medvedkin <vladimir.medvedkin@intel.com>
On 30/09/2022 13:40, Radu Nicolau wrote:
> Fix a typo in computing port mask for Tx checksum offload capability.
>
> Fixes: 4edcee19fc20 ("examples/ipsec-secgw: use Tx checksum offload conditionally")
> Cc: ndabilpuram@marvell.com
>
> Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
> ---
> examples/ipsec-secgw/ipsec-secgw.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/examples/ipsec-secgw/ipsec-secgw.c b/examples/ipsec-secgw/ipsec-secgw.c
> index 8a25b83535..75ba359e69 100644
> --- a/examples/ipsec-secgw/ipsec-secgw.c
> +++ b/examples/ipsec-secgw/ipsec-secgw.c
> @@ -3042,7 +3042,7 @@ main(int32_t argc, char **argv)
> port_init(portid, req_rx_offloads[portid],
> req_tx_offloads[portid]);
> if ((req_tx_offloads[portid] & RTE_ETH_TX_OFFLOAD_IPV4_CKSUM))
> - ipv4_cksum_port_mask = 1U << portid;
> + ipv4_cksum_port_mask |= 1U << portid;
> }
>
> for (lcore_id = 0; lcore_id < RTE_MAX_LCORE; lcore_id++) {
--
Regards,
Vladimir
^ permalink raw reply [flat|nested] 5+ messages in thread
* RE: [PATCH] examples/ipsec-secgw: fix Tx checksum offload flag
2022-06-22 9:46 ` Zhang, Roy Fan
@ 2022-06-28 8:36 ` Akhil Goyal
0 siblings, 0 replies; 5+ messages in thread
From: Akhil Goyal @ 2022-06-28 8:36 UTC (permalink / raw)
To: Zhang, Roy Fan, Nicolau, Radu, Nicolau, Radu; +Cc: dev, Nithin Kumar Dabilpuram
> > For the inline crypto path set the Tx checksum offload flag
> > only if the device supports it.
> >
> > Fixes: d24471e5786b ("examples/ipsec-secgw: disable Tx checksum for inline")
> > Cc: ndabilpuram@marvell.com
> >
> > Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
> > ---
> Acked-by: Fan Zhang <roy.fan.zhang@intel.com>
Acked-by: Akhil Goyal <gakhil@marvell.com>
Applied to dpdk-next-crypto
Thanks.
^ permalink raw reply [flat|nested] 5+ messages in thread
* RE: [PATCH] examples/ipsec-secgw: fix Tx checksum offload flag
2022-06-22 9:28 Radu Nicolau
@ 2022-06-22 9:46 ` Zhang, Roy Fan
2022-06-28 8:36 ` Akhil Goyal
0 siblings, 1 reply; 5+ messages in thread
From: Zhang, Roy Fan @ 2022-06-22 9:46 UTC (permalink / raw)
To: Nicolau, Radu, Nicolau, Radu, Akhil Goyal; +Cc: dev, ndabilpuram
> -----Original Message-----
> From: Radu Nicolau <radu.nicolau@intel.com>
> Sent: Wednesday, June 22, 2022 10:28 AM
> To: Nicolau, Radu <radu.nicolau@intel.com>; Akhil Goyal <gakhil@marvell.com>
> Cc: dev@dpdk.org; ndabilpuram@marvell.com
> Subject: [PATCH] examples/ipsec-secgw: fix Tx checksum offload flag
>
> For the inline crypto path set the Tx checksum offload flag
> only if the device supports it.
>
> Fixes: d24471e5786b ("examples/ipsec-secgw: disable Tx checksum for inline")
> Cc: ndabilpuram@marvell.com
>
> Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
> ---
Acked-by: Fan Zhang <roy.fan.zhang@intel.com>
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH] examples/ipsec-secgw: fix Tx checksum offload flag
@ 2022-06-22 9:28 Radu Nicolau
2022-06-22 9:46 ` Zhang, Roy Fan
0 siblings, 1 reply; 5+ messages in thread
From: Radu Nicolau @ 2022-06-22 9:28 UTC (permalink / raw)
To: Radu Nicolau, Akhil Goyal; +Cc: dev, ndabilpuram
For the inline crypto path set the Tx checksum offload flag
only if the device supports it.
Fixes: d24471e5786b ("examples/ipsec-secgw: disable Tx checksum for inline")
Cc: ndabilpuram@marvell.com
Signed-off-by: Radu Nicolau <radu.nicolau@intel.com>
---
examples/ipsec-secgw/sa.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/examples/ipsec-secgw/sa.c b/examples/ipsec-secgw/sa.c
index 0b27f11fc0..9b35dfdbef 100644
--- a/examples/ipsec-secgw/sa.c
+++ b/examples/ipsec-secgw/sa.c
@@ -1841,7 +1841,10 @@ sa_check_offloads(uint16_t port_id, uint64_t *rx_offloads,
if (rule->mss)
*tx_offloads |=
RTE_ETH_TX_OFFLOAD_TCP_TSO;
- *tx_offloads |= RTE_ETH_TX_OFFLOAD_IPV4_CKSUM;
+ if (dev_info.tx_offload_capa &
+ RTE_ETH_TX_OFFLOAD_IPV4_CKSUM)
+ *tx_offloads |=
+ RTE_ETH_TX_OFFLOAD_IPV4_CKSUM;
}
break;
default:
--
2.25.1
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2022-10-18 15:39 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-30 12:40 [PATCH] examples/ipsec-secgw: fix Tx checksum offload flag Radu Nicolau
2022-10-18 15:39 ` Medvedkin, Vladimir
-- strict thread matches above, loose matches on Subject: below --
2022-06-22 9:28 Radu Nicolau
2022-06-22 9:46 ` Zhang, Roy Fan
2022-06-28 8:36 ` Akhil Goyal
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).