summaryrefslogtreecommitdiff
path: root/drivers/usb/wusbcore/devconnect.c
diff options
context:
space:
mode:
authorDavid Vrabel <david.vrabel@csr.com>2009-04-08 21:36:32 +0400
committerGreg Kroah-Hartman <gregkh@suse.de>2009-04-17 21:50:28 +0400
commit5936ac7f93965931c508e1928d142076998ce65d (patch)
treeab6eafd9032dd6bf4b9b35d1c799745de2487000 /drivers/usb/wusbcore/devconnect.c
parent8db324ec4322a15cf8819b8a7f0eff5aa98b2ff6 (diff)
downloadlinux-5936ac7f93965931c508e1928d142076998ce65d.tar.xz
WUSB: fix oops when completing URBs for disconnected devices
Fix an oops in wusbhc_giveback_urb() if the wusb device had disconnected while an urb was in progress. Also release the ref count obtained here. Signed-off-by: David Vrabel <david.vrabel@csr.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/wusbcore/devconnect.c')
-rw-r--r--drivers/usb/wusbcore/devconnect.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/usb/wusbcore/devconnect.c b/drivers/usb/wusbcore/devconnect.c
index 63f200e4efb1..4ac4300a3f9a 100644
--- a/drivers/usb/wusbcore/devconnect.c
+++ b/drivers/usb/wusbcore/devconnect.c
@@ -267,6 +267,8 @@ static void wusbhc_devconnect_acked_work(struct work_struct *work)
mutex_lock(&wusbhc->mutex);
wusbhc_devconnect_acked(wusbhc, wusb_dev);
mutex_unlock(&wusbhc->mutex);
+
+ wusb_dev_put(wusb_dev);
}
/*