diff options
author | Mayank Rana <mrana@codeaurora.org> | 2016-02-19 15:14:07 -0800 |
---|---|---|
committer | David Keitel <dkeitel@codeaurora.org> | 2016-03-23 21:21:02 -0700 |
commit | e3020f3887dbd1f4443e5012942f6ec72e3fe9e9 (patch) | |
tree | e834a3036457ecd6b34a02a105d7827deb3ca2bb /arch | |
parent | 2b72760a0ad005a5a3214f7c1492b8a6d7169e52 (diff) |
xhci-hub: Handle error condition with xhci_stop_device
xhci_stop_device() is calling xhci_queue_stop_endpoint() multiple time
and doesn't check return value. xhci_queue_stop_endpoint() can return
error if xhci is already halted or not able to queue command.
xhci_stop_device() waits for stop command completion using
wait_for_completion which wouldn't be interrupted or completed if
queueing of command fails. It results into possible deadlock condition
where usb_disconnect() waits for this udev->lock which is already
acquired by caller of xhci_stop_device() which is set_port_feature().
Fix this issue by handling error condition and making sure that
xhci_stop_device() doesn't wait if queueing of command is failed.
Change-Id: Ica4db17afcd39a7e89fcf985f41760efd2756653
Signed-off-by: Mayank Rana <mrana@codeaurora.org>
Diffstat (limited to 'arch')
0 files changed, 0 insertions, 0 deletions