summaryrefslogtreecommitdiff
path: root/lib/clz_tab.c
diff options
context:
space:
mode:
authorBernard Blackham <b-linuxgit@largestprime.net>2012-09-06 10:25:04 (GMT)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-09-06 16:31:53 (GMT)
commit236742de5bfd2af772004ec829518856ff12b469 (patch)
treeae05c790985a5dcfe0ebf690620c29d91c63c305 /lib/clz_tab.c
parent73295fe185e58b8c0b288fee61a8a994015ab4b2 (diff)
downloadlinux-fsl-qoriq-236742de5bfd2af772004ec829518856ff12b469.tar.xz
staging: usbip: avoid deadlock in vhci_device_unlink_cleanup()
Almost all of usbip assumes that the_controller->lock is acquired before vdev->priv_lock. The exception is in vhci_device_unlink_cleanup(), where locks are acquired in the reverse order. This leads to occasional deadlocks. Fixing this is a bit fiddly, as the_controller->lock can't be held when calling usb_hcd_unlink_urb_from_ep() in the middle of the list traversal. As I can't rule out concurrent callers to this function (perhaps it is safe?), the code here becomes slightly uglier - when locks are dropped in the middle so the list may have emptied itself (not even list_for_each_entry_safe is safe here). Signed-off-by: Bernard Blackham <b-linuxgit@largestprime.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'lib/clz_tab.c')
0 files changed, 0 insertions, 0 deletions