aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Gallatin <gallatin@FreeBSD.org>2007-05-25 19:38:32 +0000
committerAndrew Gallatin <gallatin@FreeBSD.org>2007-05-25 19:38:32 +0000
commita0394e33a5a30d7ff789f45801770562bbcb7daf (patch)
treed845684661faea1e095cea758725f7cff4cc325c
parentd1b41c9b1685692f866ab1f7ddc16773777fd6e7 (diff)
downloadsrc-a0394e33a5a30d7ff789f45801770562bbcb7daf.tar.gz
src-a0394e33a5a30d7ff789f45801770562bbcb7daf.zip
- Use m_getcl() rather than m_getjcl() when we're allocating 2KB
clusters. This helps quite a bit on my low end machines (improves performance by about 300Kpps when being blasted by a hardware packet generator). - Include one extended f/w counter forgotten in earlier commit Sponsored by: Myricom Inc.
Notes
Notes: svn path=/head/; revision=169995
-rw-r--r--sys/dev/mxge/if_mxge.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/sys/dev/mxge/if_mxge.c b/sys/dev/mxge/if_mxge.c
index d57eff82ecbe..93c55a183b37 100644
--- a/sys/dev/mxge/if_mxge.c
+++ b/sys/dev/mxge/if_mxge.c
@@ -1372,6 +1372,12 @@ mxge_add_sysctls(mxge_softc_t *sc)
0, mxge_handle_be32,
"I", "dropped_runt");
+ SYSCTL_ADD_PROC(ctx, children, OID_AUTO,
+ "dropped_unicast_filtered",
+ CTLTYPE_INT|CTLFLAG_RD, &fw->dropped_unicast_filtered,
+ 0, mxge_handle_be32,
+ "I", "dropped_unicast_filtered");
+
/* host counters exported for debugging */
SYSCTL_ADD_INT(ctx, children, OID_AUTO,
"rx_small_cnt",
@@ -1953,7 +1959,10 @@ mxge_get_buf_big(mxge_softc_t *sc, bus_dmamap_t map, int idx)
mxge_rx_buf_t *rx = &sc->rx_big;
int cnt, err, i;
- m = m_getjcl(M_DONTWAIT, MT_DATA, M_PKTHDR, rx->cl_size);
+ if (rx->cl_size == MCLBYTES)
+ m = m_getcl(M_DONTWAIT, MT_DATA, M_PKTHDR);
+ else
+ m = m_getjcl(M_DONTWAIT, MT_DATA, M_PKTHDR, rx->cl_size);
if (m == NULL) {
rx->alloc_fail++;
err = ENOBUFS;