]> Pileus Git - ~andy/linux/blobdiff - drivers/media/usb/gspca/zc3xx.c
[media] gspca: Update / fix various comments wrt workqueue usb_lock usage
[~andy/linux] / drivers / media / usb / gspca / zc3xx.c
index 234d9eaa8eea31e5edf4b02e02e85c8de01b825d..c47ba14c76190ebaa89ff62463e7ad7b2d82388f 100644 (file)
@@ -5945,6 +5945,7 @@ static void transfer_update(struct work_struct *work)
        for (;;) {
                msleep(100);
 
+               /* To protect gspca_dev->usb_buf and gspca_dev->usb_err */
                mutex_lock(&gspca_dev->usb_lock);
 #ifdef CONFIG_PM
                if (gspca_dev->frozen)
@@ -6831,7 +6832,8 @@ static int sd_start(struct gspca_dev *gspca_dev)
        return 0;
 }
 
-/* called on streamoff with alt 0 and on disconnect */
+/* called on streamoff with alt==0 and on disconnect */
+/* the usb_lock is held at entry - restore on exit */
 static void sd_stop0(struct gspca_dev *gspca_dev)
 {
        struct sd *sd = (struct sd *) gspca_dev;