summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--device.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/device.c b/device.c
index b16f156..26b020f 100644
--- a/device.c
+++ b/device.c
@@ -254,7 +254,7 @@ void device_release(struct device_user *dep)
return;
device_broadcast_event(dev, DEV_EVENT_TEARDOWN);
- if (!dep->hotplug)
+ if (!dev->external)
dev->set_state(dev, false);
device_broadcast_event(dev, DEV_EVENT_DOWN);
}