ipsec: Add option to configure the hand-off worker queue size

Type: improvement

Change-Id: I252951d3ec01497c049ca0ffb7cb42aaf2efb965
Signed-off-by: Dau Do <daudo@yahoo.com>
diff --git a/src/vnet/ipsec/esp_decrypt.c b/src/vnet/ipsec/esp_decrypt.c
index 26d8ca1..01b2d29 100644
--- a/src/vnet/ipsec/esp_decrypt.c
+++ b/src/vnet/ipsec/esp_decrypt.c
@@ -1675,14 +1675,14 @@
 {
   ipsec_main_t *im = &ipsec_main;
 
-  im->esp4_dec_fq_index =
-    vlib_frame_queue_main_init (esp4_decrypt_node.index, 0);
-  im->esp6_dec_fq_index =
-    vlib_frame_queue_main_init (esp6_decrypt_node.index, 0);
-  im->esp4_dec_tun_fq_index =
-    vlib_frame_queue_main_init (esp4_decrypt_tun_node.index, 0);
-  im->esp6_dec_tun_fq_index =
-    vlib_frame_queue_main_init (esp6_decrypt_tun_node.index, 0);
+  im->esp4_dec_fq_index = vlib_frame_queue_main_init (esp4_decrypt_node.index,
+						      im->handoff_queue_size);
+  im->esp6_dec_fq_index = vlib_frame_queue_main_init (esp6_decrypt_node.index,
+						      im->handoff_queue_size);
+  im->esp4_dec_tun_fq_index = vlib_frame_queue_main_init (
+    esp4_decrypt_tun_node.index, im->handoff_queue_size);
+  im->esp6_dec_tun_fq_index = vlib_frame_queue_main_init (
+    esp6_decrypt_tun_node.index, im->handoff_queue_size);
 
   return 0;
 }