summaryrefslogtreecommitdiff
path: root/drivers/media/video/gspca/vicam.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/video/gspca/vicam.c')
-rw-r--r--drivers/media/video/gspca/vicam.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/media/video/gspca/vicam.c b/drivers/media/video/gspca/vicam.c
index e48ec4db6da4..432d6cd99cd6 100644
--- a/drivers/media/video/gspca/vicam.c
+++ b/drivers/media/video/gspca/vicam.c
@@ -225,7 +225,7 @@ static void vicam_dostream(struct work_struct *work)
goto exit;
}
- while (gspca_dev->present && gspca_dev->streaming) {
+ while (!gspca_dev->frozen && gspca_dev->dev && gspca_dev->streaming) {
ret = vicam_read_frame(gspca_dev, buffer, frame_sz);
if (ret < 0)
break;
@@ -327,7 +327,7 @@ static void sd_stop0(struct gspca_dev *gspca_dev)
dev->work_thread = NULL;
mutex_lock(&gspca_dev->usb_lock);
- if (gspca_dev->present)
+ if (gspca_dev->dev)
vicam_set_camera_power(gspca_dev, 0);
}