fix ethdev ports enumeration
[dpdk.git] / test / test / test_pmd_ring.c
index 4b89101..0787e4e 100644 (file)
@@ -473,7 +473,7 @@ test_pmd_ring(void)
                return -1;
 
        /* find a port created with the --vdev=net_ring0 command line option */
-       for (port = 0; port < nb_ports; port++) {
+       RTE_ETH_FOREACH_DEV(port) {
                struct rte_eth_dev_info dev_info;
 
                rte_eth_dev_info_get(port, &dev_info);