X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=examples%2Fip_pipeline%2Finit.c;h=96aee2b70a1fa99016d80615aa6722a22081f47d;hb=263333bbb7a9b3356ac2d996b2a7bfd6941d0022;hp=947e152a1b8a89a70093fc4d5d2937316a13cbce;hpb=77a334675f29b36fa653ad79f126fdcb6c20762d;p=dpdk.git diff --git a/examples/ip_pipeline/init.c b/examples/ip_pipeline/init.c index 947e152a1b..96aee2b70a 100644 --- a/examples/ip_pipeline/init.c +++ b/examples/ip_pipeline/init.c @@ -48,7 +48,6 @@ #include #include #include -#include #include #include #include @@ -113,7 +112,7 @@ struct app_params app = { .rx_adv_conf = { .rss_conf = { .rss_key = NULL, - .rss_hf = ETH_RSS_IPV4 | ETH_RSS_IPV6, + .rss_hf = ETH_RSS_IP, }, }, .txmode = { @@ -419,7 +418,7 @@ app_init_rings(void) RTE_LOG(INFO, USER1, "Initializing %u SW rings ...\n", n_swq); app.rings = rte_malloc_socket(NULL, n_swq * sizeof(struct rte_ring *), - CACHE_LINE_SIZE, rte_socket_id()); + RTE_CACHE_LINE_SIZE, rte_socket_id()); if (app.rings == NULL) rte_panic("Cannot allocate memory to store ring pointers\n"); @@ -427,7 +426,7 @@ app_init_rings(void) struct rte_ring *ring; char name[32]; - rte_snprintf(name, sizeof(name), "app_ring_%u", i); + snprintf(name, sizeof(name), "app_ring_%u", i); ring = rte_ring_create( name, @@ -474,11 +473,6 @@ app_init_ports(void) { uint32_t i; - /* Init driver */ - RTE_LOG(INFO, USER1, "Initializing the PMD driver ...\n"); - if (rte_eal_pci_probe() < 0) - rte_panic("Cannot probe PCI\n"); - /* Init NIC ports, then start the ports */ for (i = 0; i < app.n_ports; i++) { uint32_t port; @@ -561,7 +555,7 @@ app_ping(void) rte_panic("Unable to allocate new message\n"); req = (struct app_msg_req *) - ((struct rte_mbuf *)msg)->ctrl.data; + rte_ctrlmbuf_data((struct rte_mbuf *)msg); req->type = APP_MSG_REQ_PING; /* Send request */ @@ -600,7 +594,7 @@ app_init_etc(void) void app_init(void) { - if ((sizeof(struct app_pkt_metadata) % CACHE_LINE_SIZE) != 0) + if ((sizeof(struct app_pkt_metadata) % RTE_CACHE_LINE_SIZE) != 0) rte_panic("Application pkt meta-data size mismatch\n"); app_check_core_params();