Date: Thu, 27 Dec 2012 21:14:30 +0000 (UTC) From: Marcel Moolenaar <marcel@FreeBSD.org> To: src-committers@freebsd.org, svn-src-projects@freebsd.org Subject: svn commit: r244751 - projects/altix2/sys/dev/bge Message-ID: <201212272114.qBRLEUj2058601@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: marcel Date: Thu Dec 27 21:14:29 2012 New Revision: 244751 URL: http://svnweb.freebsd.org/changeset/base/244751 Log: Fix error handling when bge_detach() is called from bge_attach() and in particular due to DMA setup errors. Modified: projects/altix2/sys/dev/bge/if_bge.c Modified: projects/altix2/sys/dev/bge/if_bge.c ============================================================================== --- projects/altix2/sys/dev/bge/if_bge.c Thu Dec 27 20:59:22 2012 (r244750) +++ projects/altix2/sys/dev/bge/if_bge.c Thu Dec 27 21:14:29 2012 (r244751) @@ -3901,7 +3901,7 @@ bge_detach(device_t dev) if (sc->bge_flags & BGE_FLAG_TBI) { ifmedia_removeall(&sc->bge_ifmedia); - } else { + } else if (sc->bge_miibus != NULL) { bus_generic_detach(dev); device_delete_child(dev, sc->bge_miibus); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201212272114.qBRLEUj2058601>