blob: 210754fa72383f1cd17b71838ee5e28907a0e077 [file] [log] [blame]
Dave Barach68b0fb02017-02-28 15:15:56 -05001/*
2 * Copyright (c) 2017 Cisco and/or its affiliates.
3 * Licensed under the Apache License, Version 2.0 (the "License");
4 * you may not use this file except in compliance with the License.
5 * You may obtain a copy of the License at:
6 *
7 * http://www.apache.org/licenses/LICENSE-2.0
8 *
9 * Unless required by applicable law or agreed to in writing, software
10 * distributed under the License is distributed on an "AS IS" BASIS,
11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 * See the License for the specific language governing permissions and
13 * limitations under the License.
14 */
15
Florin Coras6792ec02017-03-13 03:49:51 -070016#include <math.h>
Dave Barach68b0fb02017-02-28 15:15:56 -050017#include <vlib/vlib.h>
18#include <vnet/vnet.h>
Dave Barach68b0fb02017-02-28 15:15:56 -050019#include <vnet/tcp/tcp.h>
Dave Barach68b0fb02017-02-28 15:15:56 -050020#include <vppinfra/elog.h>
Florin Coras6792ec02017-03-13 03:49:51 -070021#include <vnet/session/application.h>
Florin Corase69f4952017-03-07 10:06:24 -080022#include <vnet/session/session_debug.h>
Florin Coras6792ec02017-03-13 03:49:51 -070023#include <vlibmemory/unix_shared_memory_queue.h>
Dave Barach68b0fb02017-02-28 15:15:56 -050024
25vlib_node_registration_t session_queue_node;
26
27typedef struct
28{
29 u32 session_index;
30 u32 server_thread_index;
31} session_queue_trace_t;
32
33/* packet trace format function */
34static u8 *
35format_session_queue_trace (u8 * s, va_list * args)
36{
37 CLIB_UNUSED (vlib_main_t * vm) = va_arg (*args, vlib_main_t *);
38 CLIB_UNUSED (vlib_node_t * node) = va_arg (*args, vlib_node_t *);
39 session_queue_trace_t *t = va_arg (*args, session_queue_trace_t *);
40
41 s = format (s, "SESSION_QUEUE: session index %d, server thread index %d",
42 t->session_index, t->server_thread_index);
43 return s;
44}
45
46vlib_node_registration_t session_queue_node;
47
Florin Coras6792ec02017-03-13 03:49:51 -070048#define foreach_session_queue_error \
49_(TX, "Packets transmitted") \
Dave Barach68b0fb02017-02-28 15:15:56 -050050_(TIMER, "Timer events")
51
52typedef enum
53{
54#define _(sym,str) SESSION_QUEUE_ERROR_##sym,
55 foreach_session_queue_error
56#undef _
57 SESSION_QUEUE_N_ERROR,
58} session_queue_error_t;
59
60static char *session_queue_error_strings[] = {
61#define _(sym,string) string,
62 foreach_session_queue_error
63#undef _
64};
65
66static u32 session_type_to_next[] = {
67 SESSION_QUEUE_NEXT_TCP_IP4_OUTPUT,
68 SESSION_QUEUE_NEXT_IP4_LOOKUP,
69 SESSION_QUEUE_NEXT_TCP_IP6_OUTPUT,
70 SESSION_QUEUE_NEXT_IP6_LOOKUP,
71};
72
73always_inline int
Florin Corasd79b41e2017-03-04 05:37:52 -080074session_tx_fifo_read_and_snd_i (vlib_main_t * vm, vlib_node_runtime_t * node,
75 session_manager_main_t * smm,
76 session_fifo_event_t * e0,
77 stream_session_t * s0, u32 thread_index,
78 int *n_tx_packets, u8 peek_data)
Dave Barach68b0fb02017-02-28 15:15:56 -050079{
80 u32 n_trace = vlib_get_trace_count (vm, node);
81 u32 left_to_snd0, max_len_to_snd0, len_to_deq0, n_bufs, snd_space0;
82 u32 n_frame_bytes, n_frames_per_evt;
83 transport_connection_t *tc0;
84 transport_proto_vft_t *transport_vft;
85 u32 next_index, next0, *to_next, n_left_to_next, bi0;
86 vlib_buffer_t *b0;
Florin Coras6792ec02017-03-13 03:49:51 -070087 u32 rx_offset = 0, max_dequeue0;
Dave Barach68b0fb02017-02-28 15:15:56 -050088 u16 snd_mss0;
89 u8 *data0;
Florin Coras6792ec02017-03-13 03:49:51 -070090 int i, n_bytes_read;
Dave Barach68b0fb02017-02-28 15:15:56 -050091
92 next_index = next0 = session_type_to_next[s0->session_type];
93
94 transport_vft = session_get_transport_vft (s0->session_type);
95 tc0 = transport_vft->get_connection (s0->connection_index, thread_index);
96
97 /* Make sure we have space to send and there's something to dequeue */
98 snd_space0 = transport_vft->send_space (tc0);
99 snd_mss0 = transport_vft->send_mss (tc0);
100
Florin Corase04c2992017-03-01 08:17:34 -0800101 /* Can't make any progress */
Florin Coras6792ec02017-03-13 03:49:51 -0700102 if (snd_space0 == 0 || snd_mss0 == 0)
Florin Corase04c2992017-03-01 08:17:34 -0800103 {
104 vec_add1 (smm->evts_partially_read[thread_index], *e0);
105 return 0;
106 }
Dave Barach68b0fb02017-02-28 15:15:56 -0500107
Dave Barach68b0fb02017-02-28 15:15:56 -0500108 if (peek_data)
109 {
110 /* Offset in rx fifo from where to peek data */
Florin Corasd79b41e2017-03-04 05:37:52 -0800111 rx_offset = transport_vft->tx_fifo_offset (tc0);
Dave Barach68b0fb02017-02-28 15:15:56 -0500112 }
113
Florin Coras6792ec02017-03-13 03:49:51 -0700114 /* Check how much we can pull. If buffering, subtract the offset */
115 max_dequeue0 = svm_fifo_max_dequeue (s0->server_tx_fifo) - rx_offset;
116
117 /* Allow enqueuing of a new event */
118 svm_fifo_unset_event (s0->server_tx_fifo);
119
120 /* Nothing to read return */
121 if (max_dequeue0 == 0)
Florin Coras3e350af2017-03-30 02:54:28 -0700122 return 0;
Florin Coras6792ec02017-03-13 03:49:51 -0700123
124 /* Ensure we're not writing more than transport window allows */
Florin Coras3e350af2017-03-30 02:54:28 -0700125 if (max_dequeue0 < snd_space0)
126 {
127 /* Constrained by tx queue. Try to send only fully formed segments */
128 max_len_to_snd0 = (max_dequeue0 > snd_mss0) ?
129 max_dequeue0 - max_dequeue0 % snd_mss0 : max_dequeue0;
130 /* TODO Nagle ? */
131 }
132 else
133 {
134 max_len_to_snd0 = snd_space0;
135 }
Dave Barach68b0fb02017-02-28 15:15:56 -0500136
137 n_frame_bytes = snd_mss0 * VLIB_FRAME_SIZE;
138 n_frames_per_evt = ceil ((double) max_len_to_snd0 / n_frame_bytes);
139
140 n_bufs = vec_len (smm->tx_buffers[thread_index]);
141 left_to_snd0 = max_len_to_snd0;
142 for (i = 0; i < n_frames_per_evt; i++)
143 {
144 /* Make sure we have at least one full frame of buffers ready */
145 if (PREDICT_FALSE (n_bufs < VLIB_FRAME_SIZE))
146 {
147 vec_validate (smm->tx_buffers[thread_index],
148 n_bufs + VLIB_FRAME_SIZE - 1);
149 n_bufs +=
150 vlib_buffer_alloc (vm, &smm->tx_buffers[thread_index][n_bufs],
151 VLIB_FRAME_SIZE);
152
153 /* buffer shortage
154 * XXX 0.9 because when debugging we might not get a full frame */
155 if (PREDICT_FALSE (n_bufs < 0.9 * VLIB_FRAME_SIZE))
156 {
Florin Coras6792ec02017-03-13 03:49:51 -0700157 if (svm_fifo_set_event (s0->server_tx_fifo))
Florin Corase04c2992017-03-01 08:17:34 -0800158 {
Florin Corase04c2992017-03-01 08:17:34 -0800159 vec_add1 (smm->evts_partially_read[thread_index], *e0);
160 }
Dave Barach68b0fb02017-02-28 15:15:56 -0500161 return -1;
162 }
163
164 _vec_len (smm->tx_buffers[thread_index]) = n_bufs;
165 }
166
167 vlib_get_next_frame (vm, node, next_index, to_next, n_left_to_next);
168 while (left_to_snd0 && n_left_to_next)
169 {
170 /* Get free buffer */
171 n_bufs--;
172 bi0 = smm->tx_buffers[thread_index][n_bufs];
173 _vec_len (smm->tx_buffers[thread_index]) = n_bufs;
174
175 b0 = vlib_get_buffer (vm, bi0);
176 b0->error = 0;
177 b0->flags = VLIB_BUFFER_TOTAL_LENGTH_VALID
178 | VNET_BUFFER_LOCALLY_ORIGINATED;
179 b0->current_data = 0;
180
181 /* RX on the local interface. tx in default fib */
182 vnet_buffer (b0)->sw_if_index[VLIB_RX] = 0;
183 vnet_buffer (b0)->sw_if_index[VLIB_TX] = (u32) ~ 0;
184
185 /* usual speculation, or the enqueue_x1 macro will barf */
186 to_next[0] = bi0;
187 to_next += 1;
188 n_left_to_next -= 1;
189
190 VLIB_BUFFER_TRACE_TRAJECTORY_INIT (b0);
191 if (PREDICT_FALSE (n_trace > 0))
192 {
193 session_queue_trace_t *t0;
194 vlib_trace_buffer (vm, node, next_index, b0,
195 1 /* follow_chain */ );
196 vlib_set_trace_count (vm, node, --n_trace);
197 t0 = vlib_add_trace (vm, node, b0, sizeof (*t0));
198 t0->session_index = s0->session_index;
199 t0->server_thread_index = s0->thread_index;
200 }
201
Florin Corasd79b41e2017-03-04 05:37:52 -0800202 len_to_deq0 = (left_to_snd0 < snd_mss0) ? left_to_snd0 : snd_mss0;
203
Florin Corase04c2992017-03-01 08:17:34 -0800204 /* *INDENT-OFF* */
Florin Coras6792ec02017-03-13 03:49:51 -0700205 SESSION_EVT_DBG(SESSION_EVT_DEQ, s0, ({
Dave Barach68b0fb02017-02-28 15:15:56 -0500206 ed->data[0] = e0->event_id;
Florin Coras6792ec02017-03-13 03:49:51 -0700207 ed->data[1] = max_dequeue0;
Florin Corasd79b41e2017-03-04 05:37:52 -0800208 ed->data[2] = len_to_deq0;
209 ed->data[3] = left_to_snd0;
Florin Corase69f4952017-03-07 10:06:24 -0800210 }));
Florin Corase04c2992017-03-01 08:17:34 -0800211 /* *INDENT-ON* */
Dave Barach68b0fb02017-02-28 15:15:56 -0500212
Dave Barach68b0fb02017-02-28 15:15:56 -0500213 /* Make room for headers */
214 data0 = vlib_buffer_make_headroom (b0, MAX_HDRS_LEN);
215
216 /* Dequeue the data
217 * TODO 1) peek instead of dequeue
218 * 2) buffer chains */
219 if (peek_data)
220 {
Florin Corasa5464812017-04-19 13:00:05 -0700221 n_bytes_read = svm_fifo_peek (s0->server_tx_fifo, rx_offset,
222 len_to_deq0, data0);
Florin Coras6792ec02017-03-13 03:49:51 -0700223 if (n_bytes_read <= 0)
Dave Barach68b0fb02017-02-28 15:15:56 -0500224 goto dequeue_fail;
225
226 /* Keep track of progress locally, transport is also supposed to
Florin Coras6792ec02017-03-13 03:49:51 -0700227 * increment it independently when pushing the header */
Dave Barach68b0fb02017-02-28 15:15:56 -0500228 rx_offset += n_bytes_read;
229 }
230 else
231 {
Florin Coras6792ec02017-03-13 03:49:51 -0700232 n_bytes_read = svm_fifo_dequeue_nowait (s0->server_tx_fifo,
Florin Corasa5464812017-04-19 13:00:05 -0700233 len_to_deq0, data0);
Florin Coras6792ec02017-03-13 03:49:51 -0700234 if (n_bytes_read <= 0)
Dave Barach68b0fb02017-02-28 15:15:56 -0500235 goto dequeue_fail;
236 }
237
Florin Coras6792ec02017-03-13 03:49:51 -0700238 b0->current_length = n_bytes_read;
Dave Barach68b0fb02017-02-28 15:15:56 -0500239
240 /* Ask transport to push header */
241 transport_vft->push_header (tc0, b0);
242
Florin Coras6792ec02017-03-13 03:49:51 -0700243 left_to_snd0 -= n_bytes_read;
Dave Barach68b0fb02017-02-28 15:15:56 -0500244 *n_tx_packets = *n_tx_packets + 1;
245
246 vlib_validate_buffer_enqueue_x1 (vm, node, next_index,
247 to_next, n_left_to_next,
248 bi0, next0);
249 }
250 vlib_put_next_frame (vm, node, next_index, n_left_to_next);
251 }
252
Florin Coras6792ec02017-03-13 03:49:51 -0700253 /* If we couldn't dequeue all bytes mark as partially read */
254 if (max_len_to_snd0 < max_dequeue0)
Dave Barach68b0fb02017-02-28 15:15:56 -0500255 {
Florin Coras6792ec02017-03-13 03:49:51 -0700256 /* If we don't already have new event */
257 if (svm_fifo_set_event (s0->server_tx_fifo))
258 {
259 vec_add1 (smm->evts_partially_read[thread_index], *e0);
260 }
Dave Barach68b0fb02017-02-28 15:15:56 -0500261 }
262 return 0;
263
264dequeue_fail:
Florin Coras6792ec02017-03-13 03:49:51 -0700265 /*
266 * Can't read from fifo. If we don't already have an event, save as partially
267 * read, return buff to free list and return
268 */
269 clib_warning ("dequeue fail");
Dave Barach68b0fb02017-02-28 15:15:56 -0500270
Florin Coras6792ec02017-03-13 03:49:51 -0700271 if (svm_fifo_set_event (s0->server_tx_fifo))
272 {
273 vec_add1 (smm->evts_partially_read[thread_index], *e0);
274 }
275 vlib_put_next_frame (vm, node, next_index, n_left_to_next + 1);
Dave Barach68b0fb02017-02-28 15:15:56 -0500276 _vec_len (smm->tx_buffers[thread_index]) += 1;
277
Dave Barach68b0fb02017-02-28 15:15:56 -0500278 return 0;
279}
280
281int
Florin Corasd79b41e2017-03-04 05:37:52 -0800282session_tx_fifo_peek_and_snd (vlib_main_t * vm, vlib_node_runtime_t * node,
283 session_manager_main_t * smm,
284 session_fifo_event_t * e0,
285 stream_session_t * s0, u32 thread_index,
286 int *n_tx_pkts)
Dave Barach68b0fb02017-02-28 15:15:56 -0500287{
Florin Corasd79b41e2017-03-04 05:37:52 -0800288 return session_tx_fifo_read_and_snd_i (vm, node, smm, e0, s0, thread_index,
289 n_tx_pkts, 1);
Dave Barach68b0fb02017-02-28 15:15:56 -0500290}
291
292int
Florin Corasd79b41e2017-03-04 05:37:52 -0800293session_tx_fifo_dequeue_and_snd (vlib_main_t * vm, vlib_node_runtime_t * node,
294 session_manager_main_t * smm,
295 session_fifo_event_t * e0,
296 stream_session_t * s0, u32 thread_index,
297 int *n_tx_pkts)
Dave Barach68b0fb02017-02-28 15:15:56 -0500298{
Florin Corasd79b41e2017-03-04 05:37:52 -0800299 return session_tx_fifo_read_and_snd_i (vm, node, smm, e0, s0, thread_index,
300 n_tx_pkts, 0);
Dave Barach68b0fb02017-02-28 15:15:56 -0500301}
302
Florin Corasa5464812017-04-19 13:00:05 -0700303stream_session_t *
304session_event_get_session (session_fifo_event_t * e0, u8 thread_index)
305{
306 svm_fifo_t *f0;
307 stream_session_t *s0;
308 u32 session_index0;
309
310 f0 = e0->fifo;
311 session_index0 = f0->master_session_index;
312
313 /* $$$ add multiple event queues, per vpp worker thread */
314 ASSERT (f0->master_thread_index == thread_index);
315
316 s0 = stream_session_get_if_valid (session_index0, thread_index);
317
318 ASSERT (s0->thread_index == thread_index);
319
320 return s0;
321}
322
Dave Barach68b0fb02017-02-28 15:15:56 -0500323static uword
324session_queue_node_fn (vlib_main_t * vm, vlib_node_runtime_t * node,
325 vlib_frame_t * frame)
326{
327 session_manager_main_t *smm = vnet_get_session_manager_main ();
328 session_fifo_event_t *my_fifo_events, *e;
Florin Corase04c2992017-03-01 08:17:34 -0800329 u32 n_to_dequeue, n_events;
Dave Barach68b0fb02017-02-28 15:15:56 -0500330 unix_shared_memory_queue_t *q;
Florin Coras6792ec02017-03-13 03:49:51 -0700331 application_t *app;
Dave Barach68b0fb02017-02-28 15:15:56 -0500332 int n_tx_packets = 0;
Damjan Marion586afd72017-04-05 19:18:20 +0200333 u32 my_thread_index = vm->thread_index;
Dave Barach68b0fb02017-02-28 15:15:56 -0500334 int i, rv;
Florin Coras3e350af2017-03-30 02:54:28 -0700335 f64 now = vlib_time_now (vm);
336
337 SESSION_EVT_DBG (SESSION_EVT_POLL_GAP_TRACK, smm, my_thread_index);
Dave Barach68b0fb02017-02-28 15:15:56 -0500338
339 /*
340 * Update TCP time
341 */
Florin Coras3e350af2017-03-30 02:54:28 -0700342 tcp_update_time (now, my_thread_index);
Dave Barach68b0fb02017-02-28 15:15:56 -0500343
344 /*
345 * Get vpp queue events
346 */
347 q = smm->vpp_event_queues[my_thread_index];
348 if (PREDICT_FALSE (q == 0))
349 return 0;
350
351 /* min number of events we can dequeue without blocking */
352 n_to_dequeue = q->cursize;
Dave Barach68b0fb02017-02-28 15:15:56 -0500353 my_fifo_events = smm->fifo_events[my_thread_index];
354
Florin Corase04c2992017-03-01 08:17:34 -0800355 if (n_to_dequeue == 0 && vec_len (my_fifo_events) == 0)
356 return 0;
357
Florin Coras6792ec02017-03-13 03:49:51 -0700358 SESSION_EVT_DBG (SESSION_EVT_DEQ_NODE, 0);
359
Florin Corase04c2992017-03-01 08:17:34 -0800360 /*
361 * If we didn't manage to process previous events try going
Dave Barach68b0fb02017-02-28 15:15:56 -0500362 * over them again without dequeuing new ones.
Florin Corase04c2992017-03-01 08:17:34 -0800363 */
364 /* XXX: Block senders to sessions that can't keep up */
Dave Barach68b0fb02017-02-28 15:15:56 -0500365 if (vec_len (my_fifo_events) >= 100)
Florin Coras6792ec02017-03-13 03:49:51 -0700366 {
367 clib_warning ("too many fifo events unsolved");
368 goto skip_dequeue;
369 }
Dave Barach68b0fb02017-02-28 15:15:56 -0500370
371 /* See you in the next life, don't be late */
372 if (pthread_mutex_trylock (&q->mutex))
373 return 0;
374
375 for (i = 0; i < n_to_dequeue; i++)
376 {
377 vec_add2 (my_fifo_events, e, 1);
378 unix_shared_memory_queue_sub_raw (q, (u8 *) e);
379 }
380
381 /* The other side of the connection is not polling */
382 if (q->cursize < (q->maxsize / 8))
383 (void) pthread_cond_broadcast (&q->condvar);
384 pthread_mutex_unlock (&q->mutex);
385
386 smm->fifo_events[my_thread_index] = my_fifo_events;
387
388skip_dequeue:
Florin Corase04c2992017-03-01 08:17:34 -0800389 n_events = vec_len (my_fifo_events);
390 for (i = 0; i < n_events; i++)
Dave Barach68b0fb02017-02-28 15:15:56 -0500391 {
Florin Corasa5464812017-04-19 13:00:05 -0700392 stream_session_t *s0; /* $$$ prefetch 1 ahead maybe */
Dave Barach68b0fb02017-02-28 15:15:56 -0500393 session_fifo_event_t *e0;
394
395 e0 = &my_fifo_events[i];
Dave Barach68b0fb02017-02-28 15:15:56 -0500396
397 switch (e0->event_type)
398 {
Florin Corasa5464812017-04-19 13:00:05 -0700399 case FIFO_EVENT_APP_TX:
400 s0 = session_event_get_session (e0, my_thread_index);
401
402 if (CLIB_DEBUG && !s0)
403 {
404 clib_warning ("It's dead, Jim!");
405 continue;
406 }
407
408 if (PREDICT_FALSE (s0->session_state == SESSION_STATE_CLOSED))
409 continue;
Dave Barach68b0fb02017-02-28 15:15:56 -0500410 /* Spray packets in per session type frames, since they go to
411 * different nodes */
Florin Corase69f4952017-03-07 10:06:24 -0800412 rv = (smm->session_tx_fns[s0->session_type]) (vm, node, smm, e0, s0,
Dave Barach68b0fb02017-02-28 15:15:56 -0500413 my_thread_index,
414 &n_tx_packets);
Florin Coras6792ec02017-03-13 03:49:51 -0700415 /* Out of buffers */
Dave Barach68b0fb02017-02-28 15:15:56 -0500416 if (rv < 0)
417 goto done;
418
419 break;
Florin Corasa5464812017-04-19 13:00:05 -0700420 case FIFO_EVENT_DISCONNECT:
421 s0 = stream_session_get_from_handle (e0->session_handle);
Florin Coras6792ec02017-03-13 03:49:51 -0700422 stream_session_disconnect (s0);
423 break;
424 case FIFO_EVENT_BUILTIN_RX:
Florin Corasa5464812017-04-19 13:00:05 -0700425 s0 = session_event_get_session (e0, my_thread_index);
Florin Coras6792ec02017-03-13 03:49:51 -0700426 svm_fifo_unset_event (s0->server_rx_fifo);
427 /* Get session's server */
428 app = application_get (s0->app_index);
429 app->cb_fns.builtin_server_rx_callback (s0);
430 break;
Dave Barach68b0fb02017-02-28 15:15:56 -0500431 default:
432 clib_warning ("unhandled event type %d", e0->event_type);
433 }
434 }
435
436done:
437
438 /* Couldn't process all events. Probably out of buffers */
Florin Corase04c2992017-03-01 08:17:34 -0800439 if (PREDICT_FALSE (i < n_events))
Dave Barach68b0fb02017-02-28 15:15:56 -0500440 {
441 session_fifo_event_t *partially_read =
442 smm->evts_partially_read[my_thread_index];
Florin Corase04c2992017-03-01 08:17:34 -0800443 vec_add (partially_read, &my_fifo_events[i], n_events - i);
Dave Barach68b0fb02017-02-28 15:15:56 -0500444 vec_free (my_fifo_events);
445 smm->fifo_events[my_thread_index] = partially_read;
446 smm->evts_partially_read[my_thread_index] = 0;
447 }
448 else
449 {
450 vec_free (smm->fifo_events[my_thread_index]);
451 smm->fifo_events[my_thread_index] =
452 smm->evts_partially_read[my_thread_index];
453 smm->evts_partially_read[my_thread_index] = 0;
454 }
455
456 vlib_node_increment_counter (vm, session_queue_node.index,
457 SESSION_QUEUE_ERROR_TX, n_tx_packets);
458
Florin Coras6792ec02017-03-13 03:49:51 -0700459 SESSION_EVT_DBG (SESSION_EVT_DEQ_NODE, 1);
460
Dave Barach68b0fb02017-02-28 15:15:56 -0500461 return n_tx_packets;
462}
463
464/* *INDENT-OFF* */
465VLIB_REGISTER_NODE (session_queue_node) =
466{
467 .function = session_queue_node_fn,
468 .name = "session-queue",
469 .format_trace = format_session_queue_trace,
470 .type = VLIB_NODE_TYPE_INPUT,
471 .n_errors = ARRAY_LEN (session_queue_error_strings),
472 .error_strings = session_queue_error_strings,
473 .n_next_nodes = SESSION_QUEUE_N_NEXT,
Florin Corase04c2992017-03-01 08:17:34 -0800474 .state = VLIB_NODE_STATE_DISABLED,
Dave Barach68b0fb02017-02-28 15:15:56 -0500475 .next_nodes =
476 {
477 [SESSION_QUEUE_NEXT_DROP] = "error-drop",
478 [SESSION_QUEUE_NEXT_IP4_LOOKUP] = "ip4-lookup",
479 [SESSION_QUEUE_NEXT_IP6_LOOKUP] = "ip6-lookup",
480 [SESSION_QUEUE_NEXT_TCP_IP4_OUTPUT] = "tcp4-output",
481 [SESSION_QUEUE_NEXT_TCP_IP6_OUTPUT] = "tcp6-output",
482 },
483};
484/* *INDENT-ON* */
485
486/*
487 * fd.io coding-style-patch-verification: ON
488 *
489 * Local Variables:
490 * eval: (c-set-style "gnu")
491 * End:
492 */