Module Name:    src
Committed By:   martin
Date:           Wed Feb 20 09:49:49 UTC 2019

Modified Files:
        src/sys/dev/usb [netbsd-8]: if_axen.c if_axenreg.h

Log Message:
Pull up following revision(s) (requested by rin in ticket #1194):

        sys/dev/usb/if_axen.c: revision 1.26
        sys/dev/usb/if_axenreg.h: revision 1.7

Remove unused variable in axen_softc.

Drop AXEN_MEDIUM_ALWAYS_ONE (from Linux), which reduces drop erros in RX.


To generate a diff of this commit:
cvs rdiff -u -r1.11.8.6 -r1.11.8.7 src/sys/dev/usb/if_axen.c
cvs rdiff -u -r1.3.10.2 -r1.3.10.3 src/sys/dev/usb/if_axenreg.h

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

Modified files:

Index: src/sys/dev/usb/if_axen.c
diff -u src/sys/dev/usb/if_axen.c:1.11.8.6 src/sys/dev/usb/if_axen.c:1.11.8.7
--- src/sys/dev/usb/if_axen.c:1.11.8.6	Tue Feb 19 15:09:51 2019
+++ src/sys/dev/usb/if_axen.c	Wed Feb 20 09:49:48 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_axen.c,v 1.11.8.6 2019/02/19 15:09:51 martin Exp $	*/
+/*	$NetBSD: if_axen.c,v 1.11.8.7 2019/02/20 09:49:48 martin Exp $	*/
 /*	$OpenBSD: if_axen.c,v 1.3 2013/10/21 10:10:22 yuo Exp $	*/
 
 /*
@@ -23,7 +23,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_axen.c,v 1.11.8.6 2019/02/19 15:09:51 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_axen.c,v 1.11.8.7 2019/02/20 09:49:48 martin Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_inet.h"
@@ -271,9 +271,8 @@ axen_miibus_statchg(struct ifnet *ifp)
 	if ((mii->mii_media_active & IFM_GMASK) == IFM_FDX)
 		val |= AXEN_MEDIUM_FDX;
 
-	val |= (AXEN_MEDIUM_RECV_EN | AXEN_MEDIUM_ALWAYS_ONE);
-	val |= (AXEN_MEDIUM_RXFLOW_CTRL_EN | AXEN_MEDIUM_TXFLOW_CTRL_EN);
-
+	val |= AXEN_MEDIUM_RXFLOW_CTRL_EN | AXEN_MEDIUM_TXFLOW_CTRL_EN |
+	    AXEN_MEDIUM_RECV_EN;
 	switch (IFM_SUBTYPE(mii->mii_media_active)) {
 	case IFM_1000_T:
 		val |= AXEN_MEDIUM_GIGA | AXEN_MEDIUM_EN_125MHZ;
@@ -588,9 +587,9 @@ axen_ax88179_init(struct axen_softc *sc)
 	DPRINTF(("axen: Monitor mode = 0x%02x\n", val));
 
 	/* set medium type */
-	ctl = AXEN_MEDIUM_GIGA | AXEN_MEDIUM_FDX | AXEN_MEDIUM_ALWAYS_ONE |
-	      AXEN_MEDIUM_RXFLOW_CTRL_EN | AXEN_MEDIUM_TXFLOW_CTRL_EN;
-	ctl |= AXEN_MEDIUM_RECV_EN;
+	ctl = AXEN_MEDIUM_GIGA | AXEN_MEDIUM_FDX | AXEN_MEDIUM_EN_125MHZ |
+	    AXEN_MEDIUM_RXFLOW_CTRL_EN | AXEN_MEDIUM_TXFLOW_CTRL_EN |
+	    AXEN_MEDIUM_RECV_EN;
 	wval = htole16(ctl);
 	DPRINTF(("axen: set to medium mode: 0x%04x\n", ctl));
 	axen_cmd(sc, AXEN_CMD_MAC_WRITE2, 2, AXEN_MEDIUM_STATUS, &wval);

Index: src/sys/dev/usb/if_axenreg.h
diff -u src/sys/dev/usb/if_axenreg.h:1.3.10.2 src/sys/dev/usb/if_axenreg.h:1.3.10.3
--- src/sys/dev/usb/if_axenreg.h:1.3.10.2	Tue Feb 19 15:09:51 2019
+++ src/sys/dev/usb/if_axenreg.h	Wed Feb 20 09:49:48 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_axenreg.h,v 1.3.10.2 2019/02/19 15:09:51 martin Exp $	*/
+/*	$NetBSD: if_axenreg.h,v 1.3.10.3 2019/02/20 09:49:48 martin Exp $	*/
 /*	$OpenBSD: if_axenreg.h,v 1.1 2013/10/07 05:37:41 yuo Exp $	*/
 
 /*
@@ -289,7 +289,6 @@ struct axen_softc {
 
 	int			axen_link;
 
-	uint8_t			axen_ipgs[3];
 	int			axen_phyno;
 	struct timeval		axen_rx_notice;
 	struct timeval		axen_tx_notice;

Reply via email to