Prove that VLAN ID alternation is done correctlyΒΆ

Make sure that VLAN ID alternation performed by means of sending couples of mbufs with different VLAN IDs is carried out properly

The test is to verify that PMD is able to fulfill VLAN offload properly under such circumstances like sending couples of packets with different values of 'vlan_tci' field (or without such) in the corresponding mbufs

  1. Initialize ethdev and obtain the device information

  2. Check if VLAN insertion offload is supported and enable it

  3. Configure and start ethdev

  4. Obtain the source Ethernet address

  5. Adjust the traffic template

  6. Adjust so-called 'send transformations' for the 1st packet

  7. Generate mbuf(s) and the corresponding pattern for the 1st packet

  8. Adjust so-called 'send transformations' for the 2nd packet

  9. Generate mbuf(s) and the corresponding pattern for the 2nd packet

  10. Construct a burst array from the two packets

  11. Concatenate the 1st and 2nd patterns

  12. Create an RX CSAP on the TST host according to the template

  13. Start to capture traffic with the pattern prepared

  14. Ensure that interface is UP on Tester side

  15. Validate and send the burst

  16. Receive packets on peer

  17. Verify the number of matching packets received

Parameters:

template

Traffic template

payload_len

Payload length, bytes

vlan_id_first

VLAN ID (1st packet) or -1 (disable)

vlan_id_second

VLAN ID (2nd packet) or -1 (disable)