Bug #2748 ยป netmap.patch
sys/net/netmap/netmap_mem2.c | ||
---|---|---|
#define DECLARE_SYSCTLS(id, name) \
|
||
SYSCTL_INT(_dev_netmap, OID_AUTO, name##_size, \
|
||
SYSCTL_INT(_net_netmap, OID_AUTO, name##_size, \
|
||
CTLFLAG_RW, &netmap_params[id].size, 0, "Requested size of netmap " STRINGIFY(name) "s"); \
|
||
SYSCTL_INT(_dev_netmap, OID_AUTO, name##_curr_size, \
|
||
SYSCTL_INT(_net_netmap, OID_AUTO, name##_curr_size, \
|
||
CTLFLAG_RD, &nm_mem.pools[id]._objsize, 0, "Current size of netmap " STRINGIFY(name) "s"); \
|
||
SYSCTL_INT(_dev_netmap, OID_AUTO, name##_num, \
|
||
SYSCTL_INT(_net_netmap, OID_AUTO, name##_num, \
|
||
CTLFLAG_RW, &netmap_params[id].num, 0, "Requested number of netmap " STRINGIFY(name) "s"); \
|
||
SYSCTL_INT(_dev_netmap, OID_AUTO, name##_curr_num, \
|
||
SYSCTL_INT(_net_netmap, OID_AUTO, name##_curr_num, \
|
||
CTLFLAG_RD, &nm_mem.pools[id].objtotal, 0, "Current number of netmap " STRINGIFY(name) "s")
|
||
SYSCTL_DECL(_dev_netmap);
|
||
SYSCTL_DECL(_net_netmap);
|
||
DECLARE_SYSCTLS(NETMAP_IF_POOL, if);
|
||
DECLARE_SYSCTLS(NETMAP_RING_POOL, ring);
|
||
DECLARE_SYSCTLS(NETMAP_BUF_POOL, buf);
|
sys/net/netmap/netmap_vale.c | ||
---|---|---|
* last packet in the block may overflow the size.
|
||
*/
|
||
int bridge_batch = NM_BDG_BATCH; /* bridge batch size */
|
||
SYSCTL_DECL(_dev_netmap);
|
||
SYSCTL_INT(_dev_netmap, OID_AUTO, bridge_batch, CTLFLAG_RW, &bridge_batch, 0 , "");
|
||
SYSCTL_DECL(_net_netmap);
|
||
SYSCTL_INT(_net_netmap, OID_AUTO, bridge_batch, CTLFLAG_RW, &bridge_batch, 0 , "");
|
||
static int bdg_netmap_attach(struct netmap_adapter *);
|