40 clib_warning (
"no collector: disabling flow collector process");
42 VLIB_NODE_STATE_DISABLED);
100 u32 ip4_lookup_node_index;
109 uword *event_data = 0;
115 clib_warning (
"bogus kickoff event received, %d", event_type);
120 ip4_lookup_node_index = ip4_lookup_node->
index;
146 if (template_bi != ~0)
148 to_next[0] = template_bi;
154 nf, to_next, ip4_lookup_node_index);
166 .name =
"flow-report-process",
173 int found_index = ~0;
190 if (found_index != ~0)
195 return VNET_API_ERROR_NO_SUCH_ENTRY;
230 if (collector.
as_u32 == 0)
251 .short_help =
"set ipfix collector <ip4-address> src <ip4-address>",
flow_report_main_t flow_report_main
sll srl srl sll sra u16x4 i
always_inline uword vlib_process_get_events(vlib_main_t *vm, uword **data_vector)
vlib_node_registration_t flow_report_process_node
(constructor) VLIB_REGISTER_NODE (flow_report_process_node)
#define vec_add2(V, P, N)
Add N elements to end of vector V, return pointer to new elements in P.
ip4_address_t src_address
always_inline void vlib_process_signal_event(vlib_main_t *vm, uword node_index, uword type_opaque, uword data)
always_inline uword vlib_process_suspend(vlib_main_t *vm, f64 dt)
always_inline void * vlib_buffer_get_current(vlib_buffer_t *b)
Get pointer to current data to process.
#define vec_reset_length(v)
Reset vector length to zero NULL-pointer tolerant.
ip4_address_t ipfix_collector
vlib_node_registration_t ip4_lookup_node
(constructor) VLIB_REGISTER_NODE (ip4_lookup_node)
vnet_main_t * vnet_get_main(void)
i16 current_data
signed offset in data[], pre_data[] that we are currently processing.
#define VLIB_INIT_FUNCTION(x)
vnet_flow_rewrite_callback_t * rewrite_callback
#define vec_elt_at_index(v, i)
Get vector value at index i checking that i is in bounds.
always_inline void vlib_node_set_state(vlib_main_t *vm, u32 node_index, vlib_node_state_t new_state)
#define clib_warning(format, args...)
static uword flow_report_process(vlib_main_t *vm, vlib_node_runtime_t *rt, vlib_frame_t *f)
always_inline void * vlib_frame_vector_args(vlib_frame_t *f)
#define VLIB_BUFFER_DEFAULT_FREE_LIST_BYTES
u16 current_length
Nbytes between current data and the end of this buffer.
always_inline f64 vlib_process_wait_for_event_or_clock(vlib_main_t *vm, f64 dt)
void vlib_put_frame_to_node(vlib_main_t *vm, u32 to_node_index, vlib_frame_t *f)
void vlib_cli_output(vlib_main_t *vm, char *fmt,...)
int send_template_packet(flow_report_main_t *frm, flow_report_t *fr, u32 *buffer_indexp)
#define vec_free(V)
Free vector's memory (no header).
#define clib_memcpy(a, b, c)
#define VLIB_BUFFER_TOTAL_LENGTH_VALID
#define VLIB_CLI_COMMAND(x,...)
#define vec_delete(V, N, M)
Delete N elements starting at element M.
u32 vlib_buffer_alloc(vlib_main_t *vm, u32 *buffers, u32 n_buffers)
Allocate buffers into supplied array.
vnet_flow_data_callback_t * flow_data_callback
vlib_node_t * vlib_get_node_by_name(vlib_main_t *vm, u8 *name)
#define vec_len(v)
Number of elements in vector (rvalue-only, NULL tolerant)
static clib_error_t * set_ipfix_command_fn(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
vnet_flow_data_callback_t * flow_data_callback
#define VLIB_REGISTER_NODE(x,...)
vnet_flow_rewrite_callback_t * rewrite_callback
#define vec_foreach(var, vec)
Vector iterator.
always_inline f64 vlib_time_now(vlib_main_t *vm)
#define clib_error_return(e, args...)
vlib_frame_t * vlib_get_frame_to_node(vlib_main_t *vm, u32 to_node_index)
u32 flags
buffer flags: VLIB_BUFFER_IS_TRACED: trace this buffer.
always_inline vlib_buffer_t * vlib_get_buffer(vlib_main_t *vm, u32 buffer_index)
Translate buffer index into buffer pointer.
static clib_error_t * flow_report_init(vlib_main_t *vm)
int vnet_flow_report_add_del(flow_report_main_t *frm, vnet_flow_report_add_del_args_t *a)