static __rte_always_inline int
pipeline_queue_nb_event_queues(struct evt_options *opt)
{
- uint16_t eth_count = rte_eth_dev_count();
+ uint16_t eth_count = rte_eth_dev_count_avail();
return (eth_count * opt->nb_stages) + eth_count;
}
uint8_t nb_worker_queues = 0;
nb_ports = evt_nr_active_lcores(opt->wlcores);
- nb_queues = rte_eth_dev_count() * (nb_stages);
+ nb_queues = rte_eth_dev_count_avail() * (nb_stages);
/* Extra port for Tx service. */
if (t->mt_unsafe) {
nb_ports++;
nb_queues++;
} else
- nb_queues += rte_eth_dev_count();
+ nb_queues += rte_eth_dev_count_avail();
rte_event_dev_info_get(opt->dev_id, &info);
}
}
+ if (opt->wkr_deq_dep > info.max_event_port_dequeue_depth)
+ opt->wkr_deq_dep = info.max_event_port_dequeue_depth;
+
/* port configuration */
const struct rte_event_port_conf p_conf = {
.dequeue_depth = opt->wkr_deq_dep,