git.droids-corp.org
/
dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
bus/pci: reference driver structure before mapping
[dpdk.git]
/
examples
/
packet_ordering
/
main.c
diff --git
a/examples/packet_ordering/main.c
b/examples/packet_ordering/main.c
index
676cb6f
..
7ace7d1
100644
(file)
--- a/
examples/packet_ordering/main.c
+++ b/
examples/packet_ordering/main.c
@@
-430,7
+430,7
@@
rx_thread(struct rte_ring *ring_out)
static int
worker_thread(void *args_ptr)
{
static int
worker_thread(void *args_ptr)
{
- const uint
8_t nb_ports = rte_eth_dev_count
();
+ const uint
16_t nb_ports = rte_eth_dev_count_avail
();
uint16_t i, ret = 0;
uint16_t burst_size = 0;
struct worker_thread_args *args;
uint16_t i, ret = 0;
uint16_t burst_size = 0;
struct worker_thread_args *args;
@@
-644,7
+644,7
@@
main(int argc, char **argv)
"1 lcore for packet TX\n"
"and at least 1 lcore for worker threads\n");
"1 lcore for packet TX\n"
"and at least 1 lcore for worker threads\n");
- nb_ports = rte_eth_dev_count();
+ nb_ports = rte_eth_dev_count
_avail
();
if (nb_ports == 0)
rte_exit(EXIT_FAILURE, "Error: no ethernet ports detected\n");
if (nb_ports != 1 && (nb_ports & 1))
if (nb_ports == 0)
rte_exit(EXIT_FAILURE, "Error: no ethernet ports detected\n");
if (nb_ports != 1 && (nb_ports & 1))