axe(4) doesn't work (patch to replace obsolete if_watchdog interface)

Pyun YongHyeon pyunyh at gmail.com
Tue Jun 3 08:44:12 UTC 2008


On Tue, Jun 03, 2008 at 01:44:25PM +0900, Norikatsu Shigemura wrote:
 > On Tue, 3 Jun 2008 10:00:01 +0900
 > Pyun YongHyeon <pyunyh at gmail.com> wrote:
 > >  > ukphy0: OUI 0x1e525e, model 0x0014, rev. 9
 > >            ^^^^^^^^^^^^
 > > This OUI does not exist in IEEE OUI database so I vaguely guess
 > > this one comes from broken MII_OUI macro implementation in FreeBSD.
 > > Because PHY vendors also made the same mistake as FreeBSD this
 > > hasn't been much problem so far. Would you apply the following
 > > patch and let me know the output of ukphy(4)? 
 > 
 > 	Please see following result.
 > - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 > miibus0: <MII bus> on axe0
 > ukphy0: <Generic IEEE 802.3u media interface> PHY 0 on miibus0
 > ukphy0: OUI 0x1e525e, model 0x0014, rev. 9
 > ukphy0:  10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseSX, 1000baseT, 1000baseT-FDX, auto
 > ukphy0: IDR1 = 0x7949, IDR2 = 0x7949

Hmm, this also looks like faked one. Probably PHY address was
incorrectly chosen. I guess the PHY would be one of Marvell
variants. If this is correct guess, I think ax88178_init() should
be called prior to any other operations(patch attached).
Sam, what's your opinion?

-- 
Regards,
Pyun YongHyeon
-------------- next part --------------
--- if_axe.c.orig	2008-06-03 11:09:23.000000000 +0900
+++ if_axe.c	2008-06-03 17:41:16.000000000 +0900
@@ -608,14 +608,14 @@
 	AXE_SLEEPLOCK(sc);
 	AXE_LOCK(sc);
 
-	/* We need the PHYID for the init dance in some cases */
-	axe_cmd(sc, AXE_CMD_READ_PHYID, 0, 0, (void *)&sc->axe_phyaddrs);
-
 	if (sc->axe_flags & AX178)
 		axe_ax88178_init(sc);
 	else if (sc->axe_flags & AX772)
 		axe_ax88772_init(sc);
 
+	/* We need the PHYID for the init dance in some cases */
+	axe_cmd(sc, AXE_CMD_READ_PHYID, 0, 0, (void *)&sc->axe_phyaddrs);
+
 	/*
 	 * Get station address.
 	 */


More information about the freebsd-current mailing list