diff options
| author | Marko Zec <zec@FreeBSD.org> | 2008-10-02 15:37:58 +0000 |
|---|---|---|
| committer | Marko Zec <zec@FreeBSD.org> | 2008-10-02 15:37:58 +0000 |
| commit | 8b615593fc0d78ef8366c1328f5966256b82a9c0 (patch) | |
| tree | 53fef93d1ff076abec439159e0a765427992dee1 /sys/netgraph/netgraph.h | |
| parent | 04ec403dd815bd3731dbf7da040759cd16271e3c (diff) | |
Notes
Diffstat (limited to 'sys/netgraph/netgraph.h')
| -rw-r--r-- | sys/netgraph/netgraph.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/sys/netgraph/netgraph.h b/sys/netgraph/netgraph.h index 53fab56a9b9c..1fc0b19fdf4c 100644 --- a/sys/netgraph/netgraph.h +++ b/sys/netgraph/netgraph.h @@ -1184,4 +1184,23 @@ typedef void *meta_p; #define NGI_GET_META(i,m) #define ng_copy_meta(meta) NULL +/* Hash related definitions */ +#define NG_ID_HASH_SIZE 128 /* most systems wont need even this many */ + +/* Virtualization macros */ +#define INIT_VNET_NETGRAPH(vnet) \ + INIT_FROM_VNET(vnet, VNET_MOD_NETGRAPH, \ + struct vnet_netgraph, vnet_netgraph) + +#define VNET_NETGRAPH(sym) VSYM(vnet_netgraph, sym) + +/* Symbol translation macros */ +#define V_nextID VNET_NETGRAPH(nextID) +#define V_ng_ID_hash VNET_NETGRAPH(ng_ID_hash) +#define V_ng_eiface_unit VNET_NETGRAPH(ng_eiface_unit) +#define V_ng_iface_unit VNET_NETGRAPH(ng_iface_unit) +#define V_ng_name_hash VNET_NETGRAPH(ng_name_hash) +#define V_ng_nodelist VNET_NETGRAPH(ng_nodelist) +#define V_ng_wormhole_unit VNET_NETGRAPH(ng_wormhole_unit) + #endif /* _NETGRAPH_NETGRAPH_H_ */ |
