diff options
Diffstat (limited to 'drivers/media/video/gspca/finepix.c')
-rw-r--r-- | drivers/media/video/gspca/finepix.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/media/video/gspca/finepix.c b/drivers/media/video/gspca/finepix.c index 65d3cbfe6b27..607942fd7970 100644 --- a/drivers/media/video/gspca/finepix.c +++ b/drivers/media/video/gspca/finepix.c | |||
@@ -276,6 +276,12 @@ static void sd_stopN(struct gspca_dev *gspca_dev) | |||
276 | /* Stop the state machine */ | 276 | /* Stop the state machine */ |
277 | if (dev->state != FPIX_NOP) | 277 | if (dev->state != FPIX_NOP) |
278 | wait_for_completion(&dev->can_close); | 278 | wait_for_completion(&dev->can_close); |
279 | } | ||
280 | |||
281 | /* called on streamoff with alt 0 and disconnect */ | ||
282 | static void sd_stop0(struct gspca_dev *gspca_dev) | ||
283 | { | ||
284 | struct usb_fpix *dev = (struct usb_fpix *) gspca_dev; | ||
279 | 285 | ||
280 | usb_free_urb(dev->control_urb); | 286 | usb_free_urb(dev->control_urb); |
281 | dev->control_urb = NULL; | 287 | dev->control_urb = NULL; |
@@ -385,6 +391,7 @@ static int sd_start(struct gspca_dev *gspca_dev) | |||
385 | error: | 391 | error: |
386 | /* Free the ressources */ | 392 | /* Free the ressources */ |
387 | sd_stopN(gspca_dev); | 393 | sd_stopN(gspca_dev); |
394 | sd_stop0(gspca_dev); | ||
388 | return ret; | 395 | return ret; |
389 | } | 396 | } |
390 | 397 | ||
@@ -425,6 +432,7 @@ static const struct sd_desc sd_desc = { | |||
425 | .init = sd_init, | 432 | .init = sd_init, |
426 | .start = sd_start, | 433 | .start = sd_start, |
427 | .stopN = sd_stopN, | 434 | .stopN = sd_stopN, |
435 | .stop0 = sd_stop0, | ||
428 | }; | 436 | }; |
429 | 437 | ||
430 | /* -- device connect -- */ | 438 | /* -- device connect -- */ |