summaryrefslogtreecommitdiffstats
path: root/sys/xen/xenbus/xenbus_probe.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/xen/xenbus/xenbus_probe.c')
-rw-r--r--sys/xen/xenbus/xenbus_probe.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/sys/xen/xenbus/xenbus_probe.c b/sys/xen/xenbus/xenbus_probe.c
index f04f8ec..f930c8f 100644
--- a/sys/xen/xenbus/xenbus_probe.c
+++ b/sys/xen/xenbus/xenbus_probe.c
@@ -348,7 +348,9 @@ xenbus_devices_changed(struct xenbus_watch *watch,
if (p)
*p = 0;
+ newbus_xlock();
xenbus_add_device(dev, bus, type, id);
+ newbus_xunlock();
taskqueue_enqueue(taskqueue_thread, &sc->xs_probechildren);
out:
free(node, M_DEVBUF);
@@ -361,7 +363,9 @@ xenbus_attach_deferred(void *arg)
struct xenbus_softc *sc = device_get_softc(dev);
int error;
+ newbus_xlock();
error = xenbus_enumerate_bus(dev, "device");
+ newbus_xunlock();
if (error)
return;
xenbus_probe_children(dev);
OpenPOWER on IntegriCloud