summaryrefslogtreecommitdiffstats
path: root/drivers/media
diff options
context:
space:
mode:
authorJean-Francois Moine <moinejf@free.fr>2008-09-03 17:12:15 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2008-09-03 18:37:32 -0300
commit1e89e2da48070da8ac221c37fea8fa82da127c34 (patch)
tree26f748e74c1bccb4d36dd0d880cd926b5f03cb44 /drivers/media
parent65f33396ab57f3346fb07ddee8e3aa616d13386c (diff)
downloadblackbird-op-linux-1e89e2da48070da8ac221c37fea8fa82da127c34.tar.gz
blackbird-op-linux-1e89e2da48070da8ac221c37fea8fa82da127c34.zip
V4L/DVB (8818): gspca: Reinitialize the device on resume.
Signed-off-by: Jean-Francois Moine <moinejf@free.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/video/gspca/gspca.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/media/video/gspca/gspca.c b/drivers/media/video/gspca/gspca.c
index e7e73ec7134c..1767991c1f4b 100644
--- a/drivers/media/video/gspca/gspca.c
+++ b/drivers/media/video/gspca/gspca.c
@@ -1838,9 +1838,12 @@ int gspca_resume(struct usb_interface *intf)
struct gspca_dev *gspca_dev = usb_get_intfdata(intf);
gspca_dev->frozen = 0;
- if (!gspca_dev->streaming)
- return 0;
- return gspca_init_transfer(gspca_dev);
+ if (gspca_dev->users != 0) {
+ gspca_dev->sd_desc->open(gspca_dev);
+ if (gspca_dev->streaming)
+ return gspca_init_transfer(gspca_dev);
+ }
+ return 0;
}
EXPORT_SYMBOL(gspca_resume);
#endif
OpenPOWER on IntegriCloud