Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/pci rtwn(4): increase the number of tx queue require...



details:   https://anonhg.NetBSD.org/src/rev/06b4de567f50
branches:  trunk
changeset: 350837:06b4de567f50
user:      nonaka <nonaka%NetBSD.org@localhost>
date:      Tue Jan 24 10:18:33 2017 +0000

description:
rtwn(4): increase the number of tx queue required to clear the full mask.

diffstat:

 sys/dev/pci/if_rtwn.c    |  8 ++++----
 sys/dev/pci/if_rtwnreg.h |  4 +++-
 2 files changed, 7 insertions(+), 5 deletions(-)

diffs (54 lines):

diff -r b6ea48eea404 -r 06b4de567f50 sys/dev/pci/if_rtwn.c
--- a/sys/dev/pci/if_rtwn.c     Tue Jan 24 09:05:27 2017 +0000
+++ b/sys/dev/pci/if_rtwn.c     Tue Jan 24 10:18:33 2017 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_rtwn.c,v 1.9 2016/12/08 01:12:01 ozaki-r Exp $      */
+/*     $NetBSD: if_rtwn.c,v 1.10 2017/01/24 10:18:33 nonaka Exp $      */
 /*     $OpenBSD: if_rtwn.c,v 1.5 2015/06/14 08:02:47 stsp Exp $        */
 #define        IEEE80211_NO_HT
 /*-
@@ -23,7 +23,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_rtwn.c,v 1.9 2016/12/08 01:12:01 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_rtwn.c,v 1.10 2017/01/24 10:18:33 nonaka Exp $");
 
 #include <sys/param.h>
 #include <sys/sockio.h>
@@ -1989,7 +1989,7 @@
        tx_ring->cur = (tx_ring->cur + 1) % RTWN_TX_LIST_COUNT;
        tx_ring->queued++;
 
-       if (tx_ring->queued >= (RTWN_TX_LIST_COUNT - 1))
+       if (tx_ring->queued > RTWN_TX_LIST_HIMARK)
                sc->qfullmsk |= (1 << qid);
 
        /* Kick TX. */
@@ -2035,7 +2035,7 @@
                tx_ring->queued--;
        }
 
-       if (tx_ring->queued < (RTWN_TX_LIST_COUNT - 1))
+       if (tx_ring->queued < RTWN_TX_LIST_LOMARK)
                sc->qfullmsk &= ~(1 << qid);
 }
 
diff -r b6ea48eea404 -r 06b4de567f50 sys/dev/pci/if_rtwnreg.h
--- a/sys/dev/pci/if_rtwnreg.h  Tue Jan 24 09:05:27 2017 +0000
+++ b/sys/dev/pci/if_rtwnreg.h  Tue Jan 24 10:18:33 2017 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_rtwnreg.h,v 1.2 2015/11/06 14:22:17 nonaka Exp $    */
+/*     $NetBSD: if_rtwnreg.h,v 1.3 2017/01/24 10:18:33 nonaka Exp $    */
 /*     $OpenBSD: if_rtwnreg.h,v 1.3 2015/06/14 08:02:47 stsp Exp $     */
 
 /*-
@@ -1168,6 +1168,8 @@
 #define RTWN_NTXQUEUES                 9
 #define RTWN_RX_LIST_COUNT             256
 #define RTWN_TX_LIST_COUNT             256
+#define RTWN_TX_LIST_LOMARK            192
+#define RTWN_TX_LIST_HIMARK            255
 #define RTWN_HOST_CMD_RING_COUNT       32
 
 /* TX queue indices. */



Home | Main Index | Thread Index | Old Index