RELENG_7 if_nve panic
John Baldwin
jhb at freebsd.org
Tue Jan 26 15:37:57 UTC 2010
On Tuesday 26 January 2010 4:29:05 am Dmitry Sivachenko wrote:
> Hello!
>
> I recompiled recent RELENG_7 and I get the following panic after
> trying to kldload if_nve (interesting stack frames are 12, 13, 14 I guess).
> Previous version of RELENG_7 (compiled in the middle of December)
> worked fine. Last few days I was trying to re-cvsup and always get the
> same panic. I get FreeBSD sources via cvsup (cvsup5.freebsd.org).
>
> Any suggestions?
>
> Thanks in advance!
The bug is perhaps in e1000phy in that it expects all callers to have called
if_initname() before the miibus is probed. Try this patch:
Index: if_nve.c
===================================================================
--- if_nve.c (revision 202705)
+++ if_nve.c (working copy)
@@ -526,14 +526,6 @@
goto fail;
}
- /* Probe device for MII interface to PHY */
- DEBUGOUT(NVE_DEBUG_INIT, "nve: do mii_phy_probe\n");
- if (mii_phy_probe(dev, &sc->miibus, nve_ifmedia_upd, nve_ifmedia_sts)) {
- device_printf(dev, "MII without any phy!\n");
- error = ENXIO;
- goto fail;
- }
-
/* Setup interface parameters */
ifp->if_softc = sc;
if_initname(ifp, device_get_name(dev), device_get_unit(dev));
@@ -549,6 +541,14 @@
ifp->if_capabilities |= IFCAP_VLAN_MTU;
ifp->if_capenable |= IFCAP_VLAN_MTU;
+ /* Probe device for MII interface to PHY */
+ DEBUGOUT(NVE_DEBUG_INIT, "nve: do mii_phy_probe\n");
+ if (mii_phy_probe(dev, &sc->miibus, nve_ifmedia_upd, nve_ifmedia_sts)) {
+ device_printf(dev, "MII without any phy!\n");
+ error = ENXIO;
+ goto fail;
+ }
+
/* Attach to OS's managers. */
ether_ifattach(ifp, eaddr);
--
John Baldwin
More information about the freebsd-stable
mailing list