|
FD.io VPP
v21.06-3-gbb25fbf28
Vector Packet Processing
|
Go to the documentation of this file.
19 #ifndef CLIB_MARCH_VARIANT
71 u32 indent = va_arg (*args,
u32);
79 return (
format(s,
"pw-cw[???,%d]:", pwcwi));
83 s =
format(s,
"pw-cw[%d]:", pwcwi);
150 u32 bi0, pwcwi0, bi1, pwcwi1;
154 bi0 = to_next[0] =
from[0];
155 bi1 = to_next[1] =
from[1];
210 bi0, bi1, next0, next1);
244 n_left_to_next, bi0, next0);
274 .vector_size =
sizeof(
u32),
278 #ifndef CLIB_MARCH_VARIANT
pw_cw_dpo_t * pw_cw_dpo_pool
const static dpo_vft_t pwcw_vft
u16 dpoi_next_node
The next VLIB node to follow.
const static char *const pw_cw_proto_nodes[]
index_t dpoi_index
the index of objects of that type
vlib_main_t vlib_node_runtime_t vlib_frame_t * frame
#define vlib_prefetch_buffer_header(b, type)
Prefetch buffer metadata.
nat44_ei_hairpin_src_next_t next_index
#define pool_get_aligned_zero(P, E, A)
Allocate an object E from a pool P with alignment A and zero it.
u32 pw_cw_t
A Psuedo Wire Control Word is 4 bytes.
static void pw_cw_dpo_mem_show(void)
static vlib_buffer_t * vlib_get_buffer(vlib_main_t *vm, u32 buffer_index)
Translate buffer index into buffer pointer.
vlib_main_t vlib_node_runtime_t * node
dpo_id_t pwcw_parent
Next DPO in the graph.
struct pw_cw_trace_t_ pw_cw_trace_t
A struct to hold tracing information for the MPLS label imposition node.
static index_t pw_cw_dpo_get_index(pw_cw_dpo_t *pwcw)
#define pool_put(P, E)
Free an object E in pool P.
vlib_main_t * vm
X-connect all packets from the HOST to the PHY.
vlib_main_t vlib_node_runtime_t vlib_frame_t * from_frame
const static char *const *const pw_cw_nodes[DPO_PROTO_NUM]
static void pw_cw_dpo_lock(dpo_id_t *dpo)
#define pool_is_free_index(P, I)
Use free bitmap to query whether given index is free.
#define CLIB_PREFETCH(addr, size, type)
A representation of a Psuedo Wire Control Word pop DPO.
static void vlib_buffer_advance(vlib_buffer_t *b, word l)
Advance current data pointer by the supplied (signed!) amount.
#define VLIB_NODE_FN(node)
void dpo_stack(dpo_type_t child_type, dpo_proto_t child_proto, dpo_id_t *dpo, const dpo_id_t *parent)
Stack one DPO object on another, and thus establish a child-parent relationship.
vlib_node_registration_t pw_cw_node
(constructor) VLIB_REGISTER_NODE (pw_cw_node)
static void * vlib_frame_vector_args(vlib_frame_t *f)
Get pointer to frame vector data.
u32 index_t
A Data-Path Object is an object that represents actions that are applied to packets are they are swit...
void fib_show_memory_usage(const char *name, u32 in_use_elts, u32 allocd_elts, size_t size_elt)
Show the memory usage for a type.
static void pw_cw_dpo_unlock(dpo_id_t *dpo)
static u8 * format_pw_cw_trace(u8 *s, va_list *args)
void pw_cw_dpo_create(const dpo_id_t *parent, dpo_id_t *dpo)
Create an PW CW pop.
u16 pwcw_locks
Number of locks/users of the label.
dpo_lock_fn_t dv_lock
A reference counting lock function.
struct _vlib_node_registration vlib_node_registration_t
static pw_cw_dpo_t * pw_cw_dpo_alloc(void)
dpo_proto_t dpoi_proto
the data-path protocol of the type.
u8 * format_dpo_id(u8 *s, va_list *args)
Format a DPO_id_t oject.
#define pool_len(p)
Number of elements in pool vector.
#define vlib_validate_buffer_enqueue_x1(vm, node, next_index, to_next, n_left_to_next, bi0, next0)
Finish enqueueing one buffer forward in the graph.
description fragment has unexpected format
vlib_put_next_frame(vm, node, next_index, 0)
void pw_cw_dpo_module_init(void)
static pw_cw_dpo_t * pw_cw_dpo_get(index_t index)
static uword pool_elts(void *v)
Number of active elements in a pool.
A virtual function table regisitered for a DPO type.
void * vlib_add_trace(vlib_main_t *vm, vlib_node_runtime_t *r, vlib_buffer_t *b, u32 n_data_bytes)
static uword pw_cw_pop_inline(vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *from_frame)
u8 * format_pw_cw_dpo(u8 *s, va_list *args)
static void * vlib_buffer_get_current(vlib_buffer_t *b)
Get pointer to current data to process.
The identity of a DPO is a combination of its type and its instance number/index of objects of that t...
#define vlib_validate_buffer_enqueue_x2(vm, node, next_index, to_next, n_left_to_next, bi0, bi1, next0, next1)
Finish enqueueing two buffers forward in the graph.
void dpo_set(dpo_id_t *dpo, dpo_type_t type, dpo_proto_t proto, index_t index)
Set/create a DPO ID The DPO will be locked.
#define vlib_get_next_frame(vm, node, next_index, vectors, n_vectors_left)
Get pointer to next frame vector data by (vlib_node_runtime_t, next_index).
A struct to hold tracing information for the MPLS label imposition node.
void dpo_reset(dpo_id_t *dpo)
reset a DPO ID The DPO will be unlocked.
u32 flags
buffer flags: VLIB_BUFFER_FREE_LIST_INDEX_MASK: bits used to store free list index,...
void dpo_register(dpo_type_t type, const dpo_vft_t *vft, const char *const *const *nodes)
For a given DPO type Register:
VLIB buffer representation.
#define VLIB_REGISTER_NODE(x,...)