diff options
Diffstat (limited to 'example')
-rw-r--r-- | example/classifier/odp_classifier.c | 5 | ||||
-rw-r--r-- | example/generator/odp_generator.c | 4 | ||||
-rw-r--r-- | example/ipsec/odp_ipsec.c | 6 | ||||
-rw-r--r-- | example/packet/odp_pktio.c | 4 |
4 files changed, 19 insertions, 0 deletions
diff --git a/example/classifier/odp_classifier.c b/example/classifier/odp_classifier.c index ac204afb..685f335f 100644 --- a/example/classifier/odp_classifier.c +++ b/example/classifier/odp_classifier.c @@ -463,6 +463,11 @@ int main(int argc, char *argv[]) /* configure default Cos and default queue */ configure_default_queue(pktio, args); + if (odp_pktio_start(pktio)) { + EXAMPLE_ERR("Error: unable to start pktio.\n"); + exit(EXIT_FAILURE); + } + /* Create and init worker threads */ memset(thread_tbl, 0, sizeof(thread_tbl)); diff --git a/example/generator/odp_generator.c b/example/generator/odp_generator.c index 5c2eb061..f7aed760 100644 --- a/example/generator/odp_generator.c +++ b/example/generator/odp_generator.c @@ -359,6 +359,10 @@ static odp_pktio_t create_pktio(const char *dev, odp_pool_t pool) if (ret != 0) EXAMPLE_ABORT("Error: default input-Q setup for %s\n", dev); + ret = odp_pktio_start(pktio); + if (ret) + EXAMPLE_ABORT("Error: unable to start %s\n", dev); + printf(" created pktio:%02" PRIu64 ", dev:%s, queue mode (ATOMIC queues)\n" " default pktio%02" PRIu64 diff --git a/example/ipsec/odp_ipsec.c b/example/ipsec/odp_ipsec.c index 85dbc002..96effe28 100644 --- a/example/ipsec/odp_ipsec.c +++ b/example/ipsec/odp_ipsec.c @@ -556,6 +556,12 @@ void initialize_intf(char *intf) exit(EXIT_FAILURE); } + ret = odp_pktio_start(pktio); + if (ret) { + EXAMPLE_ERR("Error: unable to start %s\n", intf); + exit(EXIT_FAILURE); + } + /* Read the source MAC address for this interface */ ret = odp_pktio_mac_addr(pktio, src_mac, sizeof(src_mac)); if (ret <= 0) { diff --git a/example/packet/odp_pktio.c b/example/packet/odp_pktio.c index 835fb961..df53ea2d 100644 --- a/example/packet/odp_pktio.c +++ b/example/packet/odp_pktio.c @@ -171,6 +171,10 @@ static odp_pktio_t create_pktio(const char *dev, odp_pool_t pool, int mode) if (ret != 0) EXAMPLE_ABORT("Error: default input-Q setup for %s\n", dev); + ret = odp_pktio_start(pktio); + if (ret != 0) + EXAMPLE_ABORT("Error: unable to start %s\n", dev); + printf(" created pktio:%02" PRIu64 ", dev:%s, queue mode (ATOMIC queues)\n" " \tdefault pktio%02" PRIu64 "-INPUT queue:%" PRIu64 "\n", |