All of lore.kernel.org
 help / color / mirror / Atom feed
* Google Virtual NIC (GVE) PMD
@ 2023-01-18 13:47 Levend Sayar
  2023-01-18 15:31 ` Ferruh Yigit
  0 siblings, 1 reply; 4+ messages in thread
From: Levend Sayar @ 2023-01-18 13:47 UTC (permalink / raw)
  To: dev

[-- Attachment #1: Type: text/plain, Size: 377 bytes --]

Hi all.

PMD for Google Virtual NIC says it is capable of IPV4 TX checksum
offloading.

https://github.com/DPDK/dpdk/blob/main/drivers/net/gve/gve_ethdev.c#L285

But according to my tests on Google Cloud, it is not doing that ipv4
checksum tx offload.
I only managed to send a packet via DPDK if I calculate the checksum myself.

Do you have any idea about that?

Best,
Levend

[-- Attachment #2: Type: text/html, Size: 589 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Google Virtual NIC (GVE) PMD
  2023-01-18 13:47 Google Virtual NIC (GVE) PMD Levend Sayar
@ 2023-01-18 15:31 ` Ferruh Yigit
  2023-01-31  6:52   ` Guo, Junfeng
  0 siblings, 1 reply; 4+ messages in thread
From: Ferruh Yigit @ 2023-01-18 15:31 UTC (permalink / raw)
  To: Levend Sayar, Junfeng Guo
  Cc: dev, Jeroen de Borst, Rushil Gupta, Jordan Kimbrough

On 1/18/2023 1:47 PM, Levend Sayar wrote:
> Hi all.
> 
> PMD for Google Virtual NIC says it is capable of IPV4 TX checksum
> offloading.
> 
> https://github.com/DPDK/dpdk/blob/main/drivers/net/gve/gve_ethdev.c#L285
> <https://github.com/DPDK/dpdk/blob/main/drivers/net/gve/gve_ethdev.c#L285>
> 
> But according to my tests on Google Cloud, it is not doing that ipv4
> checksum tx offload.
> I only managed to send a packet via DPDK if I calculate the checksum myself.
> 
> Do you have any idea about that? 
> 

cc'ed gve maintainers.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* RE: Google Virtual NIC (GVE) PMD
  2023-01-18 15:31 ` Ferruh Yigit
@ 2023-01-31  6:52   ` Guo, Junfeng
  2023-01-31  8:17     ` Levend Sayar
  0 siblings, 1 reply; 4+ messages in thread
From: Guo, Junfeng @ 2023-01-31  6:52 UTC (permalink / raw)
  To: Ferruh Yigit, Levend Sayar
  Cc: dev, Jeroen de Borst, Rushil Gupta, Jordan Kimbrough



> -----Original Message-----
> From: Ferruh Yigit <ferruh.yigit@amd.com>
> Sent: Wednesday, January 18, 2023 23:32
> To: Levend Sayar <levendsayar@gmail.com>; Guo, Junfeng
> <junfeng.guo@intel.com>
> Cc: dev@dpdk.org; Jeroen de Borst <jeroendb@google.com>; Rushil
> Gupta <rushilg@google.com>; Jordan Kimbrough <jrkim@google.com>
> Subject: Re: Google Virtual NIC (GVE) PMD
> 
> On 1/18/2023 1:47 PM, Levend Sayar wrote:
> > Hi all.
> >
> > PMD for Google Virtual NIC says it is capable of IPV4 TX checksum
> > offloading.
> >
> >
> https://github.com/DPDK/dpdk/blob/main/drivers/net/gve/gve_ethdev.c
> #L285
> >
> <https://github.com/DPDK/dpdk/blob/main/drivers/net/gve/gve_ethdev.
> c#L285>
> >
> > But according to my tests on Google Cloud, it is not doing that ipv4
> > checksum tx offload.
> > I only managed to send a packet via DPDK if I calculate the checksum
> myself.
> >
> > Do you have any idea about that?

Thanks for the feedback!

I tried to use this loopback typo in csum fwd mode based on this doc:
"https://doc.dpdk.org/dts/test_plans/checksum_offload_test_plan.html"
During the dpdk ports forwarding, the received pkts at tester side can have
correct csum after setting with 'csum set ip hw 0'.

Also, on GCP, the gateway between VMs will correct the wrong L3 chksum
values by default when passing the pkts.

Could you please provide more details for your test cases? 
So that we can have more information to verify this. Thanks!


> >
> 
> cc'ed gve maintainers.

Thanks Ferruh for the forwarding!


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Google Virtual NIC (GVE) PMD
  2023-01-31  6:52   ` Guo, Junfeng
@ 2023-01-31  8:17     ` Levend Sayar
  0 siblings, 0 replies; 4+ messages in thread
From: Levend Sayar @ 2023-01-31  8:17 UTC (permalink / raw)
  To: Guo, Junfeng
  Cc: Ferruh Yigit, dev, Jeroen de Borst, Rushil Gupta, Jordan Kimbrough

Thanks for the reply Junfeng.

I will check the document you mentioned.
I don't know the command 'cksum set ip hw 0', but it looks like to me as "hardware will NOT do checksum'.

There is a gateway between VMs at GCP as you mentioned. My test application generates UDP packets.
I am checking the offloading capacity of the NIC and behaving accordingly. Since GVE says IP checksum capability, I am offloading that.
My packets have 0 as an IP checksum. In this case, I can not see any packet at the destination with tcpdump.
Since I do not have a chance to see what is happening at the gateway, I only check packet transmission at the destination VM.

If I calculate IP checksums by myself, I see the packets at the destination. So according to my observations, the gateway does not do such an IP checksum correction.

My second observation is GVE does UDP checksum if you offload. Normally I am not using a checksum at UDP and use zero as the checksum.

Best,
Levend





Telefonumdan gönderildi

> Guo, Junfeng <junfeng.guo@intel.com> şunları yazdı (31 Oca 2023 09:52):
> 
> 
> 
>> -----Original Message-----
>> From: Ferruh Yigit <ferruh.yigit@amd.com>
>> Sent: Wednesday, January 18, 2023 23:32
>> To: Levend Sayar <levendsayar@gmail.com>; Guo, Junfeng
>> <junfeng.guo@intel.com>
>> Cc: dev@dpdk.org; Jeroen de Borst <jeroendb@google.com>; Rushil
>> Gupta <rushilg@google.com>; Jordan Kimbrough <jrkim@google.com>
>> Subject: Re: Google Virtual NIC (GVE) PMD
>> 
>>> On 1/18/2023 1:47 PM, Levend Sayar wrote:
>>> Hi all.
>>> 
>>> PMD for Google Virtual NIC says it is capable of IPV4 TX checksum
>>> offloading.
>>> 
>>> 
>> https://github.com/DPDK/dpdk/blob/main/drivers/net/gve/gve_ethdev.c
>> #L285
>>> 
>> <https://github.com/DPDK/dpdk/blob/main/drivers/net/gve/gve_ethdev.
>> c#L285>
>>> 
>>> But according to my tests on Google Cloud, it is not doing that ipv4
>>> checksum tx offload.
>>> I only managed to send a packet via DPDK if I calculate the checksum
>> myself.
>>> 
>>> Do you have any idea about that?
> 
> Thanks for the feedback!
> 
> I tried to use this loopback typo in csum fwd mode based on this doc:
> "https://doc.dpdk.org/dts/test_plans/checksum_offload_test_plan.html"
> During the dpdk ports forwarding, the received pkts at tester side can have
> correct csum after setting with 'csum set ip hw 0'.
> 
> Also, on GCP, the gateway between VMs will correct the wrong L3 chksum
> values by default when passing the pkts.
> 
> Could you please provide more details for your test cases? 
> So that we can have more information to verify this. Thanks!
> 
> 
>>> 
>> 
>> cc'ed gve maintainers.
> 
> Thanks Ferruh for the forwarding!
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-01-31  8:18 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-18 13:47 Google Virtual NIC (GVE) PMD Levend Sayar
2023-01-18 15:31 ` Ferruh Yigit
2023-01-31  6:52   ` Guo, Junfeng
2023-01-31  8:17     ` Levend Sayar

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.