Module Name:    src
Committed By:   martin
Date:           Wed Feb  5 13:08:19 UTC 2020

Modified Files:
        src/sys/arch/newsmips/apbus: if_sn.c

Log Message:
Fix if_stats access.


To generate a diff of this commit:
cvs rdiff -u -r1.48 -r1.49 src/sys/arch/newsmips/apbus/if_sn.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/newsmips/apbus/if_sn.c
diff -u src/sys/arch/newsmips/apbus/if_sn.c:1.48 src/sys/arch/newsmips/apbus/if_sn.c:1.49
--- src/sys/arch/newsmips/apbus/if_sn.c:1.48	Tue Feb  4 07:41:01 2020
+++ src/sys/arch/newsmips/apbus/if_sn.c	Wed Feb  5 13:08:19 2020
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_sn.c,v 1.48 2020/02/04 07:41:01 skrll Exp $	*/
+/*	$NetBSD: if_sn.c,v 1.49 2020/02/05 13:08:19 martin Exp $	*/
 
 /*
  * National Semiconductor  DP8393X SONIC Driver
@@ -16,7 +16,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_sn.c,v 1.48 2020/02/04 07:41:01 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_sn.c,v 1.49 2020/02/05 13:08:19 martin Exp $");
 
 #include "opt_inet.h"
 
@@ -966,9 +966,9 @@ sonicrxint(struct sn_softc *sc)
 			    (char *)sc->rbuf[orra & RBAMASK] +
 				 (rxpkt_ptr & PGOFSET);
 			if (sonic_read(sc, pkt, len) == 0)
-				sc->sc_if.if_ierrors++;
+				if_statinc(&sc->sc_if, if_ierrors);
 		} else
-			sc->sc_if.if_ierrors++;
+			if_statinc(&sc->sc_if, if_ierrors);
 
 		/*
 		 * give receive buffer area back to chip.

Reply via email to