Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/pci recover if_wm.c:r1.348



details:   https://anonhg.NetBSD.org/src/rev/62cac1b17ac8
branches:  trunk
changeset: 340983:62cac1b17ac8
user:      knakahara <knakahara%NetBSD.org@localhost>
date:      Tue Oct 13 10:21:21 2015 +0000

description:
recover if_wm.c:r1.348

diffstat:

 sys/dev/pci/if_wm.c |  10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diffs (31 lines):

diff -r b883ca3a04af -r 62cac1b17ac8 sys/dev/pci/if_wm.c
--- a/sys/dev/pci/if_wm.c       Tue Oct 13 09:46:42 2015 +0000
+++ b/sys/dev/pci/if_wm.c       Tue Oct 13 10:21:21 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_wm.c,v 1.367 2015/10/13 09:10:01 knakahara Exp $    */
+/*     $NetBSD: if_wm.c,v 1.368 2015/10/13 10:21:21 knakahara Exp $    */
 
 /*
  * Copyright (c) 2001, 2002, 2003, 2004 Wasabi Systems, Inc.
@@ -83,7 +83,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.367 2015/10/13 09:10:01 knakahara Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.368 2015/10/13 10:21:21 knakahara Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_net_mpsafe.h"
@@ -5872,8 +5872,10 @@
                } else {
                        CSR_WRITE(sc, WMREG_RDH(qid), 0);
                        CSR_WRITE(sc, WMREG_RDT(qid), 0);
-                       CSR_WRITE(sc, WMREG_RDTR, 375 | RDTR_FPD); /* ITR/4 */
-                       CSR_WRITE(sc, WMREG_RADV, 375); /* MUST be same */
+                       /* ITR / 4 */
+                       CSR_WRITE(sc, WMREG_RDTR, (sc->sc_itr / 4) | RDTR_FPD);
+                       /* MUST be same */
+                       CSR_WRITE(sc, WMREG_RADV, sc->sc_itr / 4);
                        CSR_WRITE(sc, WMREG_RXDCTL(qid), RXDCTL_PTHRESH(0) |
                            RXDCTL_HTHRESH(0) | RXDCTL_WTHRESH(1));
                }



Home | Main Index | Thread Index | Old Index