diff options
Diffstat (limited to 'sys/dev/usb/controller/usb_controller.c')
| -rw-r--r-- | sys/dev/usb/controller/usb_controller.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/dev/usb/controller/usb_controller.c b/sys/dev/usb/controller/usb_controller.c index fe8e48efa01c..fd9bcd5ee524 100644 --- a/sys/dev/usb/controller/usb_controller.c +++ b/sys/dev/usb/controller/usb_controller.c @@ -438,9 +438,9 @@ usb_bus_detach(struct usb_proc_msg *pm) USB_BUS_UNLOCK(bus); /* detach children first */ - mtx_lock(&Giant); + bus_topo_lock(); bus_generic_detach(dev); - mtx_unlock(&Giant); + bus_topo_unlock(); /* * Free USB device and all subdevices, if any. @@ -803,10 +803,10 @@ usb_bus_attach(struct usb_proc_msg *pm) static void usb_attach_sub(device_t dev, struct usb_bus *bus) { - mtx_lock(&Giant); + bus_topo_lock(); if (usb_devclass_ptr == NULL) usb_devclass_ptr = devclass_find("usbus"); - mtx_unlock(&Giant); + bus_topo_unlock(); #if USB_HAVE_PF usbpf_attach(bus); |
