Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/pci bge_init_tx_ring() uses BGE_RSLOTS (==256) but b...



details:   https://anonhg.NetBSD.org/src/rev/204a9fa26b4d
branches:  trunk
changeset: 786941:204a9fa26b4d
user:      msaitoh <msaitoh%NetBSD.org@localhost>
date:      Fri May 24 02:29:36 2013 +0000

description:
bge_init_tx_ring() uses BGE_RSLOTS (==256) but bge_free_tx_ring() uses
BGE_TX_RING_CNT (== 512). Delete BGE_RSLOTS and use BGE_TX_RING_CNT. Same as
OpenBSD's if_bge.c rev. 1.86.

diffstat:

 sys/dev/pci/if_bge.c    |  6 +++---
 sys/dev/pci/if_bgevar.h |  3 +--
 2 files changed, 4 insertions(+), 5 deletions(-)

diffs (44 lines):

diff -r c377a9e62a9d -r 204a9fa26b4d sys/dev/pci/if_bge.c
--- a/sys/dev/pci/if_bge.c      Thu May 23 21:39:49 2013 +0000
+++ b/sys/dev/pci/if_bge.c      Fri May 24 02:29:36 2013 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_bge.c,v 1.245 2013/05/21 06:59:28 martin Exp $      */
+/*     $NetBSD: if_bge.c,v 1.246 2013/05/24 02:29:36 msaitoh Exp $     */
 
 /*
  * Copyright (c) 2001 Wind River Systems
@@ -79,7 +79,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_bge.c,v 1.245 2013/05/21 06:59:28 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_bge.c,v 1.246 2013/05/24 02:29:36 msaitoh Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -1965,7 +1965,7 @@
                bge_writembx(sc, BGE_MBX_TX_NIC_PROD0_LO, 0);
 
        SLIST_INIT(&sc->txdma_list);
-       for (i = 0; i < BGE_RSLOTS; i++) {
+       for (i = 0; i < BGE_TX_RING_CNT; i++) {
                if (bus_dmamap_create(sc->bge_dmatag, BGE_TXDMA_MAX,
                    BGE_NTXSEG, ETHER_MAX_LEN_JUMBO, 0, BUS_DMA_NOWAIT,
                    &dmamap))
diff -r c377a9e62a9d -r 204a9fa26b4d sys/dev/pci/if_bgevar.h
--- a/sys/dev/pci/if_bgevar.h   Thu May 23 21:39:49 2013 +0000
+++ b/sys/dev/pci/if_bgevar.h   Fri May 24 02:29:36 2013 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_bgevar.h,v 1.14 2013/03/24 22:33:59 msaitoh Exp $   */
+/*     $NetBSD: if_bgevar.h,v 1.15 2013/05/24 02:29:36 msaitoh Exp $   */
 /*
  * Copyright (c) 2001 Wind River Systems
  * Copyright (c) 1997, 1998, 1999, 2001
@@ -152,7 +152,6 @@
 #define BGE_SSLOTS     256
 #define BGE_MSLOTS     256
 #define BGE_JSLOTS     384
-#define BGE_RSLOTS     256
 
 #define BGE_JRAWLEN (BGE_JUMBO_FRAMELEN + ETHER_ALIGN)
 #define BGE_JLEN (BGE_JRAWLEN + (sizeof(uint64_t) - \



Home | Main Index | Thread Index | Old Index