kernel: bump 4.19 to 4.19.62
[openwrt/staging/chunkeey.git] / target / linux / brcm2708 / patches-4.19 / 950-0242-staging-bcm2835-camera-Return-early-on-errors.patch
index 5dc558a7e365f7f5435d82a480065ca26ff047bd..5ccb2850d530d7c41bf3e50f180d2ded7a67fc7a 100644 (file)
@@ -24,10 +24,10 @@ Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
 +
 +      if (length == 0) {
                /* stream ended */
-               if (buf) {
-                       /* this should only ever happen if the port is
-@@ -358,71 +360,72 @@ static void buffer_cb(struct vchiq_mmal_
-                       /* signal frame completion */
+               if (dev->capture.frame_count) {
+                       /* empty buffer whilst capturing - expected to be an
+@@ -361,71 +363,72 @@ static void buffer_cb(struct vchiq_mmal_
+                       vb2_buffer_done(&buf->vb.vb2_buf, VB2_BUF_STATE_ERROR);
                        complete(&dev->capture.frame_cmplt);
                }
 -      } else {
@@ -158,7 +158,7 @@ Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
  }
  
  static int enable_camera(struct bm2835_mmal_dev *dev)
-@@ -802,27 +805,29 @@ static int vidioc_overlay(struct file *f
+@@ -815,27 +818,29 @@ static int vidioc_overlay(struct file *f
  
        ret = vchiq_mmal_port_set_format(dev->instance, src);
        if (ret < 0)