Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/pci Bump the number of Tx DMA segments from 8 to 16 ...



details:   https://anonhg.NetBSD.org/src/rev/ca68ca429237
branches:  trunk
changeset: 526381:ca68ca429237
user:      thorpej <thorpej%NetBSD.org@localhost>
date:      Fri May 03 00:18:31 2002 +0000

description:
Bump the number of Tx DMA segments from 8 to 16 (the zero-copy socket
code sometimes sees more than 8).

diffstat:

 sys/dev/pci/if_sip.c    |  9 +++++----
 sys/dev/pci/if_stereg.h |  4 ++--
 2 files changed, 7 insertions(+), 6 deletions(-)

diffs (50 lines):

diff -r fb12178cc81d -r ca68ca429237 sys/dev/pci/if_sip.c
--- a/sys/dev/pci/if_sip.c      Fri May 03 00:07:02 2002 +0000
+++ b/sys/dev/pci/if_sip.c      Fri May 03 00:18:31 2002 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_sip.c,v 1.51 2002/03/27 21:42:45 briggs Exp $       */
+/*     $NetBSD: if_sip.c,v 1.52 2002/05/03 00:18:31 thorpej Exp $      */
 
 /*-
  * Copyright (c) 2001, 2002 The NetBSD Foundation, Inc.
@@ -82,7 +82,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_sip.c,v 1.51 2002/03/27 21:42:45 briggs Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_sip.c,v 1.52 2002/05/03 00:18:31 thorpej Exp $");
 
 #include "bpfilter.h"
 
@@ -138,10 +138,11 @@
  * enough descriptors for 128 pending transmissions, and 8 segments
  * per packet.  This MUST work out to a power of 2.
  */
-#define        SIP_NTXSEGS             8
+#define        SIP_NTXSEGS             16
+#define        SIP_NTXSEGS_ALLOC       8
 
 #define        SIP_TXQUEUELEN          256
-#define        SIP_NTXDESC             (SIP_TXQUEUELEN * SIP_NTXSEGS)
+#define        SIP_NTXDESC             (SIP_TXQUEUELEN * SIP_NTXSEGS_ALLOC)
 #define        SIP_NTXDESC_MASK        (SIP_NTXDESC - 1)
 #define        SIP_NEXTTX(x)           (((x) + 1) & SIP_NTXDESC_MASK)
 
diff -r fb12178cc81d -r ca68ca429237 sys/dev/pci/if_stereg.h
--- a/sys/dev/pci/if_stereg.h   Fri May 03 00:07:02 2002 +0000
+++ b/sys/dev/pci/if_stereg.h   Fri May 03 00:18:31 2002 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_stereg.h,v 1.1 2001/06/19 23:00:47 thorpej Exp $    */
+/*     $NetBSD: if_stereg.h,v 1.2 2002/05/03 00:19:12 thorpej Exp $    */
 
 /*-
  * Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -59,7 +59,7 @@
  * ST-201 Transmit Frame Descriptor.  Note the number of fragments
  * here is arbitrary, but we can't exceed 512 bytes of TFD.
  */
-#define        STE_NTXFRAGS    8
+#define        STE_NTXFRAGS    16
 struct ste_tfd {
        uint32_t        tfd_next;       /* next TFD in list */
        uint32_t        tfd_control;    /* control bits */



Home | Main Index | Thread Index | Old Index