X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=examples%2Fvmdq%2Fmain.c;h=178af2f5b9d98aa06a3814cc9feafec5e2b73c42;hb=a90ca1a12eb560f0ca8e76a6b116cd1fc9ac0439;hp=7596bac3ceabac1aa0a246e0d70290b1cd5e658f;hpb=ea0c20ea95fd5d71a10757e6598ac66233ea1495;p=dpdk.git diff --git a/examples/vmdq/main.c b/examples/vmdq/main.c index 7596bac3ce..178af2f5b9 100644 --- a/examples/vmdq/main.c +++ b/examples/vmdq/main.c @@ -69,14 +69,14 @@ #include #include -#define MAX_QUEUES 128 +#define MAX_QUEUES 1024 /* - * For 10 GbE, 128 queues require roughly - * 128*512 (RX/TX_queue_nb * RX/TX_ring_descriptors_nb) per port. + * 1024 queues require to meet the needs of a large number of vmdq_pools. + * (RX/TX_queue_nb * RX/TX_ring_descriptors_nb) per port. */ -#define NUM_MBUFS_PER_PORT (128*512) +#define NUM_MBUFS_PER_PORT (MAX_QUEUES * RTE_MAX(RTE_TEST_RX_DESC_DEFAULT, \ + RTE_TEST_TX_DESC_DEFAULT)) #define MBUF_CACHE_SIZE 64 -#define MBUF_DATA_SIZE (2048 + RTE_PKTMBUF_HEADROOM) #define MAX_PKT_BURST 32 @@ -615,7 +615,7 @@ main(int argc, char *argv[]) mbuf_pool = rte_pktmbuf_pool_create("MBUF_POOL", NUM_MBUFS_PER_PORT * nb_ports, MBUF_CACHE_SIZE, - 0, MBUF_DATA_SIZE, rte_socket_id()); + 0, RTE_MBUF_DEFAULT_BUF_SIZE, rte_socket_id()); if (mbuf_pool == NULL) rte_exit(EXIT_FAILURE, "Cannot create mbuf pool\n");