summaryrefslogtreecommitdiffstats
path: root/sys/pci/if_tl.c
diff options
context:
space:
mode:
authorru <ru@FreeBSD.org>2005-10-13 21:11:20 +0000
committerru <ru@FreeBSD.org>2005-10-13 21:11:20 +0000
commitb9c7add838ccaace56cbb1d065e502e478f92d4e (patch)
tree42d971c6d541bfdfd3204acba1a4ae6004c37124 /sys/pci/if_tl.c
parent9d4f7296d4bd26d172e55a582c41d028d6dceb40 (diff)
downloadFreeBSD-src-b9c7add838ccaace56cbb1d065e502e478f92d4e.zip
FreeBSD-src-b9c7add838ccaace56cbb1d065e502e478f92d4e.tar.gz
In detach method, move if_free() after bus_teardown_intr().
Diffstat (limited to 'sys/pci/if_tl.c')
-rw-r--r--sys/pci/if_tl.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/pci/if_tl.c b/sys/pci/if_tl.c
index 6743912..35f41c8 100644
--- a/sys/pci/if_tl.c
+++ b/sys/pci/if_tl.c
@@ -1343,8 +1343,6 @@ tl_detach(dev)
callout_drain(&sc->tl_stat_callout);
ether_ifdetach(ifp);
}
- if (ifp)
- if_free(ifp);
if (sc->tl_miibus)
device_delete_child(dev, sc->tl_miibus);
bus_generic_detach(dev);
@@ -1361,6 +1359,9 @@ tl_detach(dev)
if (sc->tl_res)
bus_release_resource(dev, TL_RES, TL_RID, sc->tl_res);
+ if (ifp)
+ if_free(ifp);
+
mtx_destroy(&sc->tl_mtx);
return(0);
OpenPOWER on IntegriCloud