OpenSDN source code
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
gmph_private.h File Reference

Go to the source code of this file.

Classes

struct  gmph_instance_
 
struct  gmph_intf_
 
struct  gmph_rpt_msg_addr_entry_
 
struct  gmph_group_
 
struct  gmph_group_set_context_
 
struct  gmph_client_
 
struct  gmph_client_group_key_
 
struct  gmph_client_group_
 

Macros

#define GMPH_INSTANCE_MAGIC   0x48696E73 /* 'Hins' */
 
#define GMPH_INITIAL_REPORT_JITTER   0 /* Percent jitter for initial packet */
 
#define GMPH_REPORT_REXMIT_JITTER   100 /* Percent jitter for retransmission */
 
#define GMPH_QUERY_REPLY_JITTER   100 /* Percent jitter for replies */
 
#define GMPH_CLIENT_MAGIC   0x48636A69 /* 'Hcli' */
 
#define client_group_intf_id   client_group_key.group_key_intf_id
 
#define client_group_addr   client_group_key.group_key_addr
 

Typedefs

typedef struct gmph_instance_ gmph_instance
 
typedef struct gmph_intf_ gmph_intf
 
typedef struct
gmph_rpt_msg_addr_entry_ 
gmph_rpt_msg_addr_entry
 
typedef struct gmph_group_ gmph_group
 
typedef struct
gmph_group_set_context_ 
gmph_group_set_context
 
typedef struct gmph_client_ gmph_client
 
typedef struct
gmph_client_group_key_ 
gmph_client_group_key
 
typedef struct gmph_client_group_ gmph_client_group
 

Enumerations

enum  gmph_report_type { GMP_CHANGE_RECORD, GMP_CURRENT_STATE }
 

Functions

 THREAD_TO_STRUCT (gmph_thread_to_instance, gmph_instance, hinst_thread)
 
 GMPX_PATNODE_TO_STRUCT (gmph_inst_patnode_to_intf, gmph_intf, hintf_inst_patnode)
 
 GMPX_PATNODE_TO_STRUCT (gmph_global_patnode_to_intf, gmph_intf, hintf_global_patnode)
 
 EMBEDDED_STRUCT_TO_STRUCT (gmph_addr_list_to_group_list, gmph_rpt_msg_addr_entry, gmp_addr_list_entry, msg_addr_entry)
 
 GMPX_PATNODE_TO_STRUCT (gmph_intf_patnode_to_group, gmph_group, hgroup_intf_patnode)
 
 THREAD_TO_STRUCT (gmph_xmit_thread_to_group, gmph_group, hgroup_xmit_thread)
 
 THREAD_TO_STRUCT (gmph_thread_to_client, gmph_client, hclient_thread)
 
 GMPX_PATNODE_TO_STRUCT (gmph_patnode_to_client_group, gmph_client_group, client_group_node)
 
 THREAD_TO_STRUCT (gmph_thread_to_client_group, gmph_client_group, client_group_thread)
 
static u_int gmph_client_group_key_len (gmph_instance *instance)
 
static boolean gmph_group_is_active (gmph_group *group)
 
static boolean gmph_intf_shutting_down (gmph_intf *intf)
 
gmph_instancegmph_instance_create (gmp_proto proto, void *inst_context)
 
gmph_instancegmph_get_instance (gmp_instance_id instance_id)
 
void gmph_instance_destroy (gmph_instance *instance)
 
gmph_clientgmph_create_client (gmph_instance *instance)
 
gmph_clientgmph_get_client (gmp_client_id client_id)
 
void gmph_destroy_client (gmph_client *client)
 
gmph_client_groupgmph_lookup_client_group (gmph_client *client, gmpx_intf_id intf_id, const u_int8_t *group)
 
void gmph_destroy_client_group (gmph_client_group *client_group, boolean evaluate_group)
 
void gmph_destroy_intf_client_groups (gmph_client *client, gmph_intf *intf)
 
gmph_client_groupgmph_create_client_group (gmph_intf *intf, gmph_client *client, gmph_group *group, const u_int8_t *group_addr, gmp_filter_mode filter_mode, gmp_addr_thread *addr_thread)
 
void gmph_destroy_group_client_groups (gmph_group *group)
 
void gmph_destroy_instance_clients (gmph_instance *instance)
 
void gmph_intf_evaluate_version (gmph_intf *intf)
 
gmph_intfgmph_intf_lookup (gmph_instance *instance, gmpx_intf_id intf_id)
 
gmph_intfgmph_intf_lookup_global (gmp_proto proto, gmpx_intf_id intf_id)
 
void gmph_kick_xmit (gmph_intf *intf)
 
int gmph_attach_intf_internal (gmph_instance *instance, gmpx_intf_id intf_id)
 
int gmph_detach_intf_internal (gmph_instance *instance, gmpx_intf_id intf_id, gmph_soft_detach_callback callback, void *context)
 
void gmph_attempt_intf_free (gmph_intf *intf)
 
void gmph_destroy_instance_intfs (gmph_instance *instance)
 
void gmph_start_general_query_timer (gmph_intf *intf, u_int32_t ivl, u_int jitter_pct)
 
void gmph_intf_increment_pending_xmit_count (gmph_intf *)
 
void gmph_intf_decrement_pending_xmit_count (gmph_intf *)
 
int gmph_reevaluate_group (gmph_group *group)
 
gmph_groupgmph_group_lookup_create (gmph_intf *, const u_int8_t *group)
 
gmph_groupgmph_group_lookup (gmph_intf *intf, const u_int8_t *group)
 
gmph_groupgmph_group_lookup_first (gmph_intf *intf)
 
gmph_groupgmph_group_create (gmph_intf *intf, const u_int8_t *group)
 
gmpx_timergmph_create_change_report_timer (gmph_group *group)
 
gmph_groupgmph_first_group_xmit (gmph_intf *intf)
 
gmph_groupgmph_next_group_xmit (gmph_group *group)
 
void gmph_dequeue_group_xmit (gmph_group *group)
 
void gmph_delete_rpt_addr_entry (gmph_rpt_msg_addr_entry *report_entry)
 
void gmph_attempt_group_free (gmph_group *group)
 
void gmph_destroy_intf_groups (gmph_intf *intf)
 
void gmph_enqueue_group_xmit (gmph_group *group)
 
boolean gmph_group_xmit_pending (gmph_group *group)
 
void gmph_set_report_entry_rexmit (gmph_group *group, gmp_addr_list_entry *addr_entry)
 
boolean gmph_group_source_requested (gmph_group *group, const u_int8_t *source_addr)
 
void gmph_mark_pending_group_xmit (gmph_group *group)
 
void gmph_unmark_pending_group_xmit (gmph_group *group, boolean force)
 
void gmph_start_change_rpt_timer (gmph_group *group, u_int32_t ivl, u_int jitter_pct)
 
void gmph_start_query_timer (gmph_group *group, u_int32_t ivl, u_int jitter_pct)
 
void gmph_lock_group (gmph_group *group)
 
boolean gmph_unlock_group (gmph_group *group)
 
void gmph_register_packet_handler (void)
 
void gmph_version_changed (gmph_instance *instance, gmph_intf *intf)
 
void gmph_group_general_query_timer_expiry (gmph_group *group)
 
void gmph_group_change_report_timer_expiry (gmpx_timer *timer, void *context)
 
void gmph_group_query_timer_expiry (gmpx_timer *timer, void *context)
 

Variables

gmpx_block_tag gmph_instance_tag
 
gmpx_block_tag gmph_client_tag
 
gmpx_block_tag gmph_intf_tag
 
gmpx_block_tag gmph_group_tag
 
gmpx_block_tag gmph_group_rpt_entry_tag
 
gmpx_block_tag gmph_client_group_tag
 
gmpx_block_tag gmph_client_group_thread_tag
 
task_thread gmph_global_instance_thread
 
gmpx_patrootgmph_global_intf_tree []
 

Macro Definition Documentation

#define client_group_addr   client_group_key.group_key_addr

Definition at line 349 of file gmph_private.h.

#define client_group_intf_id   client_group_key.group_key_intf_id

Definition at line 348 of file gmph_private.h.

#define GMPH_CLIENT_MAGIC   0x48636A69 /* 'Hcli' */

Definition at line 312 of file gmph_private.h.

#define GMPH_INITIAL_REPORT_JITTER   0 /* Percent jitter for initial packet */

Definition at line 277 of file gmph_private.h.

#define GMPH_INSTANCE_MAGIC   0x48696E73 /* 'Hins' */

Definition at line 46 of file gmph_private.h.

#define GMPH_QUERY_REPLY_JITTER   100 /* Percent jitter for replies */

Definition at line 279 of file gmph_private.h.

#define GMPH_REPORT_REXMIT_JITTER   100 /* Percent jitter for retransmission */

Definition at line 278 of file gmph_private.h.

Typedef Documentation

typedef struct gmph_client_ gmph_client
typedef struct gmph_group_ gmph_group
typedef struct gmph_instance_ gmph_instance
typedef struct gmph_intf_ gmph_intf

Enumeration Type Documentation

Enumerator
GMP_CHANGE_RECORD 
GMP_CURRENT_STATE 

Definition at line 51 of file gmph_private.h.

Function Documentation

EMBEDDED_STRUCT_TO_STRUCT ( gmph_addr_list_to_group_list  ,
gmph_rpt_msg_addr_entry  ,
gmp_addr_list_entry  ,
msg_addr_entry   
)
int gmph_attach_intf_internal ( gmph_instance instance,
gmpx_intf_id  intf_id 
)
void gmph_attempt_group_free ( gmph_group group)
void gmph_attempt_intf_free ( gmph_intf intf)
static u_int gmph_client_group_key_len ( gmph_instance instance)
inlinestatic

Definition at line 359 of file gmph_private.h.

gmpx_timer* gmph_create_change_report_timer ( gmph_group group)
gmph_client* gmph_create_client ( gmph_instance instance)
gmph_client_group* gmph_create_client_group ( gmph_intf intf,
gmph_client client,
gmph_group group,
const u_int8_t *  group_addr,
gmp_filter_mode  filter_mode,
gmp_addr_thread addr_thread 
)
void gmph_delete_rpt_addr_entry ( gmph_rpt_msg_addr_entry report_entry)
void gmph_dequeue_group_xmit ( gmph_group group)
void gmph_destroy_client ( gmph_client client)
void gmph_destroy_client_group ( gmph_client_group client_group,
boolean  evaluate_group 
)
void gmph_destroy_group_client_groups ( gmph_group group)
void gmph_destroy_instance_clients ( gmph_instance instance)
void gmph_destroy_instance_intfs ( gmph_instance instance)
void gmph_destroy_intf_client_groups ( gmph_client client,
gmph_intf intf 
)
void gmph_destroy_intf_groups ( gmph_intf intf)
int gmph_detach_intf_internal ( gmph_instance instance,
gmpx_intf_id  intf_id,
gmph_soft_detach_callback  callback,
void *  context 
)
void gmph_enqueue_group_xmit ( gmph_group group)
gmph_group* gmph_first_group_xmit ( gmph_intf intf)
gmph_client* gmph_get_client ( gmp_client_id  client_id)
gmph_instance* gmph_get_instance ( gmp_instance_id  instance_id)
void gmph_group_change_report_timer_expiry ( gmpx_timer timer,
void *  context 
)
gmph_group* gmph_group_create ( gmph_intf intf,
const u_int8_t *  group 
)
void gmph_group_general_query_timer_expiry ( gmph_group group)
static boolean gmph_group_is_active ( gmph_group group)
inlinestatic

Definition at line 379 of file gmph_private.h.

Here is the call graph for this function:

gmph_group* gmph_group_lookup ( gmph_intf intf,
const u_int8_t *  group 
)
gmph_group* gmph_group_lookup_create ( gmph_intf ,
const u_int8_t *  group 
)
gmph_group* gmph_group_lookup_first ( gmph_intf intf)
void gmph_group_query_timer_expiry ( gmpx_timer timer,
void *  context 
)
boolean gmph_group_source_requested ( gmph_group group,
const u_int8_t *  source_addr 
)
boolean gmph_group_xmit_pending ( gmph_group group)
gmph_instance* gmph_instance_create ( gmp_proto  proto,
void *  inst_context 
)
void gmph_instance_destroy ( gmph_instance instance)
void gmph_intf_decrement_pending_xmit_count ( gmph_intf )
void gmph_intf_evaluate_version ( gmph_intf intf)
void gmph_intf_increment_pending_xmit_count ( gmph_intf )
gmph_intf* gmph_intf_lookup ( gmph_instance instance,
gmpx_intf_id  intf_id 
)
gmph_intf* gmph_intf_lookup_global ( gmp_proto  proto,
gmpx_intf_id  intf_id 
)
static boolean gmph_intf_shutting_down ( gmph_intf intf)
inlinestatic

Definition at line 402 of file gmph_private.h.

void gmph_kick_xmit ( gmph_intf intf)
void gmph_lock_group ( gmph_group group)
gmph_client_group* gmph_lookup_client_group ( gmph_client client,
gmpx_intf_id  intf_id,
const u_int8_t *  group 
)
void gmph_mark_pending_group_xmit ( gmph_group group)
gmph_group* gmph_next_group_xmit ( gmph_group group)
int gmph_reevaluate_group ( gmph_group group)
void gmph_register_packet_handler ( void  )
void gmph_set_report_entry_rexmit ( gmph_group group,
gmp_addr_list_entry addr_entry 
)
void gmph_start_change_rpt_timer ( gmph_group group,
u_int32_t  ivl,
u_int  jitter_pct 
)
void gmph_start_general_query_timer ( gmph_intf intf,
u_int32_t  ivl,
u_int  jitter_pct 
)
void gmph_start_query_timer ( gmph_group group,
u_int32_t  ivl,
u_int  jitter_pct 
)
boolean gmph_unlock_group ( gmph_group group)
void gmph_unmark_pending_group_xmit ( gmph_group group,
boolean  force 
)
void gmph_version_changed ( gmph_instance instance,
gmph_intf intf 
)
GMPX_PATNODE_TO_STRUCT ( gmph_inst_patnode_to_intf  ,
gmph_intf  ,
hintf_inst_patnode   
)
GMPX_PATNODE_TO_STRUCT ( gmph_global_patnode_to_intf  ,
gmph_intf  ,
hintf_global_patnode   
)
GMPX_PATNODE_TO_STRUCT ( gmph_intf_patnode_to_group  ,
gmph_group  ,
hgroup_intf_patnode   
)
GMPX_PATNODE_TO_STRUCT ( gmph_patnode_to_client_group  ,
gmph_client_group  ,
client_group_node   
)
THREAD_TO_STRUCT ( gmph_thread_to_instance  ,
gmph_instance  ,
hinst_thread   
)
THREAD_TO_STRUCT ( gmph_xmit_thread_to_group  ,
gmph_group  ,
hgroup_xmit_thread   
)
THREAD_TO_STRUCT ( gmph_thread_to_client  ,
gmph_client  ,
hclient_thread   
)
THREAD_TO_STRUCT ( gmph_thread_to_client_group  ,
gmph_client_group  ,
client_group_thread   
)

Variable Documentation

gmpx_block_tag gmph_client_group_tag
gmpx_block_tag gmph_client_group_thread_tag
gmpx_block_tag gmph_client_tag
task_thread gmph_global_instance_thread
gmpx_patroot* gmph_global_intf_tree[]
gmpx_block_tag gmph_group_rpt_entry_tag
gmpx_block_tag gmph_group_tag
gmpx_block_tag gmph_instance_tag
gmpx_block_tag gmph_intf_tag