From 214073e5e40bb05206c2e00041a1b2dddb2e754d Mon Sep 17 00:00:00 2001 From: Warner Losh Date: Mon, 21 Apr 2003 18:34:04 +0000 Subject: Use newly minted device_is_attached rather than device_is_alive to see if attach succeeded. device_is_alive just tells us that probe succeeded. Since we were using it to do things like detach net interfaces, this caused problems when there were errors in the attach routine. Symptoms of problem reported by: martin blapp --- sys/dev/dc/if_dc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sys/dev/dc') diff --git a/sys/dev/dc/if_dc.c b/sys/dev/dc/if_dc.c index 1f872ec4cb7c..a350d47d4bdc 100644 --- a/sys/dev/dc/if_dc.c +++ b/sys/dev/dc/if_dc.c @@ -2316,7 +2316,7 @@ dc_detach(dev) ifp = &sc->arpcom.ac_if; /* These should only be active if attach succeeded */ - if (device_is_alive(dev)) { + if (device_is_attached(dev)) { dc_stop(sc); ether_ifdetach(ifp); } -- cgit v1.3