svn commit: r184964 - user/kmacy/HEAD_fast_multi_xmit/sys/dev/cxgb
Kip Macy
kmacy at FreeBSD.org
Fri Nov 14 00:43:01 PST 2008
Author: kmacy
Date: Fri Nov 14 08:43:01 2008
New Revision: 184964
URL: http://svn.freebsd.org/changeset/base/184964
Log:
Add sysctl to disable use of multiple transmit queues at run-time (the number of rx queues
can only be set at initialization time)
Modified:
user/kmacy/HEAD_fast_multi_xmit/sys/dev/cxgb/cxgb_multiq.c
user/kmacy/HEAD_fast_multi_xmit/sys/dev/cxgb/cxgb_sge.c
Modified: user/kmacy/HEAD_fast_multi_xmit/sys/dev/cxgb/cxgb_multiq.c
==============================================================================
--- user/kmacy/HEAD_fast_multi_xmit/sys/dev/cxgb/cxgb_multiq.c Fri Nov 14 08:41:27 2008 (r184963)
+++ user/kmacy/HEAD_fast_multi_xmit/sys/dev/cxgb/cxgb_multiq.c Fri Nov 14 08:43:01 2008 (r184964)
@@ -87,8 +87,10 @@ __FBSDID("$FreeBSD$");
#include <sys/mvec.h>
extern int txq_fills;
+int multiq_tx_enable = 1;
+
extern struct sysctl_oid_list sysctl__hw_cxgb_children;
-static int cxgb_pcpu_tx_coalesce = 0;
+static int cxgb_pcpu_tx_coalesce = 1;
TUNABLE_INT("hw.cxgb.tx_coalesce", &cxgb_pcpu_tx_coalesce);
SYSCTL_UINT(_hw_cxgb, OID_AUTO, tx_coalesce, CTLFLAG_RDTUN, &cxgb_pcpu_tx_coalesce, 0,
"coalesce small packets into a single work request");
@@ -503,6 +505,9 @@ cxgb_pcpu_cookie_to_qidx(struct port_inf
{
int qidx;
uint32_t tmp;
+
+ if (multiq_tx_enable == 0)
+ return (pi->first_qset);
/*
* Will probably need to be changed for 4-port XXX
Modified: user/kmacy/HEAD_fast_multi_xmit/sys/dev/cxgb/cxgb_sge.c
==============================================================================
--- user/kmacy/HEAD_fast_multi_xmit/sys/dev/cxgb/cxgb_sge.c Fri Nov 14 08:41:27 2008 (r184963)
+++ user/kmacy/HEAD_fast_multi_xmit/sys/dev/cxgb/cxgb_sge.c Fri Nov 14 08:43:01 2008 (r184964)
@@ -84,9 +84,7 @@ extern int cxgb_pcpu_cache_enable;
extern int nmbjumbo4;
extern int nmbjumbo9;
extern int nmbjumbo16;
-
-
-
+extern int multiq_tx_enable;
#define USE_GTS 0
@@ -1273,7 +1271,6 @@ t3_encap(struct sge_qset *qs, struct mbu
KASSERT(txsd->mi.mi_base == NULL,
("overwriting valid entry mi_base==%p", txsd->mi.mi_base));
if (count > 1) {
- panic("count > 1 not support in CVS\n");
if ((err = busdma_map_sg_vec(m, &m0, segs, count)))
return (err);
nsegs = count;
@@ -3368,6 +3365,10 @@ t3_add_attach_sysctls(adapter_t *sc)
CTLFLAG_RW, &cxgb_pcpu_cache_enable,
0, "#enable driver local pcpu caches");
SYSCTL_ADD_INT(ctx, children, OID_AUTO,
+ "multiq_tx_enable",
+ CTLFLAG_RW, &multiq_tx_enable,
+ 0, "enable transmit by multiple tx queues");
+ SYSCTL_ADD_INT(ctx, children, OID_AUTO,
"cache_alloc",
CTLFLAG_RD, &cxgb_cached_allocations,
0, "#times a cluster was allocated from cache");
More information about the svn-src-user
mailing list