summaryrefslogtreecommitdiffstats
path: root/drivers/usb/wusbcore
diff options
context:
space:
mode:
authorThomas Pugliese <thomas.pugliese@gmail.com>2014-04-23 21:32:27 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-04-24 21:45:40 +0200
commit7584f2ebc18b6355f21be5fb2f75afbf3f781ce5 (patch)
tree048f31e5c303f4fcbb1cd5d7110598ffeec72d0f /drivers/usb/wusbcore
parentuwb: don't call spin_unlock_irq in a USB completion handler (diff)
downloadlinux-7584f2ebc18b6355f21be5fb2f75afbf3f781ce5.tar.xz
linux-7584f2ebc18b6355f21be5fb2f75afbf3f781ce5.zip
usb: wusbcore: convert nested lock to use spin_lock instead of spin_lock_irq
Nesting a spin_lock_irq/unlock_irq inside a lock that has already disabled interrupts will enable interrupts before we are ready when spin_unlock_irq is called. This patch converts the inner lock to use spin_lock and spin_unlock instead. Signed-off-by: Thomas Pugliese <thomas.pugliese@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/wusbcore')
-rw-r--r--drivers/usb/wusbcore/wa-xfer.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/wusbcore/wa-xfer.c b/drivers/usb/wusbcore/wa-xfer.c
index c8e2a47d62a7..3e2e4ed20157 100644
--- a/drivers/usb/wusbcore/wa-xfer.c
+++ b/drivers/usb/wusbcore/wa-xfer.c
@@ -2390,10 +2390,10 @@ error_complete:
done) {
dev_info(dev, "Control EP stall. Queue delayed work.\n");
- spin_lock_irq(&wa->xfer_list_lock);
+ spin_lock(&wa->xfer_list_lock);
/* move xfer from xfer_list to xfer_errored_list. */
list_move_tail(&xfer->list_node, &wa->xfer_errored_list);
- spin_unlock_irq(&wa->xfer_list_lock);
+ spin_unlock(&wa->xfer_list_lock);
spin_unlock_irqrestore(&xfer->lock, flags);
queue_work(wusbd, &wa->xfer_error_work);
} else {