* [PATCH] app/testpmd: fix GTP L2 len in checksum engine
@ 2023-04-02 12:26 Raslan Darawsheh
2023-04-25 11:59 ` Singh, Aman Deep
0 siblings, 1 reply; 3+ messages in thread
From: Raslan Darawsheh @ 2023-04-02 12:26 UTC (permalink / raw)
To: thomas; +Cc: dev, ting.xu, stable, Aman Singh, Yuying Zhang
GTP header can be followed by an optional 32 bits extension.
But, l2_len value statically set to RTE_ETHER_GTP_HLEN
which is defined to be
(sizeof(struct rte_udp_hdr) + sizeof(struct rte_gtp_hdr))
This fixes the l2_len to take into consideration the extension size.
Fixes: d8e5e69f3a9b ("app/testpmd: add GTP parsing and Tx checksum offload")
Cc: ting.xu@intel.com
Cc: stable@dpdk.org
Signed-off-by: Raslan Darawsheh <rasland@nvidia.com>
---
app/test-pmd/csumonly.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/test-pmd/csumonly.c b/app/test-pmd/csumonly.c
index fc85c22a77..b50b89367a 100644
--- a/app/test-pmd/csumonly.c
+++ b/app/test-pmd/csumonly.c
@@ -250,7 +250,7 @@ parse_gtp(struct rte_udp_hdr *udp_hdr,
info->l4_proto = 0;
}
- info->l2_len += RTE_ETHER_GTP_HLEN;
+ info->l2_len += gtp_len + sizeof(udp_hdr);
}
/* Parse a vxlan header */
--
2.25.1
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] app/testpmd: fix GTP L2 len in checksum engine
2023-04-02 12:26 [PATCH] app/testpmd: fix GTP L2 len in checksum engine Raslan Darawsheh
@ 2023-04-25 11:59 ` Singh, Aman Deep
2023-05-17 15:31 ` Ferruh Yigit
0 siblings, 1 reply; 3+ messages in thread
From: Singh, Aman Deep @ 2023-04-25 11:59 UTC (permalink / raw)
To: Raslan Darawsheh, thomas; +Cc: dev, ting.xu, stable, Yuying Zhang
On 4/2/2023 5:56 PM, Raslan Darawsheh wrote:
> GTP header can be followed by an optional 32 bits extension.
>
> But, l2_len value statically set to RTE_ETHER_GTP_HLEN
> which is defined to be
> (sizeof(struct rte_udp_hdr) + sizeof(struct rte_gtp_hdr))
>
> This fixes the l2_len to take into consideration the extension size.
>
> Fixes: d8e5e69f3a9b ("app/testpmd: add GTP parsing and Tx checksum offload")
> Cc: ting.xu@intel.com
> Cc: stable@dpdk.org
>
> Signed-off-by: Raslan Darawsheh <rasland@nvidia.com>
Acked-by: Aman Singh <aman.deep.singh@intel.com>
> ---
> app/test-pmd/csumonly.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/app/test-pmd/csumonly.c b/app/test-pmd/csumonly.c
> index fc85c22a77..b50b89367a 100644
> --- a/app/test-pmd/csumonly.c
> +++ b/app/test-pmd/csumonly.c
> @@ -250,7 +250,7 @@ parse_gtp(struct rte_udp_hdr *udp_hdr,
> info->l4_proto = 0;
> }
>
> - info->l2_len += RTE_ETHER_GTP_HLEN;
> + info->l2_len += gtp_len + sizeof(udp_hdr);
Macro is unused after above change.
So can be removed.
> }
>
> /* Parse a vxlan header */
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] app/testpmd: fix GTP L2 len in checksum engine
2023-04-25 11:59 ` Singh, Aman Deep
@ 2023-05-17 15:31 ` Ferruh Yigit
0 siblings, 0 replies; 3+ messages in thread
From: Ferruh Yigit @ 2023-05-17 15:31 UTC (permalink / raw)
To: Singh, Aman Deep, Raslan Darawsheh, thomas
Cc: dev, ting.xu, stable, Yuying Zhang
On 4/25/2023 12:59 PM, Singh, Aman Deep wrote:
>
> On 4/2/2023 5:56 PM, Raslan Darawsheh wrote:
>> GTP header can be followed by an optional 32 bits extension.
>>
>> But, l2_len value statically set to RTE_ETHER_GTP_HLEN
>> which is defined to be
>> (sizeof(struct rte_udp_hdr) + sizeof(struct rte_gtp_hdr))
>>
>> This fixes the l2_len to take into consideration the extension size.
>>
>> Fixes: d8e5e69f3a9b ("app/testpmd: add GTP parsing and Tx checksum
>> offload")
>> Cc: ting.xu@intel.com
>> Cc: stable@dpdk.org
>>
>> Signed-off-by: Raslan Darawsheh <rasland@nvidia.com>
>
> Acked-by: Aman Singh <aman.deep.singh@intel.com>>
Applied to dpdk-next-net/main, thanks.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-05-17 15:31 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-04-02 12:26 [PATCH] app/testpmd: fix GTP L2 len in checksum engine Raslan Darawsheh
2023-04-25 11:59 ` Singh, Aman Deep
2023-05-17 15:31 ` Ferruh Yigit
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).