session: use vpp to switch io events for ct sessions
[vpp.git] / src / vnet / session / application_worker.c
index 662c65b..7c88888 100644 (file)
@@ -165,7 +165,6 @@ app_worker_alloc_session_fifos (segment_manager_t * sm, session_t * s)
 
   s->rx_fifo = rx_fifo;
   s->tx_fifo = tx_fifo;
-  s->svm_segment_index = fifo_segment_index;
   return 0;
 }
 
@@ -362,7 +361,7 @@ app_worker_own_session (app_worker_t * app_wrk, session_t * s)
       s->tx_fifo->cursize = txf->cursize;
     }
 
-  segment_manager_dealloc_fifos (rxf->segment_index, rxf, txf);
+  segment_manager_dealloc_fifos (rxf, txf);
 
   return 0;
 }
@@ -544,7 +543,7 @@ app_send_io_evt_rx (app_worker_t * app_wrk, session_t * s, u8 lock)
       return app->cb_fns.builtin_app_rx_callback (s);
     }
 
-  if (svm_fifo_has_event (s->rx_fifo) || svm_fifo_is_empty (s->rx_fifo))
+  if (svm_fifo_has_event (s->rx_fifo))
     return 0;
 
   mq = app_wrk->event_queue;
@@ -609,9 +608,8 @@ app_send_io_evt_tx (app_worker_t * app_wrk, session_t * s, u8 lock)
 typedef int (app_send_evt_handler_fn) (app_worker_t *app,
                                       session_t *s,
                                       u8 lock);
-static app_send_evt_handler_fn * const app_send_evt_handler_fns[3] = {
+static app_send_evt_handler_fn * const app_send_evt_handler_fns[2] = {
     app_send_io_evt_rx,
-    0,
     app_send_io_evt_tx,
 };
 /* *INDENT-ON* */