OSDN Git Service

media: vsp1: Use vb2_queue_is_busy()
authorLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Fri, 18 Mar 2022 18:01:03 +0000 (19:01 +0100)
committerMauro Carvalho Chehab <mchehab@kernel.org>
Fri, 13 May 2022 09:02:21 +0000 (11:02 +0200)
Use the new vb2_queue_is_busy() helper to replace the open-coded
version.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
drivers/media/platform/renesas/vsp1/vsp1_video.c

index 0180ffc..51219b1 100644 (file)
@@ -1030,7 +1030,7 @@ vsp1_video_streamon(struct file *file, void *fh, enum v4l2_buf_type type)
        struct vsp1_pipeline *pipe;
        int ret;
 
-       if (video->queue.owner && video->queue.owner != file->private_data)
+       if (vb2_queue_is_busy(&video->queue, file))
                return -EBUSY;
 
        /*