diff options
author | archie <archie@FreeBSD.org> | 1999-11-02 23:31:49 +0000 |
---|---|---|
committer | archie <archie@FreeBSD.org> | 1999-11-02 23:31:49 +0000 |
commit | ef92fd8274559bbe8abe33a3ef8a69ba13bbb52f (patch) | |
tree | 84a6c159f8b88576eb14e204d7475488a0574989 /sys/netgraph/ng_tee.h | |
parent | a481e1e52bd7ec5a593408ac4a14285997f6d2b9 (diff) | |
download | FreeBSD-src-ef92fd8274559bbe8abe33a3ef8a69ba13bbb52f.zip FreeBSD-src-ef92fd8274559bbe8abe33a3ef8a69ba13bbb52f.tar.gz |
Add statistics counters to "tee" netgraph node type.
Diffstat (limited to 'sys/netgraph/ng_tee.h')
-rw-r--r-- | sys/netgraph/ng_tee.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/sys/netgraph/ng_tee.h b/sys/netgraph/ng_tee.h index 96f2380..2c1959a 100644 --- a/sys/netgraph/ng_tee.h +++ b/sys/netgraph/ng_tee.h @@ -53,4 +53,26 @@ #define NG_TEE_HOOK_RIGHT2LEFT "right2left" #define NG_TEE_HOOK_LEFT2RIGHT "left2right" +/* Statistics structure for one hook */ +struct ng_tee_hookstat { + u_int64_t inOctets; + u_int64_t inFrames; + u_int64_t outOctets; + u_int64_t outFrames; +}; + +/* Statistics structure returned by NGM_TEE_GET_STATS */ +struct ng_tee_stats { + struct ng_tee_hookstat right; + struct ng_tee_hookstat left; + struct ng_tee_hookstat right2left; + struct ng_tee_hookstat left2right; +}; + +/* Netgraph commands */ +enum { + NGM_TEE_GET_STATS = 1, /* get stats */ + NGM_TEE_CLR_STATS, /* clear stats */ +}; + #endif /* _NETGRAPH_TEE_H_ */ |