{
b = vlib_get_buffer (vm, to_next[i - n_segs]);
vlib_trace_buffer (vm, node, next_index, b, 1 /* follow_chain */ );
- vlib_set_trace_count (vm, node, --n_trace);
t = vlib_add_trace (vm, node, b, sizeof (*t));
t->session_index = s->session_index;
t->server_thread_index = s->thread_index;
}
+ vlib_set_trace_count (vm, node, n_trace - i);
}
always_inline void
b->error = 0;
b->flags = VNET_BUFFER_F_LOCALLY_ORIGINATED;
b->current_data = 0;
- b->total_length_not_including_first_buffer = 0;
data0 = vlib_buffer_make_headroom (b, MAX_HDRS_LEN);
len_to_deq = clib_min (ctx->left_to_snd, ctx->deq_per_first_buf);
session_tx_fifo_chain_tail (vm, ctx, b, n_bufs, peek_data);
/* *INDENT-OFF* */
- SESSION_EVT_DBG(SESSION_EVT_DEQ, s, ({
- ed->data[0] = e->event_type;
- ed->data[1] = max_dequeue;
+ SESSION_EVT_DBG(SESSION_EVT_DEQ, ctx->s, ({
+ ed->data[0] = FIFO_EVENT_APP_TX;
+ ed->data[1] = ctx->max_dequeue;
ed->data[2] = len_to_deq;
- ed->data[3] = left_to_snd;
+ ed->data[3] = ctx->left_to_snd;
}));
/* *INDENT-ON* */
}
}
break;
case FIFO_EVENT_DISCONNECT:
- /* Make sure stream disconnects run after the pending list is drained */
+ /* Make sure stream disconnects run after the pending list is
+ * drained */
s0 = session_get_from_handle (e0->session_handle);
if (!e0->postponed)
{
vec_add1 (smm->pending_disconnects[thread_index], *e0);
continue;
}
- /* If tx queue is still not empty, wait a bit */
- if (svm_fifo_max_dequeue (s0->server_tx_fifo)
- && e0->postponed < 200)
+ /* If tx queue is still not empty, wait */
+ if (svm_fifo_max_dequeue (s0->server_tx_fifo))
{
- e0->postponed += 1;
vec_add1 (smm->pending_disconnects[thread_index], *e0);
continue;
}
vlib_node_increment_counter (vm, session_queue_node.index,
SESSION_QUEUE_ERROR_TX, n_tx_packets);
- SESSION_EVT_DBG (SESSION_EVT_DEQ_NODE, 1);
+ SESSION_EVT_DBG (SESSION_EVT_DISPATCH_END, smm, thread_index);
return n_tx_packets;
}