Bug 361 - vAPV ping delay issue on AVX

Review Request #73 — Created Oct. 31, 2023 and updated

timlai
APV10
rel_apv_10_7
361
jasonchou, peteryeh, wli

Patch fix from https://github.com/DPDK/dpdk/commit/a08f9cb698c3d4687765860e328dca727f7a516b

For Rx-Queue Interrupt Setting, when VF Rx interrupt
disable (INTENA=0), there are two ways to write back
descriptor to host memory:

1) Set WB_ON_ITR bit 0 to Interrupt Dynamic Control Register:
Completed descriptors are posted to host memory according to
the internal descriptor cache policy (in other words when a
full cache line is available for write-back).

A internal descriptor size is 16 bytes or 32 bytes, a cache
line size is 64 bytes or 128 bytes from datasheet :
PCIe Global Config 2 - GLPCI_CNF2 (0x000BE004; RO)
so the full cache line could contains 4 packets, it means
Network card will send 4 packets to host when a full cache line
is available.

2) Set WB_ON_ITR bit 1 to Interrupt Dynamic Control Register:
Completed descriptors also trigger the ITR. Following ITR
expiration, all leftover completed descriptors are posted to
host memory.

Network card will send packet to host even if only one
descriptor is completed.

Changing 1) to 2) to make sure VF send the packet to host even
if there is only one Rx packet is ready in hardware.

AN(config)#system tune rxmode interrupt

AN(config)#ping 192.168.1.104
PING 192.168.1.104 (192.168.1.104) 56(84) bytes of data.
64 bytes from 192.168.1.104: icmp_seq=1 ttl=64 time=2.30 ms
64 bytes from 192.168.1.104: icmp_seq=2 ttl=64 time=1.51 ms
64 bytes from 192.168.1.104: icmp_seq=3 ttl=64 time=2.11 ms
64 bytes from 192.168.1.104: icmp_seq=4 ttl=64 time=1.48 ms
64 bytes from 192.168.1.104: icmp_seq=5 ttl=64 time=1.98 ms

--- 192.168.1.104 ping statistics ---
5 packets transmitted, 5 received, 0% packet loss, time 4004ms
rtt min/avg/max/mdev = 1.484/1.880/2.301/0.327 ms

AN(config)#system tune rxmode poll 100

AN#ping 192.168.1.104
PING 192.168.1.104 (192.168.1.104) 56(84) bytes of data.
64 bytes from 192.168.1.104: icmp_seq=1 ttl=64 time=0.784 ms
64 bytes from 192.168.1.104: icmp_seq=2 ttl=64 time=0.892 ms
64 bytes from 192.168.1.104: icmp_seq=3 ttl=64 time=0.822 ms
64 bytes from 192.168.1.104: icmp_seq=4 ttl=64 time=0.717 ms
64 bytes from 192.168.1.104: icmp_seq=5 ttl=64 time=0.711 ms

--- 192.168.1.104 ping statistics ---
5 packets transmitted, 5 received, 0% packet loss, time 4000ms
rtt min/avg/max/mdev = 0.711/0.785/0.892/0.069 ms

Loading...