Simulate HW offload
Make sure that offloading traffic to a virtual function works with RTE flow API
Hotplug the representor of the VF
Bind kernel or DPDK driver on a VF
If
use_dpdk_driver:Hotplug VF
If not
use_dpdk_driver:Add VF's kernel interface and bring it up
Create a big enough mempool for PF, VF and representor ports
Make flow rule pattern and template
Start PF, VF and representor ports
Check full traffic path (IUT - representor - TST) without flow rule
Make flow rule attributes with transfer and ingress or egress depending on traffic direction
Direct traffic to the VF (when receiving on IUT) or to the physical port (when receiving on TST)
If
count:Add flow rule action "count" for counter query
Validate and create the flow rule
For each iteration (
i = 0; i < nb_pkts; i++):Check the traffic from VF to TST
Only on the error path:
Check the traffic at least reached PF or representor
Destroy the flow rule and check the full traffic path again
Igor Romanov Igor.Romanov@oktetlabs.ru
Parameters:
flow_rule_pattern |
Flow Rule pattern |
use_dpdk_driver |
Use DPDK driver on VF if |
count |
Count offloaded packets if |
iut_client |
|
nb_pkts |
Number of offloaded packets to send |