FD.io VPP  v16.06
Vector Packet Processing
node.h File Reference
+ Include dependency graph for node.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  vlib_node_stats_t
 
struct  vlib_node_t
 
struct  vlib_frame_t
 
struct  vlib_next_frame_t
 
struct  vlib_pending_frame_t
 
struct  vlib_node_runtime_t
 
struct  vlib_frame_size_t
 
struct  vlib_process_event_type_t
 
struct  vlib_process_t
 
struct  vlib_one_time_waiting_process_t
 
struct  vlib_signal_timed_event_data_t
 
struct  vlib_node_main_t
 

Macros

#define VLIB_REGISTER_NODE(x, ...)
 
#define foreach_vlib_node_state
 
#define VLIB_NODE_FLAG_FRAME_NO_FREE_AFTER_DISPATCH   (1 << 0)
 
#define VLIB_NODE_FLAG_IS_OUTPUT   (1 << 1)
 
#define VLIB_NODE_FLAG_IS_DROP   (1 << 2)
 
#define VLIB_NODE_FLAG_IS_PUNT   (1 << 3)
 
#define VLIB_NODE_FLAG_IS_HANDOFF   (1 << 4)
 
#define VLIB_NODE_FLAG_TRACE   (1 << 5)
 
#define VLIB_NODE_FLAG_SWITCH_FROM_INTERRUPT_TO_POLLING_MODE   (1 << 6)
 
#define VLIB_NODE_FLAG_SWITCH_FROM_POLLING_TO_INTERRUPT_MODE   (1 << 7)
 
#define VLIB_INVALID_NODE_INDEX   ((u32) ~0)
 
#define VLIB_FRAME_SIZE   256
 
#define VLIB_FRAME_ALIGN   VLIB_MAX_CPUS
 
#define VLIB_FRAME_NO_FREE_AFTER_DISPATCH   VLIB_NODE_FLAG_FRAME_NO_FREE_AFTER_DISPATCH
 
#define VLIB_FRAME_OWNER   (1 << 15)
 
#define VLIB_FRAME_IS_ALLOCATED   VLIB_NODE_FLAG_IS_OUTPUT
 
#define VLIB_FRAME_PENDING   VLIB_NODE_FLAG_IS_DROP
 
#define VLIB_FRAME_FREE_AFTER_DISPATCH   VLIB_NODE_FLAG_IS_PUNT
 
#define VLIB_FRAME_TRACE   VLIB_NODE_FLAG_TRACE
 
#define VLIB_PENDING_FRAME_NO_NEXT_FRAME   ((u32) ~0)
 
#define VLIB_PROCESS_RETURN_LONGJMP_RETURN   ((uword) ~0 - 0)
 
#define VLIB_PROCESS_RETURN_LONGJMP_SUSPEND   ((uword) ~0 - 1)
 
#define VLIB_PROCESS_RESUME_LONGJMP_SUSPEND   0
 
#define VLIB_PROCESS_RESUME_LONGJMP_RESUME   1
 
#define VLIB_PROCESS_IS_SUSPENDED_WAITING_FOR_CLOCK   (1 << 0)
 
#define VLIB_PROCESS_IS_SUSPENDED_WAITING_FOR_EVENT   (1 << 1)
 
#define VLIB_PROCESS_RESUME_PENDING   (1 << 2)
 
#define VLIB_PROCESS_IS_RUNNING   (1 << 3)
 
#define PAGE_SIZE_MULTIPLE   0x1000
 
#define ALIGN_ON_MULTIPLE_PAGE_BOUNDARY_FOR_MPROTECT   __attribute__ ((aligned (PAGE_SIZE_MULTIPLE)))
 
#define VLIB_PROCESS_STACK_MAGIC   (0xdead7ead)
 
#define VLIB_NODE_MAIN_RUNTIME_STARTED   (1 << 0)
 

Typedefs

typedef uwordvlib_node_function_t) (struct vlib_main_t *vm, struct vlib_node_runtime_t *node, struct vlib_frame_t *frame)
 
typedef struct _vlib_node_registration vlib_node_registration_t
 
typedef struct vlib_node_t vlib_node_t
 
typedef struct vlib_frame_t vlib_frame_t
 
typedef struct vlib_node_runtime_t vlib_node_runtime_t
 
typedef char assert_process_stack_must_be_aligned_exactly_to_page_size_multiple[(sizeof(vlib_process_t)-PAGE_SIZE_MULTIPLE)==0?0:-1]
 

Enumerations

enum  vlib_node_type_t {
  VLIB_NODE_TYPE_INTERNAL, VLIB_NODE_TYPE_INPUT, VLIB_NODE_TYPE_PRE_INPUT, VLIB_NODE_TYPE_PROCESS,
  VLIB_N_NODE_TYPE
}
 
enum  vlib_node_state_t { VLIB_N_NODE_STATE }
 

Functions

always_inline vlib_node_registration_tvlib_node_next_registered (vlib_node_registration_t *c)
 
always_inline void vlib_next_frame_init (vlib_next_frame_t *nf)
 
always_inline uword vlib_timing_wheel_data_is_timed_event (u32 d)
 
always_inline u32 vlib_timing_wheel_data_set_suspended_process (u32 i)
 
always_inline u32 vlib_timing_wheel_data_set_timed_event (u32 i)
 
always_inline uword vlib_timing_wheel_data_get_index (u32 d)
 

Macro Definition Documentation

#define ALIGN_ON_MULTIPLE_PAGE_BOUNDARY_FOR_MPROTECT   __attribute__ ((aligned (PAGE_SIZE_MULTIPLE)))

Definition at line 507 of file node.h.

#define foreach_vlib_node_state
Value:
/* Input node is called each iteration of main loop. \
This is the default (zero). */ \
_ (POLLING) \
/* Input node is called when device signals an interrupt. */ \
_ (INTERRUPT) \
/* Input node is never called. */ \
_ (DISABLED)

Definition at line 166 of file node.h.

#define PAGE_SIZE_MULTIPLE   0x1000

Definition at line 506 of file node.h.

#define VLIB_FRAME_ALIGN   VLIB_MAX_CPUS

Definition at line 293 of file node.h.

#define VLIB_FRAME_FREE_AFTER_DISPATCH   VLIB_NODE_FLAG_IS_PUNT

Definition at line 341 of file node.h.

#define VLIB_FRAME_IS_ALLOCATED   VLIB_NODE_FLAG_IS_OUTPUT

Definition at line 335 of file node.h.

#define VLIB_FRAME_NO_FREE_AFTER_DISPATCH   VLIB_NODE_FLAG_FRAME_NO_FREE_AFTER_DISPATCH

Definition at line 327 of file node.h.

#define VLIB_FRAME_OWNER   (1 << 15)

Definition at line 332 of file node.h.

#define VLIB_FRAME_PENDING   VLIB_NODE_FLAG_IS_DROP

Definition at line 338 of file node.h.

#define VLIB_FRAME_SIZE   256

Definition at line 292 of file node.h.

#define VLIB_FRAME_TRACE   VLIB_NODE_FLAG_TRACE

Definition at line 344 of file node.h.

#define VLIB_INVALID_NODE_INDEX   ((u32) ~0)

Definition at line 289 of file node.h.

#define VLIB_NODE_FLAG_FRAME_NO_FREE_AFTER_DISPATCH   (1 << 0)

Definition at line 216 of file node.h.

#define VLIB_NODE_FLAG_IS_DROP   (1 << 2)

Definition at line 220 of file node.h.

#define VLIB_NODE_FLAG_IS_HANDOFF   (1 << 4)

Definition at line 222 of file node.h.

#define VLIB_NODE_FLAG_IS_OUTPUT   (1 << 1)

Definition at line 219 of file node.h.

#define VLIB_NODE_FLAG_IS_PUNT   (1 << 3)

Definition at line 221 of file node.h.

#define VLIB_NODE_FLAG_SWITCH_FROM_INTERRUPT_TO_POLLING_MODE   (1 << 6)

Definition at line 227 of file node.h.

#define VLIB_NODE_FLAG_SWITCH_FROM_POLLING_TO_INTERRUPT_MODE   (1 << 7)

Definition at line 228 of file node.h.

#define VLIB_NODE_FLAG_TRACE   (1 << 5)

Definition at line 225 of file node.h.

#define VLIB_NODE_MAIN_RUNTIME_STARTED   (1 << 0)

Definition at line 576 of file node.h.

#define VLIB_PENDING_FRAME_NO_NEXT_FRAME   ((u32) ~0)

Definition at line 370 of file node.h.

#define VLIB_PROCESS_IS_RUNNING   (1 << 3)

Definition at line 470 of file node.h.

#define VLIB_PROCESS_IS_SUSPENDED_WAITING_FOR_CLOCK   (1 << 0)

Definition at line 464 of file node.h.

#define VLIB_PROCESS_IS_SUSPENDED_WAITING_FOR_EVENT   (1 << 1)

Definition at line 465 of file node.h.

#define VLIB_PROCESS_RESUME_LONGJMP_RESUME   1

Definition at line 461 of file node.h.

#define VLIB_PROCESS_RESUME_LONGJMP_SUSPEND   0

Definition at line 460 of file node.h.

#define VLIB_PROCESS_RESUME_PENDING   (1 << 2)

Definition at line 467 of file node.h.

#define VLIB_PROCESS_RETURN_LONGJMP_RETURN   ((uword) ~0 - 0)

Definition at line 455 of file node.h.

#define VLIB_PROCESS_RETURN_LONGJMP_SUSPEND   ((uword) ~0 - 1)

Definition at line 456 of file node.h.

#define VLIB_PROCESS_STACK_MAGIC   (0xdead7ead)

Definition at line 515 of file node.h.

#define VLIB_REGISTER_NODE (   x,
  ... 
)
Value:
__VA_ARGS__ vlib_node_registration_t x; \
static void __vlib_add_node_registration_##x (void) \
__attribute__((__constructor__)) ; \
static void __vlib_add_node_registration_##x (void) \
{ \
x.next_registration = vm->node_main.node_registrations; \
vm->node_main.node_registrations = &x; \
} \
struct _vlib_node_registration vlib_node_registration_t
always_inline vlib_main_t * vlib_get_main(void)
Definition: global_funcs.h:23
struct vlib_main_t vlib_main_t

Definition at line 140 of file node.h.

Typedef Documentation

typedef char assert_process_stack_must_be_aligned_exactly_to_page_size_multiple[(sizeof(vlib_process_t)-PAGE_SIZE_MULTIPLE)==0?0:-1]

Definition at line 522 of file node.h.

typedef struct vlib_frame_t vlib_frame_t
typedef uword( vlib_node_function_t) (struct vlib_main_t *vm, struct vlib_node_runtime_t *node, struct vlib_frame_t *frame)

Definition at line 53 of file node.h.

typedef struct _vlib_node_registration vlib_node_registration_t
typedef struct vlib_node_t vlib_node_t

Enumeration Type Documentation

Enumerator
VLIB_N_NODE_STATE 

Definition at line 175 of file node.h.

Enumerator
VLIB_NODE_TYPE_INTERNAL 
VLIB_NODE_TYPE_INPUT 
VLIB_NODE_TYPE_PRE_INPUT 
VLIB_NODE_TYPE_PROCESS 
VLIB_N_NODE_TYPE 

Definition at line 57 of file node.h.

Function Documentation

always_inline void vlib_next_frame_init ( vlib_next_frame_t nf)

Definition at line 351 of file node.h.

+ Here is the caller graph for this function:

Definition at line 153 of file node.h.

always_inline uword vlib_timing_wheel_data_get_index ( u32  d)

Definition at line 565 of file node.h.

+ Here is the caller graph for this function:

always_inline uword vlib_timing_wheel_data_is_timed_event ( u32  d)

Definition at line 553 of file node.h.

+ Here is the caller graph for this function:

always_inline u32 vlib_timing_wheel_data_set_suspended_process ( u32  i)

Definition at line 557 of file node.h.

+ Here is the caller graph for this function:

always_inline u32 vlib_timing_wheel_data_set_timed_event ( u32  i)

Definition at line 561 of file node.h.

+ Here is the caller graph for this function: