FD.io VPP  v19.08.3-2-gbabecb413
Vector Packet Processing
dhcp6_pd_client_cp.c File Reference
+ Include dependency graph for dhcp6_pd_client_cp.c:

Go to the source code of this file.

Data Structures

struct  prefix_info_t
 
struct  client_state_t
 
struct  dhcp6_pd_client_cp_main_t
 
struct  ip6_prefix_main_t
 
struct  ip6_address_info_t
 
struct  ip6_address_with_prefix_main_t
 

Macros

#define vl_typedefs   /* define message structures */
 
#define vl_endianfun   /* define message structures */
 
#define foreach_dhcp6_pd_client_cp_msg
 
#define vl_api_dhcp6_pd_client_enable_disable_t_print   vl_noop_handler
 
#define vl_api_ip6_add_del_address_using_prefix_t_print   vl_noop_handler
 
#define vl_msg_name_crc_list
 

Enumerations

enum  { DHCPV6_PD_EVENT_INTERRUPT, DHCPV6_PD_EVENT_DISABLE }
 

Functions

static_always_inline u32 active_prefix_index_by_prefix_group_index_get (u32 prefix_group_index)
 
static_always_inline void active_prefix_index_by_prefix_group_index_set (u32 prefix_group_index, u32 prefix_index)
 
static_always_inline u8 is_dhcpv6_pd_prefix (prefix_info_t *prefix_info)
 
static_always_inline void set_is_dhcpv6_pd_prefix (prefix_info_t *prefix_info, u8 value)
 
static void cp_ip6_address_prefix_add_del_handler (u32 prefix_index, u8 is_add)
 
static void notify_prefix_add_del (u32 prefix_index, u8 is_add)
 
static void send_client_message_start_stop (u32 sw_if_index, u32 server_index, u8 msg_type, prefix_info_t *prefix_list, u8 start)
 
static void interrupt_process (void)
 
static u32 ip6_enable (u32 sw_if_index)
 
static u8 ip6_prefixes_equal (ip6_address_t *prefix1, ip6_address_t *prefix2, u8 len)
 
static clib_error_tdhcp6_pd_reply_event_handler (vl_api_dhcp6_pd_reply_event_t *mp)
 
static prefix_info_tcreate_prefix_list (u32 sw_if_index)
 
 VNET_DHCP6_PD_REPLY_EVENT_FUNCTION (dhcp6_pd_reply_event_handler)
 
static uword dhcp6_pd_client_cp_process (vlib_main_t *vm, vlib_node_runtime_t *rt, vlib_frame_t *f)
 
static void disable_process (void)
 
static void enable_process (void)
 
static u32 cp_ip6_construct_address (ip6_address_info_t *address_info, u32 prefix_index, ip6_address_t *r_addr)
 
static void cp_ip6_address_add_del_now (ip6_address_info_t *address_info, u8 is_add)
 
static u32 cp_ip6_address_find_new_active_prefix (u32 prefix_group_index, u32 ignore_prefix_index)
 
static u32 prefix_group_find_or_create (const u8 *name, u8 create)
 
static int cp_ip6_address_add_del (u32 sw_if_index, const u8 *prefix_group, ip6_address_t address, u8 prefix_length, u8 is_add)
 
static void vl_api_ip6_add_del_address_using_prefix_t_handler (vl_api_ip6_add_del_address_using_prefix_t *mp)
 
static clib_error_tcp_ip6_address_add_del_command_function (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
 
static clib_error_tcp_ip6_addresses_show_command_function (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
 
static clib_error_tcp_ip6_prefixes_show_command_function (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
 
static clib_error_tip6_pd_clients_show_command_function (vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)
 
static int dhcp6_pd_client_enable_disable (u32 sw_if_index, const u8 *prefix_group, u8 enable)
 
static clib_error_tdhcp6_pd_client_enable_disable_command_fn (vlib_main_t *vm, unformat_input_t() *input, vlib_cli_command_t *cmd)
 
static void vl_api_dhcp6_pd_client_enable_disable_t_handler (vl_api_dhcp6_pd_client_enable_disable_t *mp)
 
static void setup_message_id_table (api_main_t *am)
 
static clib_error_tdhcp_pd_client_cp_init (vlib_main_t *vm)
 

Variables

static dhcp6_pd_client_cp_main_t dhcp6_pd_client_cp_main
 
static ip6_prefix_main_t ip6_prefix_main
 
static ip6_address_with_prefix_main_t ip6_address_with_prefix_main
 
vlib_node_registration_t dhcp6_pd_client_cp_process_node
 (constructor) VLIB_REGISTER_NODE (dhcp6_pd_client_cp_process_node) More...
 
static vlib_cli_command_t ip6_address_add_del_command
 (constructor) VLIB_CLI_COMMAND (ip6_address_add_del_command) More...
 
static vlib_cli_command_t ip6_addresses_show_command
 (constructor) VLIB_CLI_COMMAND (ip6_addresses_show_command) More...
 
static vlib_cli_command_t ip6_prefixes_show_command
 (constructor) VLIB_CLI_COMMAND (ip6_prefixes_show_command) More...
 
static vlib_cli_command_t ip6_pd_clients_show_command
 (constructor) VLIB_CLI_COMMAND (ip6_pd_clients_show_command) More...
 
static vlib_cli_command_t dhcp6_pd_client_enable_disable_command
 (constructor) VLIB_CLI_COMMAND (dhcp6_pd_client_enable_disable_command) More...
 

Macro Definition Documentation

◆ foreach_dhcp6_pd_client_cp_msg

#define foreach_dhcp6_pd_client_cp_msg
Value:
_(DHCP6_PD_CLIENT_ENABLE_DISABLE, dhcp6_pd_client_enable_disable) \
_(IP6_ADD_DEL_ADDRESS_USING_PREFIX, ip6_add_del_address_using_prefix)
static int dhcp6_pd_client_enable_disable(u32 sw_if_index, const u8 *prefix_group, u8 enable)

Definition at line 37 of file dhcp6_pd_client_cp.c.

◆ vl_api_dhcp6_pd_client_enable_disable_t_print

#define vl_api_dhcp6_pd_client_enable_disable_t_print   vl_noop_handler

Definition at line 41 of file dhcp6_pd_client_cp.c.

◆ vl_api_ip6_add_del_address_using_prefix_t_print

#define vl_api_ip6_add_del_address_using_prefix_t_print   vl_noop_handler

Definition at line 42 of file dhcp6_pd_client_cp.c.

◆ vl_endianfun

#define vl_endianfun   /* define message structures */

Definition at line 31 of file dhcp6_pd_client_cp.c.

◆ vl_msg_name_crc_list

#define vl_msg_name_crc_list

Definition at line 1370 of file dhcp6_pd_client_cp.c.

◆ vl_typedefs

#define vl_typedefs   /* define message structures */

Definition at line 27 of file dhcp6_pd_client_cp.c.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
DHCPV6_PD_EVENT_INTERRUPT 
DHCPV6_PD_EVENT_DISABLE 

Definition at line 112 of file dhcp6_pd_client_cp.c.

Function Documentation

◆ active_prefix_index_by_prefix_group_index_get()

static_always_inline u32 active_prefix_index_by_prefix_group_index_get ( u32  prefix_group_index)

Definition at line 119 of file dhcp6_pd_client_cp.c.

+ Here is the caller graph for this function:

◆ active_prefix_index_by_prefix_group_index_set()

static_always_inline void active_prefix_index_by_prefix_group_index_set ( u32  prefix_group_index,
u32  prefix_index 
)

Definition at line 131 of file dhcp6_pd_client_cp.c.

+ Here is the caller graph for this function:

◆ cp_ip6_address_add_del()

static int cp_ip6_address_add_del ( u32  sw_if_index,
const u8 prefix_group,
ip6_address_t  address,
u8  prefix_length,
u8  is_add 
)
static

Definition at line 872 of file dhcp6_pd_client_cp.c.

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

◆ cp_ip6_address_add_del_command_function()

static clib_error_t* cp_ip6_address_add_del_command_function ( vlib_main_t vm,
unformat_input_t input,
vlib_cli_command_t cmd 
)
static

Definition at line 957 of file dhcp6_pd_client_cp.c.

+ Here is the call graph for this function:

◆ cp_ip6_address_add_del_now()

static void cp_ip6_address_add_del_now ( ip6_address_info_t address_info,
u8  is_add 
)
static

Definition at line 676 of file dhcp6_pd_client_cp.c.

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

◆ cp_ip6_address_find_new_active_prefix()

static u32 cp_ip6_address_find_new_active_prefix ( u32  prefix_group_index,
u32  ignore_prefix_index 
)
static

Definition at line 762 of file dhcp6_pd_client_cp.c.

+ Here is the caller graph for this function:

◆ cp_ip6_address_prefix_add_del_handler()

static void cp_ip6_address_prefix_add_del_handler ( u32  prefix_index,
u8  is_add 
)
static

Definition at line 780 of file dhcp6_pd_client_cp.c.

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

◆ cp_ip6_addresses_show_command_function()

static clib_error_t* cp_ip6_addresses_show_command_function ( vlib_main_t vm,
unformat_input_t input,
vlib_cli_command_t cmd 
)
static

Definition at line 1035 of file dhcp6_pd_client_cp.c.

+ Here is the call graph for this function:

◆ cp_ip6_construct_address()

static u32 cp_ip6_construct_address ( ip6_address_info_t address_info,
u32  prefix_index,
ip6_address_t r_addr 
)
static

Definition at line 650 of file dhcp6_pd_client_cp.c.

+ Here is the caller graph for this function:

◆ cp_ip6_prefixes_show_command_function()

static clib_error_t* cp_ip6_prefixes_show_command_function ( vlib_main_t vm,
unformat_input_t input,
vlib_cli_command_t cmd 
)
static

Definition at line 1073 of file dhcp6_pd_client_cp.c.

+ Here is the call graph for this function:

◆ create_prefix_list()

static prefix_info_t* create_prefix_list ( u32  sw_if_index)
static

Definition at line 475 of file dhcp6_pd_client_cp.c.

+ Here is the caller graph for this function:

◆ dhcp6_pd_client_cp_process()

static uword dhcp6_pd_client_cp_process ( vlib_main_t vm,
vlib_node_runtime_t rt,
vlib_frame_t f 
)
static

Definition at line 499 of file dhcp6_pd_client_cp.c.

+ Here is the call graph for this function:

◆ dhcp6_pd_client_enable_disable()

static int dhcp6_pd_client_enable_disable ( u32  sw_if_index,
const u8 prefix_group,
u8  enable 
)
static

Definition at line 1178 of file dhcp6_pd_client_cp.c.

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

◆ dhcp6_pd_client_enable_disable_command_fn()

static clib_error_t* dhcp6_pd_client_enable_disable_command_fn ( vlib_main_t vm,
unformat_input_t() *  input,
vlib_cli_command_t cmd 
)
static

Definition at line 1279 of file dhcp6_pd_client_cp.c.

+ Here is the call graph for this function:

◆ dhcp6_pd_reply_event_handler()

static clib_error_t* dhcp6_pd_reply_event_handler ( vl_api_dhcp6_pd_reply_event_t mp)
static

Definition at line 290 of file dhcp6_pd_client_cp.c.

+ Here is the call graph for this function:

◆ dhcp_pd_client_cp_init()

static clib_error_t* dhcp_pd_client_cp_init ( vlib_main_t vm)
static

Definition at line 1383 of file dhcp6_pd_client_cp.c.

+ Here is the call graph for this function:

◆ disable_process()

static void disable_process ( void  )
static

Definition at line 627 of file dhcp6_pd_client_cp.c.

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

◆ enable_process()

static void enable_process ( void  )
static

Definition at line 637 of file dhcp6_pd_client_cp.c.

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

◆ interrupt_process()

static void interrupt_process ( void  )
static

Definition at line 617 of file dhcp6_pd_client_cp.c.

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

◆ ip6_enable()

static u32 ip6_enable ( u32  sw_if_index)
static

Definition at line 263 of file dhcp6_pd_client_cp.c.

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

◆ ip6_pd_clients_show_command_function()

static clib_error_t* ip6_pd_clients_show_command_function ( vlib_main_t vm,
unformat_input_t input,
vlib_cli_command_t cmd 
)
static

Definition at line 1111 of file dhcp6_pd_client_cp.c.

+ Here is the call graph for this function:

◆ ip6_prefixes_equal()

static u8 ip6_prefixes_equal ( ip6_address_t prefix1,
ip6_address_t prefix2,
u8  len 
)
static

Definition at line 274 of file dhcp6_pd_client_cp.c.

◆ is_dhcpv6_pd_prefix()

static_always_inline u8 is_dhcpv6_pd_prefix ( prefix_info_t prefix_info)

Definition at line 151 of file dhcp6_pd_client_cp.c.

+ Here is the call graph for this function:

◆ notify_prefix_add_del()

static void notify_prefix_add_del ( u32  prefix_index,
u8  is_add 
)
static

Definition at line 177 of file dhcp6_pd_client_cp.c.

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

◆ prefix_group_find_or_create()

static u32 prefix_group_find_or_create ( const u8 name,
u8  create 
)
static

Definition at line 840 of file dhcp6_pd_client_cp.c.

+ Here is the caller graph for this function:

◆ send_client_message_start_stop()

static void send_client_message_start_stop ( u32  sw_if_index,
u32  server_index,
u8  msg_type,
prefix_info_t prefix_list,
u8  start 
)
static

Definition at line 184 of file dhcp6_pd_client_cp.c.

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

◆ set_is_dhcpv6_pd_prefix()

static_always_inline void set_is_dhcpv6_pd_prefix ( prefix_info_t prefix_info,
u8  value 
)

Definition at line 162 of file dhcp6_pd_client_cp.c.

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

◆ setup_message_id_table()

static void setup_message_id_table ( api_main_t am)
static

Definition at line 1375 of file dhcp6_pd_client_cp.c.

+ Here is the caller graph for this function:

◆ vl_api_dhcp6_pd_client_enable_disable_t_handler()

static void vl_api_dhcp6_pd_client_enable_disable_t_handler ( vl_api_dhcp6_pd_client_enable_disable_t mp)
static

Definition at line 1351 of file dhcp6_pd_client_cp.c.

+ Here is the call graph for this function:

◆ vl_api_ip6_add_del_address_using_prefix_t_handler()

static void vl_api_ip6_add_del_address_using_prefix_t_handler ( vl_api_ip6_add_del_address_using_prefix_t mp)
static

Definition at line 932 of file dhcp6_pd_client_cp.c.

+ Here is the call graph for this function:

◆ VNET_DHCP6_PD_REPLY_EVENT_FUNCTION()

VNET_DHCP6_PD_REPLY_EVENT_FUNCTION ( dhcp6_pd_reply_event_handler  )

Variable Documentation

◆ dhcp6_pd_client_cp_main

dhcp6_pd_client_cp_main_t dhcp6_pd_client_cp_main
static

Definition at line 82 of file dhcp6_pd_client_cp.c.

◆ dhcp6_pd_client_cp_process_node

vlib_node_registration_t dhcp6_pd_client_cp_process_node
Initial value:
= {
.name = "dhcp6-pd-client-cp-process",
}
static uword dhcp6_pd_client_cp_process(vlib_main_t *vm, vlib_node_runtime_t *rt, vlib_frame_t *f)

(constructor) VLIB_REGISTER_NODE (dhcp6_pd_client_cp_process_node)

Definition at line 609 of file dhcp6_pd_client_cp.c.

◆ dhcp6_pd_client_enable_disable_command

vlib_cli_command_t dhcp6_pd_client_enable_disable_command
static
Initial value:
= {
.path = "dhcp6 pd client",
.short_help = "dhcp6 pd client <interface> (prefix group <string> | disable)",
}
static clib_error_t * dhcp6_pd_client_enable_disable_command_fn(vlib_main_t *vm, unformat_input_t() *input, vlib_cli_command_t *cmd)

(constructor) VLIB_CLI_COMMAND (dhcp6_pd_client_enable_disable_command)

Definition at line 1342 of file dhcp6_pd_client_cp.c.

◆ ip6_address_add_del_command

vlib_cli_command_t ip6_address_add_del_command
static
Initial value:
= {
.path = "set ip6 address",
.short_help = "set ip6 address <interface> [prefix group <string>] "
"<address> [del]",
}
static clib_error_t * cp_ip6_address_add_del_command_function(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)

(constructor) VLIB_CLI_COMMAND (ip6_address_add_del_command)

Definition at line 1026 of file dhcp6_pd_client_cp.c.

◆ ip6_address_with_prefix_main

ip6_address_with_prefix_main_t ip6_address_with_prefix_main
static

Definition at line 110 of file dhcp6_pd_client_cp.c.

◆ ip6_addresses_show_command

vlib_cli_command_t ip6_addresses_show_command
static
Initial value:
= {
.path = "show ip6 addresses",
.short_help = "show ip6 addresses",
}
static clib_error_t * cp_ip6_addresses_show_command_function(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)

(constructor) VLIB_CLI_COMMAND (ip6_addresses_show_command)

Definition at line 1065 of file dhcp6_pd_client_cp.c.

◆ ip6_pd_clients_show_command

vlib_cli_command_t ip6_pd_clients_show_command
static
Initial value:
= {
.path = "show ip6 pd clients",
.short_help = "show ip6 pd clients",
}
static clib_error_t * ip6_pd_clients_show_command_function(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)

(constructor) VLIB_CLI_COMMAND (ip6_pd_clients_show_command)

Definition at line 1170 of file dhcp6_pd_client_cp.c.

◆ ip6_prefix_main

ip6_prefix_main_t ip6_prefix_main
static

Definition at line 90 of file dhcp6_pd_client_cp.c.

◆ ip6_prefixes_show_command

vlib_cli_command_t ip6_prefixes_show_command
static
Initial value:
= {
.path = "show ip6 prefixes",
.short_help = "show ip6 prefixes",
}
static clib_error_t * cp_ip6_prefixes_show_command_function(vlib_main_t *vm, unformat_input_t *input, vlib_cli_command_t *cmd)

(constructor) VLIB_CLI_COMMAND (ip6_prefixes_show_command)

Definition at line 1103 of file dhcp6_pd_client_cp.c.