FreeBSD kernel netgraph code
ng_one2many.c File Reference
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/kernel.h>
#include <sys/malloc.h>
#include <sys/ctype.h>
#include <sys/mbuf.h>
#include <sys/errno.h>
#include <netgraph/ng_message.h>
#include <netgraph/netgraph.h>
#include <netgraph/ng_parse.h>
#include <netgraph/ng_one2many.h>
Include dependency graph for ng_one2many.c:

Go to the source code of this file.

Data Structures

struct  ng_one2many_link
 
struct  ng_one2many_private
 

Typedefs

typedef struct ng_one2many_privatepriv_p
 

Functions

static void ng_one2many_update_many (priv_p priv)
 
static void ng_one2many_notify (priv_p priv, uint32_t cmd)
 
 NETGRAPH_INIT (one2many, &ng_one2many_typestruct)
 
static int ng_one2many_constructor (node_p node)
 
static int ng_one2many_newhook (node_p node, hook_p hook, const char *name)
 
static int ng_one2many_rcvmsg (node_p node, item_p item, hook_p lasthook)
 
static int ng_one2many_rcvdata (hook_p hook, item_p item)
 
static int ng_one2many_shutdown (node_p node)
 
static int ng_one2many_disconnect (hook_p hook)
 

Variables

static ng_constructor_t ng_one2many_constructor
 
static ng_rcvmsg_t ng_one2many_rcvmsg
 
static ng_shutdown_t ng_one2many_shutdown
 
static ng_newhook_t ng_one2many_newhook
 
static ng_rcvdata_t ng_one2many_rcvdata
 
static ng_disconnect_t ng_one2many_disconnect
 
static const struct ng_parse_fixedarray_info ng_one2many_enableLinks_array_type_info
 
static const struct ng_parse_type ng_one2many_enableLinks_array_type
 
static const struct ng_parse_struct_field ng_one2many_config_type_fields [] = NG_ONE2MANY_CONFIG_TYPE_INFO(&ng_one2many_enableLinks_array_type)
 
static const struct ng_parse_type ng_one2many_config_type
 
static const struct ng_parse_struct_field ng_one2many_link_stats_type_fields [] = NG_ONE2MANY_LINK_STATS_TYPE_INFO
 
static const struct ng_parse_type ng_one2many_link_stats_type
 
static const struct ng_cmdlist ng_one2many_cmdlist []
 
static struct ng_type ng_one2many_typestruct
 

Typedef Documentation

◆ priv_p

typedef struct ng_one2many_private* priv_p

Definition at line 80 of file ng_one2many.c.

Function Documentation

◆ NETGRAPH_INIT()

NETGRAPH_INIT ( one2many  ,
ng_one2many_typestruct 
)

◆ ng_one2many_constructor()

static int ng_one2many_constructor ( node_p  node)
static

◆ ng_one2many_disconnect()

static int ng_one2many_disconnect ( hook_p  hook)
static

◆ ng_one2many_newhook()

static int ng_one2many_newhook ( node_p  node,
hook_p  hook,
const char *  name 
)
static

◆ ng_one2many_notify()

static void ng_one2many_notify ( priv_p  priv,
uint32_t  cmd 
)
static

Definition at line 601 of file ng_one2many.c.

References NG_MKMESSAGE, NG_SEND_MSG_HOOK, and NGM_FLOW_COOKIE.

Referenced by ng_one2many_update_many().

Here is the caller graph for this function:

◆ ng_one2many_rcvdata()

◆ ng_one2many_rcvmsg()

◆ ng_one2many_shutdown()

static int ng_one2many_shutdown ( node_p  node)
static

Definition at line 500 of file ng_one2many.c.

References NG_NODE_PRIVATE, NG_NODE_SET_PRIVATE, and NG_NODE_UNREF.

◆ ng_one2many_update_many()

static void ng_one2many_update_many ( priv_p  priv)
static

Variable Documentation

◆ ng_one2many_cmdlist

const struct ng_cmdlist ng_one2many_cmdlist[]
static

Definition at line 124 of file ng_one2many.c.

◆ ng_one2many_config_type

const struct ng_parse_type ng_one2many_config_type
static
Initial value:
= {
}
static const struct ng_parse_struct_field ng_one2many_config_type_fields[]
Definition: ng_one2many.c:109
const struct ng_parse_type ng_parse_struct_type
Definition: ng_parse.c:222

Definition at line 110 of file ng_one2many.c.

◆ ng_one2many_config_type_fields

const struct ng_parse_struct_field ng_one2many_config_type_fields[] = NG_ONE2MANY_CONFIG_TYPE_INFO(&ng_one2many_enableLinks_array_type)
static

Definition at line 108 of file ng_one2many.c.

◆ ng_one2many_constructor

ng_constructor_t ng_one2many_constructor
static

Definition at line 83 of file ng_one2many.c.

◆ ng_one2many_disconnect

ng_disconnect_t ng_one2many_disconnect
static

Definition at line 88 of file ng_one2many.c.

◆ ng_one2many_enableLinks_array_type

const struct ng_parse_type ng_one2many_enableLinks_array_type
static
Initial value:
= {
}
static const struct ng_parse_fixedarray_info ng_one2many_enableLinks_array_type_info
Definition: ng_one2many.c:100
const struct ng_parse_type ng_parse_fixedarray_type
Definition: ng_parse.c:271

Definition at line 104 of file ng_one2many.c.

◆ ng_one2many_enableLinks_array_type_info

const struct ng_parse_fixedarray_info ng_one2many_enableLinks_array_type_info
static
Initial value:
= {
}
#define NG_ONE2MANY_MAX_LINKS
Definition: ng_one2many.h:56
const struct ng_parse_type ng_parse_uint8_type
Definition: ng_parse.c:413

Definition at line 100 of file ng_one2many.c.

◆ ng_one2many_link_stats_type

const struct ng_parse_type ng_one2many_link_stats_type
static
Initial value:
= {
}
static const struct ng_parse_struct_field ng_one2many_link_stats_type_fields[]
Definition: ng_one2many.c:117

Definition at line 118 of file ng_one2many.c.

◆ ng_one2many_link_stats_type_fields

const struct ng_parse_struct_field ng_one2many_link_stats_type_fields[] = NG_ONE2MANY_LINK_STATS_TYPE_INFO
static

Definition at line 116 of file ng_one2many.c.

◆ ng_one2many_newhook

ng_newhook_t ng_one2many_newhook
static

Definition at line 86 of file ng_one2many.c.

◆ ng_one2many_rcvdata

ng_rcvdata_t ng_one2many_rcvdata
static

Definition at line 87 of file ng_one2many.c.

◆ ng_one2many_rcvmsg

ng_rcvmsg_t ng_one2many_rcvmsg
static

Definition at line 84 of file ng_one2many.c.

◆ ng_one2many_shutdown

ng_shutdown_t ng_one2many_shutdown
static

Definition at line 85 of file ng_one2many.c.

◆ ng_one2many_typestruct

struct ng_type ng_one2many_typestruct
static
Initial value:
= {
.version = NG_ABI_VERSION,
.constructor = ng_one2many_constructor,
.rcvmsg = ng_one2many_rcvmsg,
.shutdown = ng_one2many_shutdown,
.newhook = ng_one2many_newhook,
.rcvdata = ng_one2many_rcvdata,
.disconnect = ng_one2many_disconnect,
.cmdlist = ng_one2many_cmdlist,
}
#define NG_ABI_VERSION
Definition: netgraph.h:77
static ng_constructor_t ng_one2many_constructor
Definition: ng_one2many.c:83
static ng_newhook_t ng_one2many_newhook
Definition: ng_one2many.c:86
static ng_shutdown_t ng_one2many_shutdown
Definition: ng_one2many.c:85
static ng_rcvmsg_t ng_one2many_rcvmsg
Definition: ng_one2many.c:84
static ng_rcvdata_t ng_one2many_rcvdata
Definition: ng_one2many.c:87
static ng_disconnect_t ng_one2many_disconnect
Definition: ng_one2many.c:88
static const struct ng_cmdlist ng_one2many_cmdlist[]
Definition: ng_one2many.c:124
#define NG_ONE2MANY_NODE_TYPE
Definition: ng_one2many.h:47

Definition at line 164 of file ng_one2many.c.