FD.io VPP  v19.01.3-6-g70449b9b9
Vector Packet Processing
interface_rx_dpo.c File Reference
+ Include dependency graph for interface_rx_dpo.c:

Go to the source code of this file.

Data Structures

struct  interface_rx_dpo_trace_t_
 Interface DPO trace data. More...
 

Typedefs

typedef struct interface_rx_dpo_trace_t_ interface_rx_dpo_trace_t
 Interface DPO trace data. More...
 
typedef enum interface_rx_dpo_next_t_ interface_rx_dpo_next_t
 

Enumerations

enum  interface_rx_dpo_next_t_ { INTERFACE_RX_DPO_DROP = 0, INTERFACE_RX_DPO_INPUT = 1 }
 

Functions

static interface_rx_dpo_tinterface_rx_dpo_alloc (void)
 
static interface_rx_dpo_tinterface_rx_dpo_get_from_dpo (const dpo_id_t *dpo)
 
static index_t interface_rx_dpo_get_index (interface_rx_dpo_t *ido)
 
static void interface_rx_dpo_lock (dpo_id_t *dpo)
 
static void interface_rx_dpo_unlock (dpo_id_t *dpo)
 
void interface_rx_dpo_add_or_lock (dpo_proto_t proto, u32 sw_if_index, dpo_id_t *dpo)
 
static clib_error_tinterface_rx_dpo_interface_state_change (vnet_main_t *vnm, u32 sw_if_index, u32 flags)
 
 VNET_SW_INTERFACE_ADMIN_UP_DOWN_FUNCTION (interface_rx_dpo_interface_state_change)
 
static clib_error_tinterface_rx_dpo_hw_interface_state_change (vnet_main_t *vnm, u32 hw_if_index, u32 flags)
 Registered callback for HW interface state changes. More...
 
 VNET_HW_INTERFACE_LINK_UP_DOWN_FUNCTION (interface_rx_dpo_hw_interface_state_change)
 
static clib_error_tinterface_rx_dpo_interface_delete (vnet_main_t *vnm, u32 sw_if_index, u32 is_add)
 
 VNET_SW_INTERFACE_ADD_DEL_FUNCTION (interface_rx_dpo_interface_delete)
 
u8format_interface_rx_dpo (u8 *s, va_list *ap)
 
static void interface_rx_dpo_mem_show (void)
 
void interface_rx_dpo_module_init (void)
 
static uword interface_rx_dpo_inline (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *from_frame, u8 is_l2)
 
static u8format_interface_rx_dpo_trace (u8 *s, va_list *args)
 
static uword interface_rx_dpo_ip4 (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *from_frame)
 
static uword interface_rx_dpo_ip6 (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *from_frame)
 
static uword interface_rx_dpo_l2 (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *from_frame)
 
 VLIB_NODE_FUNCTION_MULTIARCH (interface_rx_dpo_ip4_node, interface_rx_dpo_ip4)
 (constructor) VLIB_REGISTER_NODE (interface_rx_dpo_ip6_node) More...
 
 VLIB_NODE_FUNCTION_MULTIARCH (interface_rx_dpo_ip6_node, interface_rx_dpo_ip6)
 (constructor) VLIB_REGISTER_NODE (interface_rx_dpo_l2_node) More...
 

Variables

static index_tinterface_rx_dpo_db [DPO_PROTO_NUM]
 
static const dpo_vft_t interface_rx_dpo_vft
 
static const char *const interface_rx_dpo_ip4_nodes []
 The per-protocol VLIB graph nodes that are assigned to a glean object. More...
 
static const char *const interface_rx_dpo_ip6_nodes []
 
static const char *const interface_rx_dpo_l2_nodes []
 
static const char *const *const interface_rx_dpo_nodes [DPO_PROTO_NUM]
 
vlib_node_registration_t interface_rx_dpo_ip4_node
 (constructor) VLIB_REGISTER_NODE (interface_rx_dpo_ip4_node) More...
 

Typedef Documentation

◆ interface_rx_dpo_next_t

◆ interface_rx_dpo_trace_t

Interface DPO trace data.

Enumeration Type Documentation

◆ interface_rx_dpo_next_t_

Enumerator
INTERFACE_RX_DPO_DROP 
INTERFACE_RX_DPO_INPUT 

Definition at line 229 of file interface_rx_dpo.c.

Function Documentation

◆ format_interface_rx_dpo()

u8* format_interface_rx_dpo ( u8 s,
va_list *  ap 
)

Definition at line 151 of file interface_rx_dpo.c.

+ Here is the call graph for this function:

◆ format_interface_rx_dpo_trace()

static u8* format_interface_rx_dpo_trace ( u8 s,
va_list *  args 
)
static

Definition at line 366 of file interface_rx_dpo.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ interface_rx_dpo_add_or_lock()

void interface_rx_dpo_add_or_lock ( dpo_proto_t  proto,
u32  sw_if_index,
dpo_id_t dpo 
)

Definition at line 83 of file interface_rx_dpo.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ interface_rx_dpo_alloc()

static interface_rx_dpo_t* interface_rx_dpo_alloc ( void  )
static

Definition at line 28 of file interface_rx_dpo.c.

+ Here is the caller graph for this function:

◆ interface_rx_dpo_get_from_dpo()

static interface_rx_dpo_t* interface_rx_dpo_get_from_dpo ( const dpo_id_t dpo)
inlinestatic

Definition at line 38 of file interface_rx_dpo.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ interface_rx_dpo_get_index()

static index_t interface_rx_dpo_get_index ( interface_rx_dpo_t ido)
inlinestatic

Definition at line 46 of file interface_rx_dpo.c.

+ Here is the caller graph for this function:

◆ interface_rx_dpo_hw_interface_state_change()

static clib_error_t* interface_rx_dpo_hw_interface_state_change ( vnet_main_t vnm,
u32  hw_if_index,
u32  flags 
)
static

Registered callback for HW interface state changes.

Definition at line 129 of file interface_rx_dpo.c.

+ Here is the call graph for this function:

◆ interface_rx_dpo_inline()

static uword interface_rx_dpo_inline ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t from_frame,
u8  is_l2 
)
inlinestatic

Definition at line 236 of file interface_rx_dpo.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ interface_rx_dpo_interface_delete()

static clib_error_t* interface_rx_dpo_interface_delete ( vnet_main_t vnm,
u32  sw_if_index,
u32  is_add 
)
static

Definition at line 140 of file interface_rx_dpo.c.

+ Here is the call graph for this function:

◆ interface_rx_dpo_interface_state_change()

static clib_error_t* interface_rx_dpo_interface_state_change ( vnet_main_t vnm,
u32  sw_if_index,
u32  flags 
)
static

Definition at line 113 of file interface_rx_dpo.c.

+ Here is the call graph for this function:

◆ interface_rx_dpo_ip4()

static uword interface_rx_dpo_ip4 ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t from_frame 
)
static

Definition at line 379 of file interface_rx_dpo.c.

+ Here is the call graph for this function:

◆ interface_rx_dpo_ip6()

static uword interface_rx_dpo_ip6 ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t from_frame 
)
static

Definition at line 387 of file interface_rx_dpo.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ interface_rx_dpo_l2()

static uword interface_rx_dpo_l2 ( vlib_main_t vm,
vlib_node_runtime_t node,
vlib_frame_t from_frame 
)
static

Definition at line 395 of file interface_rx_dpo.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ interface_rx_dpo_lock()

static void interface_rx_dpo_lock ( dpo_id_t dpo)
static

Definition at line 52 of file interface_rx_dpo.c.

+ Here is the call graph for this function:

◆ interface_rx_dpo_mem_show()

static void interface_rx_dpo_mem_show ( void  )
static

Definition at line 166 of file interface_rx_dpo.c.

+ Here is the call graph for this function:

◆ interface_rx_dpo_module_init()

void interface_rx_dpo_module_init ( void  )

Definition at line 214 of file interface_rx_dpo.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ interface_rx_dpo_unlock()

static void interface_rx_dpo_unlock ( dpo_id_t dpo)
static

Definition at line 61 of file interface_rx_dpo.c.

+ Here is the call graph for this function:

◆ VLIB_NODE_FUNCTION_MULTIARCH() [1/2]

VLIB_NODE_FUNCTION_MULTIARCH ( interface_rx_dpo_ip4_node  ,
interface_rx_dpo_ip4   
)

(constructor) VLIB_REGISTER_NODE (interface_rx_dpo_ip6_node)

Definition at line 415 of file interface_rx_dpo.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ VLIB_NODE_FUNCTION_MULTIARCH() [2/2]

VLIB_NODE_FUNCTION_MULTIARCH ( interface_rx_dpo_ip6_node  ,
interface_rx_dpo_ip6   
)

(constructor) VLIB_REGISTER_NODE (interface_rx_dpo_l2_node)

Definition at line 431 of file interface_rx_dpo.c.

+ Here is the call graph for this function:

◆ VNET_HW_INTERFACE_LINK_UP_DOWN_FUNCTION()

VNET_HW_INTERFACE_LINK_UP_DOWN_FUNCTION ( interface_rx_dpo_hw_interface_state_change  )
+ Here is the caller graph for this function:

◆ VNET_SW_INTERFACE_ADD_DEL_FUNCTION()

VNET_SW_INTERFACE_ADD_DEL_FUNCTION ( interface_rx_dpo_interface_delete  )
+ Here is the caller graph for this function:

◆ VNET_SW_INTERFACE_ADMIN_UP_DOWN_FUNCTION()

VNET_SW_INTERFACE_ADMIN_UP_DOWN_FUNCTION ( interface_rx_dpo_interface_state_change  )
+ Here is the caller graph for this function:

Variable Documentation

◆ interface_rx_dpo_db

index_t* interface_rx_dpo_db[DPO_PROTO_NUM]
static

Definition at line 25 of file interface_rx_dpo.c.

◆ interface_rx_dpo_ip4_node

vlib_node_registration_t interface_rx_dpo_ip4_node
Initial value:
= {
.function = interface_rx_dpo_ip4,
.name = "interface-rx-dpo-ip4",
.vector_size = sizeof (u32),
.n_next_nodes = 2,
.next_nodes = {
[INTERFACE_RX_DPO_DROP] = "ip4-drop",
[INTERFACE_RX_DPO_INPUT] = "ip4-input",
},
}
unsigned int u32
Definition: types.h:88
static u8 * format_interface_rx_dpo_trace(u8 *s, va_list *args)
static uword interface_rx_dpo_ip4(vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *from_frame)

(constructor) VLIB_REGISTER_NODE (interface_rx_dpo_ip4_node)

Definition at line 402 of file interface_rx_dpo.c.

◆ interface_rx_dpo_ip4_nodes

const char* const interface_rx_dpo_ip4_nodes[]
static
Initial value:
=
{
"interface-rx-dpo-ip4",
}
#define NULL
Definition: clib.h:58

The per-protocol VLIB graph nodes that are assigned to a glean object.

this means that these graph nodes are ones from which a glean is the parent object in the DPO-graph.

Definition at line 189 of file interface_rx_dpo.c.

◆ interface_rx_dpo_ip6_nodes

const char* const interface_rx_dpo_ip6_nodes[]
static
Initial value:
=
{
"interface-rx-dpo-ip6",
}
#define NULL
Definition: clib.h:58

Definition at line 194 of file interface_rx_dpo.c.

◆ interface_rx_dpo_l2_nodes

const char* const interface_rx_dpo_l2_nodes[]
static
Initial value:
=
{
"interface-rx-dpo-l2",
}
#define NULL
Definition: clib.h:58

Definition at line 199 of file interface_rx_dpo.c.

◆ interface_rx_dpo_nodes

const char* const* const interface_rx_dpo_nodes[DPO_PROTO_NUM]
static
Initial value:
=
{
}
#define NULL
Definition: clib.h:58
static const char *const interface_rx_dpo_ip4_nodes[]
The per-protocol VLIB graph nodes that are assigned to a glean object.
static const char *const interface_rx_dpo_ip6_nodes[]
static const char *const interface_rx_dpo_l2_nodes[]

Definition at line 205 of file interface_rx_dpo.c.

◆ interface_rx_dpo_vft

const dpo_vft_t interface_rx_dpo_vft
static
Initial value:
= {
.dv_mem_show = interface_rx_dpo_mem_show,
}
static void interface_rx_dpo_mem_show(void)
static void interface_rx_dpo_unlock(dpo_id_t *dpo)
u8 * format_interface_rx_dpo(u8 *s, va_list *ap)
static void interface_rx_dpo_lock(dpo_id_t *dpo)

Definition at line 175 of file interface_rx_dpo.c.