Test of Tx statistics

Check the correctness of Tx statistics

  1. Initialize EAL, preparing of Rx/Tx setup done Ethernet device state

  2. Prepare mbufs to be sent and pattern to match it by tmpl

  3. Adjust MTU on both ends

  4. Identify destination address: unicast, broadcast, multicast

  5. Calculate packet length and number of bytes to transmit

  6. Although valid figures are expected to become available instantly upon the port start, in rare cases a Tx pause frame may be generated and counted once within a second thus not being considered on the step where the initial figures are collected but being spotted among the final readings; to cope with the issue, wait for a one second

  7. Get initial Tx statistics

  8. Create Ethernet-based CSAP which starts to listen to network immediately

  9. Ensure that interface is UP on Tester side

  10. Validate and send the mbufs to iut_port Make sure that all are sent

  11. Receive packet on tst_if Check that the received packets matches the sent one from iut_port

  12. Check that no extra packets are received on Tester

  13. Check that number of received packets equal to sent

  14. Wait statistics update

  15. Check that general Tx statistics are correct

  16. Get extended Tx statistics

  17. Check that extended Tx statistics are correct

Parameters:

tmpl

Traffic template

nb_pkts

The number of packets

payload_len

Payload length