diff options
-rw-r--r-- | sys/dev/vr/if_vr.c | 2 | ||||
-rw-r--r-- | sys/pci/if_vr.c | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/sys/dev/vr/if_vr.c b/sys/dev/vr/if_vr.c index eb986ee..d509b13 100644 --- a/sys/dev/vr/if_vr.c +++ b/sys/dev/vr/if_vr.c @@ -798,7 +798,9 @@ vr_detach(device_t dev) /* These should only be active if attach succeeded */ if (device_is_attached(dev)) { vr_stop(sc); + VR_UNLOCK(sc); /* XXX: Avoid recursive acquire. */ ether_ifdetach(ifp); + VR_LOCK(sc); } if (sc->vr_miibus) device_delete_child(dev, sc->vr_miibus); diff --git a/sys/pci/if_vr.c b/sys/pci/if_vr.c index eb986ee..d509b13 100644 --- a/sys/pci/if_vr.c +++ b/sys/pci/if_vr.c @@ -798,7 +798,9 @@ vr_detach(device_t dev) /* These should only be active if attach succeeded */ if (device_is_attached(dev)) { vr_stop(sc); + VR_UNLOCK(sc); /* XXX: Avoid recursive acquire. */ ether_ifdetach(ifp); + VR_LOCK(sc); } if (sc->vr_miibus) device_delete_child(dev, sc->vr_miibus); |