diff options
-rw-r--r-- | drivers/staging/rspiusb/rspiusb.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/staging/rspiusb/rspiusb.c b/drivers/staging/rspiusb/rspiusb.c index 2f8155c1968b..04e2f92c0f62 100644 --- a/drivers/staging/rspiusb/rspiusb.c +++ b/drivers/staging/rspiusb/rspiusb.c | |||
@@ -716,6 +716,8 @@ static int MapUserBuffer(struct ioctl_struct *io, struct device_extension *pdx) | |||
716 | pdx->PixelUrb[frameInfo][i]->transfer_flags = | 716 | pdx->PixelUrb[frameInfo][i]->transfer_flags = |
717 | URB_NO_TRANSFER_DMA_MAP | URB_NO_INTERRUPT; | 717 | URB_NO_TRANSFER_DMA_MAP | URB_NO_INTERRUPT; |
718 | } | 718 | } |
719 | if (i == 0) | ||
720 | return -EINVAL; | ||
719 | /* only interrupt when last URB completes */ | 721 | /* only interrupt when last URB completes */ |
720 | pdx->PixelUrb[frameInfo][--i]->transfer_flags &= ~URB_NO_INTERRUPT; | 722 | pdx->PixelUrb[frameInfo][--i]->transfer_flags &= ~URB_NO_INTERRUPT; |
721 | pdx->pendedPixelUrbs[frameInfo] = | 723 | pdx->pendedPixelUrbs[frameInfo] = |