Separates loop list process size from the endpoint DPDK queue size.
Corrected DPDK queue size to be a power of 2 which allows dpdkr interface to be 
created.
Increased queue size to improve zero loss data rate.
Changed NIC queue size comment to make NIC queue size formula more clear.

Signed-off-by: Mike A. Polehn <mike.a.pol...@intel.com>

diff --git a/lib/netdev-dpdk.c b/lib/netdev-dpdk.c
old mode 100644
new mode 100755
index 6ee9803..3a19db0
--- a/lib/netdev-dpdk.c
+++ b/lib/netdev-dpdk.c
@@ -71,8 +71,11 @@ static struct vlog_rate_limit rl = VLOG_RATE_LIMIT_INIT(5, 
20);
 
 #define NON_PMD_THREAD_TX_QUEUE 0
 
-#define NIC_PORT_RX_Q_SIZE 2048  /* Size of Physical NIC RX Queue, Max 
(n+32<=4096)*/
-#define NIC_PORT_TX_Q_SIZE 2048  /* Size of Physical NIC TX Queue, Max 
(n+32<=4096)*/
+#define NIC_PORT_RX_Q_SIZE 2048  /* Size of Physical NIC RX Queue, Size: 
(x*32<=4064)*/
+#define NIC_PORT_TX_Q_SIZE 2048  /* Size of Physical NIC TX Queue, Size: 
(x*32<=4064)*/
+
+#define DPDK_RX_Q_SIZE     2048  /* Size of DPDK RX Client Queue, Size: 
(x**2)*/
+#define DPDK_TX_Q_SIZE     2048  /* Size of DPDK TX Client Queue, Size: 
(x**2)*/
 
 /* XXX: Needs per NIC value for these constants. */
 #define RX_PTHRESH 32 /* Default values of RX prefetch threshold reg. */
@@ -1236,7 +1239,7 @@ dpdk_ring_create(const char dev_name[], unsigned int 
port_no,
         return -err;
     }
 
-    ivshmem->cring_tx = rte_ring_create(ring_name, MAX_RX_QUEUE_LEN, SOCKET0, 
0);
+    ivshmem->cring_tx = rte_ring_create(ring_name, DPDK_TX_Q_SIZE, SOCKET0, 0);
     if (ivshmem->cring_tx == NULL) {
         rte_free(ivshmem);
         return ENOMEM;
@@ -1247,7 +1250,7 @@ dpdk_ring_create(const char dev_name[], unsigned int 
port_no,
         return -err;
     }
 
-    ivshmem->cring_rx = rte_ring_create(ring_name, MAX_RX_QUEUE_LEN, SOCKET0, 
0);
+    ivshmem->cring_rx = rte_ring_create(ring_name, DPDK_RX_Q_SIZE, SOCKET0, 0);
     if (ivshmem->cring_rx == NULL) {
         rte_free(ivshmem);
         return ENOMEM;
_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev

Reply via email to