diff options
| author | Malcolm Priestley <tvboxspy@gmail.com> | 2014-02-17 21:16:20 +0000 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-02-18 11:01:01 -0800 |
| commit | c98fbf9075e61a611edbb35475f2001197ca113e (patch) | |
| tree | f3823dfda291b130f5232edb4e6f39246bf1edcb | |
| parent | 247b4b68b1cb65a2c2051f34415b455020fa8c10 (diff) | |
staging: vt6656: s_nsInterruptUsbIoCompleteRead add urb status returns
Drop out of urb return on usb errors and set intBuf.bInUse to false.
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
| -rw-r--r-- | drivers/staging/vt6656/usbpipe.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/staging/vt6656/usbpipe.c b/drivers/staging/vt6656/usbpipe.c index 258eec13b8df..d18cb2f0fb41 100644 --- a/drivers/staging/vt6656/usbpipe.c +++ b/drivers/staging/vt6656/usbpipe.c @@ -364,6 +364,19 @@ static void s_nsInterruptUsbIoCompleteRead(struct urb *urb) // 4) The irp was cancelled. // 5) Some other failure from the USB device object. // + switch (urb->status) { + case 0: + case -ETIMEDOUT: + break; + case -ECONNRESET: + case -ENOENT: + case -ESHUTDOWN: + pDevice->intBuf.bInUse = false; + return; + default: + break; + } + ntStatus = urb->status; DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO"s_nsInterruptUsbIoCompleteRead Status %d\n", ntStatus); |
