FreeBSD kernel netgraph code
ng_split.c File Reference
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/errno.h>
#include <sys/kernel.h>
#include <sys/malloc.h>
#include <sys/mbuf.h>
#include <sys/sockio.h>
#include <sys/socket.h>
#include <sys/syslog.h>
#include <netgraph/ng_message.h>
#include <netgraph/netgraph.h>
#include <netgraph/ng_split.h>
Include dependency graph for ng_split.c:

Go to the source code of this file.

Data Structures

struct  ng_split_private
 

Typedefs

typedef struct ng_split_privatepriv_p
 

Functions

 NETGRAPH_INIT (ng_split, &typestruct)
 
static int ng_split_constructor (node_p node)
 
static int ng_split_newhook (node_p node, hook_p hook, const char *name)
 
static int ng_split_rcvdata (hook_p hook, item_p item)
 
static int ng_split_shutdown (node_p node)
 
static int ng_split_disconnect (hook_p hook)
 

Variables

static ng_constructor_t ng_split_constructor
 
static ng_shutdown_t ng_split_shutdown
 
static ng_newhook_t ng_split_newhook
 
static ng_rcvdata_t ng_split_rcvdata
 
static ng_disconnect_t ng_split_disconnect
 
static struct ng_type typestruct
 

Typedef Documentation

◆ priv_p

typedef struct ng_split_private* priv_p

Definition at line 74 of file ng_split.c.

Function Documentation

◆ NETGRAPH_INIT()

NETGRAPH_INIT ( ng_split  ,
typestruct 
)

◆ ng_split_constructor()

static int ng_split_constructor ( node_p  node)
static

Definition at line 84 of file ng_split.c.

References NG_NODE_SET_PRIVATE, and ng_split_private::node.

◆ ng_split_disconnect()

static int ng_split_disconnect ( hook_p  hook)
static

Definition at line 166 of file ng_split.c.

References NG_HOOK_NODE, NG_HOOK_PRIVATE, NG_NODE_IS_VALID, NG_NODE_NUMHOOKS, and ng_rmnode_self().

Here is the call graph for this function:

◆ ng_split_newhook()

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

◆ ng_split_rcvdata()

static int ng_split_rcvdata ( hook_p  hook,
item_p  item 
)
static

Definition at line 129 of file ng_split.c.

References NG_FREE_ITEM, NG_FWD_ITEM_HOOK, NG_HOOK_NODE, and NG_NODE_PRIVATE.

◆ ng_split_shutdown()

static int ng_split_shutdown ( node_p  node)
static

Variable Documentation

◆ ng_split_constructor

ng_constructor_t ng_split_constructor
static

Definition at line 49 of file ng_split.c.

◆ ng_split_disconnect

ng_disconnect_t ng_split_disconnect
static

Definition at line 53 of file ng_split.c.

◆ ng_split_newhook

ng_newhook_t ng_split_newhook
static

Definition at line 51 of file ng_split.c.

◆ ng_split_rcvdata

ng_rcvdata_t ng_split_rcvdata
static

Definition at line 52 of file ng_split.c.

◆ ng_split_shutdown

ng_shutdown_t ng_split_shutdown
static

Definition at line 50 of file ng_split.c.

◆ typestruct

struct ng_type typestruct
static
Initial value:
= {
.version = NG_ABI_VERSION,
.constructor = ng_split_constructor,
.shutdown = ng_split_shutdown,
.newhook = ng_split_newhook,
.rcvdata = ng_split_rcvdata,
.disconnect = ng_split_disconnect,
}
#define NG_ABI_VERSION
Definition: netgraph.h:77
static ng_disconnect_t ng_split_disconnect
Definition: ng_split.c:53
static ng_shutdown_t ng_split_shutdown
Definition: ng_split.c:50
static ng_rcvdata_t ng_split_rcvdata
Definition: ng_split.c:52
static ng_newhook_t ng_split_newhook
Definition: ng_split.c:51
static ng_constructor_t ng_split_constructor
Definition: ng_split.c:49
#define NG_SPLIT_NODE_TYPE
Definition: ng_split.h:37

Definition at line 56 of file ng_split.c.