FD.io VPP  v21.06-3-gbb25fbf28
Vector Packet Processing
ipip.c File Reference
+ Include dependency graph for ipip.c:

Go to the source code of this file.

Data Structures

struct  ipip_tx_trace_t
 
struct  mipip_walk_ctx_t_
 

Typedefs

typedef struct mipip_walk_ctx_t_ mipip_walk_ctx_t
 

Functions

u8format_ipip_tx_trace (u8 *s, va_list *args)
 
static u8ipip_build_rewrite (vnet_main_t *vnm, u32 sw_if_index, vnet_link_t link_type, const void *dst_address)
 
static void ipip64_fixup (vlib_main_t *vm, const ip_adjacency_t *adj, vlib_buffer_t *b, const void *data)
 
static void ipip44_fixup (vlib_main_t *vm, const ip_adjacency_t *adj, vlib_buffer_t *b, const void *data)
 
static void ipip46_fixup (vlib_main_t *vm, const ip_adjacency_t *adj, vlib_buffer_t *b, const void *data)
 
static void ipip66_fixup (vlib_main_t *vm, const ip_adjacency_t *adj, vlib_buffer_t *b, const void *data)
 
static void ipipm6_fixup (vlib_main_t *vm, const ip_adjacency_t *adj, vlib_buffer_t *b, const void *data)
 
static void ipipm4_fixup (vlib_main_t *vm, const ip_adjacency_t *adj, vlib_buffer_t *b, const void *data)
 
static void ipip_tunnel_stack (adj_index_t ai)
 
static adj_walk_rc_t ipip_adj_walk_cb (adj_index_t ai, void *ctx)
 
static void ipip_tunnel_restack (ipip_tunnel_t *gt)
 
static adj_midchain_fixup_t ipip_get_fixup (const ipip_tunnel_t *t, vnet_link_t lt, adj_flags_t *aflags)
 
void ipip_update_adj (vnet_main_t *vnm, u32 sw_if_index, adj_index_t ai)
 
static adj_walk_rc_t mipip_mk_complete_walk (adj_index_t ai, void *data)
 
static adj_walk_rc_t mipip_mk_incomplete_walk (adj_index_t ai, void *data)
 
void mipip_update_adj (vnet_main_t *vnm, u32 sw_if_index, adj_index_t ai)
 
static u8format_ipip_tunnel_name (u8 *s, va_list *args)
 
static u8format_ipip_device (u8 *s, va_list *args)
 
static clib_error_tipip_interface_admin_up_down (vnet_main_t *vnm, u32 hw_if_index, u32 flags)
 
static int ipip_tunnel_desc (u32 sw_if_index, ip46_address_t *src, ip46_address_t *dst, u8 *is_l2)
 
 VNET_DEVICE_CLASS (ipip_device_class)
 
 VNET_HW_INTERFACE_CLASS (ipip_hw_interface_class)
 
 VNET_HW_INTERFACE_CLASS (mipip_hw_interface_class)
 
ipip_tunnel_tipip_tunnel_db_find (const ipip_tunnel_key_t *key)
 
ipip_tunnel_tipip_tunnel_db_find_by_sw_if_index (u32 sw_if_index)
 
void ipip_tunnel_db_add (ipip_tunnel_t *t, const ipip_tunnel_key_t *key)
 
void ipip_tunnel_db_remove (ipip_tunnel_t *t, const ipip_tunnel_key_t *key)
 
void ipip_mk_key_i (ipip_transport_t transport, ipip_mode_t mode, const ip46_address_t *src, const ip46_address_t *dst, u32 fib_index, ipip_tunnel_key_t *key)
 
void ipip_mk_key (const ipip_tunnel_t *t, ipip_tunnel_key_t *key)
 
static void ipip_teib_mk_key (const ipip_tunnel_t *t, const teib_entry_t *ne, ipip_tunnel_key_t *key)
 
static void ipip_teib_entry_added (const teib_entry_t *ne)
 
static void ipip_teib_entry_deleted (const teib_entry_t *ne)
 
static walk_rc_t ipip_tunnel_delete_teib_walk (index_t nei, void *ctx)
 
static walk_rc_t ipip_tunnel_add_teib_walk (index_t nei, void *ctx)
 
int ipip_add_tunnel (ipip_transport_t transport, u32 instance, ip46_address_t *src, ip46_address_t *dst, u32 fib_index, tunnel_encap_decap_flags_t flags, ip_dscp_t dscp, tunnel_mode_t tmode, u32 *sw_if_indexp)
 
int ipip_del_tunnel (u32 sw_if_index)
 
static clib_error_tipip_init (vlib_main_t *vm)
 

Variables

ipip_main_t ipip_main
 
const static teib_vft_t ipip_teib_vft
 

Typedef Documentation

◆ mipip_walk_ctx_t

Function Documentation

◆ format_ipip_device()

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

Definition at line 469 of file ipip.c.

◆ format_ipip_tunnel_name()

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

Definition at line 455 of file ipip.c.

◆ format_ipip_tx_trace()

u8* format_ipip_tx_trace ( u8 s,
va_list *  args 
)

Definition at line 43 of file ipip.c.

◆ ipip44_fixup()

static void ipip44_fixup ( vlib_main_t vm,
const ip_adjacency_t adj,
vlib_buffer_t b,
const void *  data 
)
static

Definition at line 155 of file ipip.c.

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

◆ ipip46_fixup()

static void ipip46_fixup ( vlib_main_t vm,
const ip_adjacency_t adj,
vlib_buffer_t b,
const void *  data 
)
static

Definition at line 171 of file ipip.c.

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

◆ ipip64_fixup()

static void ipip64_fixup ( vlib_main_t vm,
const ip_adjacency_t adj,
vlib_buffer_t b,
const void *  data 
)
static

Definition at line 139 of file ipip.c.

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

◆ ipip66_fixup()

static void ipip66_fixup ( vlib_main_t vm,
const ip_adjacency_t adj,
vlib_buffer_t b,
const void *  data 
)
static

Definition at line 191 of file ipip.c.

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

◆ ipip_add_tunnel()

int ipip_add_tunnel ( ipip_transport_t  transport,
u32  instance,
ip46_address_t *  src,
ip46_address_t *  dst,
u32  fib_index,
tunnel_encap_decap_flags_t  flags,
ip_dscp_t  dscp,
tunnel_mode_t  tmode,
u32 sw_if_indexp 
)

Definition at line 722 of file ipip.c.

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

◆ ipip_adj_walk_cb()

static adj_walk_rc_t ipip_adj_walk_cb ( adj_index_t  ai,
void *  ctx 
)
static

Definition at line 287 of file ipip.c.

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

◆ ipip_build_rewrite()

static u8* ipip_build_rewrite ( vnet_main_t vnm,
u32  sw_if_index,
vnet_link_t  link_type,
const void *  dst_address 
)
static

Definition at line 57 of file ipip.c.

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

◆ ipip_del_tunnel()

int ipip_del_tunnel ( u32  sw_if_index)

Definition at line 832 of file ipip.c.

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

◆ ipip_get_fixup()

static adj_midchain_fixup_t ipip_get_fixup ( const ipip_tunnel_t t,
vnet_link_t  lt,
adj_flags_t aflags 
)
static

Definition at line 309 of file ipip.c.

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

◆ ipip_init()

static clib_error_t* ipip_init ( vlib_main_t vm)
static

Definition at line 864 of file ipip.c.

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

◆ ipip_interface_admin_up_down()

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

Definition at line 479 of file ipip.c.

+ Here is the call graph for this function:

◆ ipip_mk_key()

void ipip_mk_key ( const ipip_tunnel_t t,
ipip_tunnel_key_t *  key 
)

Definition at line 606 of file ipip.c.

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

◆ ipip_mk_key_i()

void ipip_mk_key_i ( ipip_transport_t  transport,
ipip_mode_t  mode,
const ip46_address_t *  src,
const ip46_address_t *  dst,
u32  fib_index,
ipip_tunnel_key_t *  key 
)

Definition at line 591 of file ipip.c.

+ Here is the caller graph for this function:

◆ ipip_teib_entry_added()

static void ipip_teib_entry_added ( const teib_entry_t ne)
static

Definition at line 627 of file ipip.c.

+ Here is the call graph for this function:

◆ ipip_teib_entry_deleted()

static void ipip_teib_entry_deleted ( const teib_entry_t ne)
static

Definition at line 664 of file ipip.c.

+ Here is the call graph for this function:

◆ ipip_teib_mk_key()

static void ipip_teib_mk_key ( const ipip_tunnel_t t,
const teib_entry_t ne,
ipip_tunnel_key_t *  key 
)
static

Definition at line 613 of file ipip.c.

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

◆ ipip_tunnel_add_teib_walk()

static walk_rc_t ipip_tunnel_add_teib_walk ( index_t  nei,
void *  ctx 
)
static

Definition at line 710 of file ipip.c.

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

◆ ipip_tunnel_db_add()

void ipip_tunnel_db_add ( ipip_tunnel_t t,
const ipip_tunnel_key_t *  key 
)

Definition at line 575 of file ipip.c.

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

◆ ipip_tunnel_db_find()

ipip_tunnel_t* ipip_tunnel_db_find ( const ipip_tunnel_key_t *  key)

Definition at line 551 of file ipip.c.

+ Here is the caller graph for this function:

◆ ipip_tunnel_db_find_by_sw_if_index()

ipip_tunnel_t* ipip_tunnel_db_find_by_sw_if_index ( u32  sw_if_index)

Definition at line 563 of file ipip.c.

+ Here is the caller graph for this function:

◆ ipip_tunnel_db_remove()

void ipip_tunnel_db_remove ( ipip_tunnel_t t,
const ipip_tunnel_key_t *  key 
)

Definition at line 583 of file ipip.c.

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

◆ ipip_tunnel_delete_teib_walk()

static walk_rc_t ipip_tunnel_delete_teib_walk ( index_t  nei,
void *  ctx 
)
static

Definition at line 698 of file ipip.c.

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

◆ ipip_tunnel_desc()

static int ipip_tunnel_desc ( u32  sw_if_index,
ip46_address_t *  src,
ip46_address_t *  dst,
u8 is_l2 
)
static

Definition at line 502 of file ipip.c.

+ Here is the call graph for this function:

◆ ipip_tunnel_restack()

static void ipip_tunnel_restack ( ipip_tunnel_t gt)
static

Definition at line 295 of file ipip.c.

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

◆ ipip_tunnel_stack()

static void ipip_tunnel_stack ( adj_index_t  ai)
static

Definition at line 252 of file ipip.c.

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

◆ ipip_update_adj()

void ipip_update_adj ( vnet_main_t vnm,
u32  sw_if_index,
adj_index_t  ai 
)

Definition at line 332 of file ipip.c.

+ Here is the call graph for this function:

◆ ipipm4_fixup()

static void ipipm4_fixup ( vlib_main_t vm,
const ip_adjacency_t adj,
vlib_buffer_t b,
const void *  data 
)
static

Definition at line 232 of file ipip.c.

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

◆ ipipm6_fixup()

static void ipipm6_fixup ( vlib_main_t vm,
const ip_adjacency_t adj,
vlib_buffer_t b,
const void *  data 
)
static

Definition at line 211 of file ipip.c.

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

◆ mipip_mk_complete_walk()

static adj_walk_rc_t mipip_mk_complete_walk ( adj_index_t  ai,
void *  data 
)
static

Definition at line 370 of file ipip.c.

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

◆ mipip_mk_incomplete_walk()

static adj_walk_rc_t mipip_mk_incomplete_walk ( adj_index_t  ai,
void *  data 
)
static

Definition at line 401 of file ipip.c.

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

◆ mipip_update_adj()

void mipip_update_adj ( vnet_main_t vnm,
u32  sw_if_index,
adj_index_t  ai 
)

Definition at line 418 of file ipip.c.

+ Here is the call graph for this function:

◆ VNET_DEVICE_CLASS()

VNET_DEVICE_CLASS ( ipip_device_class  )

◆ VNET_HW_INTERFACE_CLASS() [1/2]

VNET_HW_INTERFACE_CLASS ( ipip_hw_interface_class  )

◆ VNET_HW_INTERFACE_CLASS() [2/2]

VNET_HW_INTERFACE_CLASS ( mipip_hw_interface_class  )

Variable Documentation

◆ ipip_main

ipip_main_t ipip_main

Definition at line 31 of file ipip.c.

◆ ipip_teib_vft

const static teib_vft_t ipip_teib_vft
static
Initial value:
= {
.nv_added = ipip_teib_entry_added,
.nv_deleted = ipip_teib_entry_deleted,
}

Definition at line 858 of file ipip.c.

ipip_teib_entry_deleted
static void ipip_teib_entry_deleted(const teib_entry_t *ne)
Definition: ipip.c:664
ipip_teib_entry_added
static void ipip_teib_entry_added(const teib_entry_t *ne)
Definition: ipip.c:627