summaryrefslogtreecommitdiffstats
path: root/sys/netgraph/ng_one2many.h
diff options
context:
space:
mode:
authorjulian <julian@FreeBSD.org>2001-01-28 15:37:06 +0000
committerjulian <julian@FreeBSD.org>2001-01-28 15:37:06 +0000
commit501d5b3f2033d0054d7b9b6d70d20d959ce74f02 (patch)
treebab247e05a8e2e5a2a1a19c92ecda16435148102 /sys/netgraph/ng_one2many.h
parentba9a1fe1a95e88cca498b342048056405f5022b7 (diff)
downloadFreeBSD-src-501d5b3f2033d0054d7b9b6d70d20d959ce74f02.zip
FreeBSD-src-501d5b3f2033d0054d7b9b6d70d20d959ce74f02.tar.gz
Add a new distribution algorythm to the 'one2many' node type.
The new method is 'flood' (in addition to the old round-robin) in which incoming packets are sent to more than one outgoing hook. (I'm not sure what Rogier is using this for but it seems generally useful and isn't much extra) Submitted by: Rogier R. Mulhuijzen (drwilco@drwilco.net )
Diffstat (limited to 'sys/netgraph/ng_one2many.h')
-rw-r--r--sys/netgraph/ng_one2many.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/netgraph/ng_one2many.h b/sys/netgraph/ng_one2many.h
index 79d45b3..a83e8b0 100644
--- a/sys/netgraph/ng_one2many.h
+++ b/sys/netgraph/ng_one2many.h
@@ -59,6 +59,7 @@
/* Algorithms for outgoing packet distribution (XXX only one so far) */
#define NG_ONE2MANY_XMIT_ROUNDROBIN 1 /* round-robin delivery */
+#define NG_ONE2MANY_XMIT_ALL 2 /* send packets to all many hooks */
/* Algorithms for detecting link failure (XXX only one so far) */
#define NG_ONE2MANY_FAIL_MANUAL 1 /* use enabledLinks[] array */
@@ -86,6 +87,7 @@ struct ng_one2many_link_stats {
u_int64_t recvPackets; /* total pkts rec'd on link */
u_int64_t xmitOctets; /* total octets xmit'd on link */
u_int64_t xmitPackets; /* total pkts xmit'd on link */
+ u_int64_t memoryFailures; /* times couldn't get mem or mbuf */
};
/* Keep this in sync with the above structure definition */
@@ -95,6 +97,7 @@ struct ng_one2many_link_stats {
{ "recvPackets", &ng_parse_uint64_type }, \
{ "xmitOctets", &ng_parse_uint64_type }, \
{ "xmitPackets", &ng_parse_uint64_type }, \
+ { "memoryFailures", &ng_parse_uint64_type }, \
{ NULL } \
} \
}
OpenPOWER on IntegriCloud