usb_lock_device - acquire the lock for a usb device structure
void usb_lock_device (struct usb_device * udev);
udev device that’s being locked
Use this routine when you don’t hold any other device locks; to acquire nested inner locks call down(&udev->serialize) directly. This is necessary for proper interaction with usb_lock_all_devices.