Commit 2f2db2f2 authored by Laurent Pinchart's avatar Laurent Pinchart Committed by Mauro Carvalho Chehab

[media] v4l: vsp1: Remove struct vsp1_pipeline num_video field

The field is always equal to the num_inputs field plus one, remove the
duplicate.
Signed-off-by: default avatarLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@osg.samsung.com>
parent faf2644d
...@@ -403,7 +403,6 @@ static void __vsp1_pipeline_cleanup(struct vsp1_pipeline *pipe) ...@@ -403,7 +403,6 @@ static void __vsp1_pipeline_cleanup(struct vsp1_pipeline *pipe)
INIT_LIST_HEAD(&pipe->entities); INIT_LIST_HEAD(&pipe->entities);
pipe->state = VSP1_PIPELINE_STOPPED; pipe->state = VSP1_PIPELINE_STOPPED;
pipe->buffers_ready = 0; pipe->buffers_ready = 0;
pipe->num_video = 0;
pipe->num_inputs = 0; pipe->num_inputs = 0;
pipe->output = NULL; pipe->output = NULL;
pipe->bru = NULL; pipe->bru = NULL;
...@@ -436,10 +435,8 @@ static int vsp1_pipeline_validate(struct vsp1_pipeline *pipe, ...@@ -436,10 +435,8 @@ static int vsp1_pipeline_validate(struct vsp1_pipeline *pipe,
struct vsp1_rwpf *rwpf; struct vsp1_rwpf *rwpf;
struct vsp1_entity *e; struct vsp1_entity *e;
if (is_media_entity_v4l2_io(entity)) { if (is_media_entity_v4l2_io(entity))
pipe->num_video++;
continue; continue;
}
subdev = media_entity_to_v4l2_subdev(entity); subdev = media_entity_to_v4l2_subdev(entity);
e = to_vsp1_entity(subdev); e = to_vsp1_entity(subdev);
...@@ -907,7 +904,7 @@ static int vsp1_video_start_streaming(struct vb2_queue *vq, unsigned int count) ...@@ -907,7 +904,7 @@ static int vsp1_video_start_streaming(struct vb2_queue *vq, unsigned int count)
int ret; int ret;
mutex_lock(&pipe->lock); mutex_lock(&pipe->lock);
if (pipe->stream_count == pipe->num_video - 1) { if (pipe->stream_count == pipe->num_inputs) {
if (pipe->uds) { if (pipe->uds) {
struct vsp1_uds *uds = to_uds(&pipe->uds->subdev); struct vsp1_uds *uds = to_uds(&pipe->uds->subdev);
......
...@@ -75,7 +75,6 @@ struct vsp1_pipeline { ...@@ -75,7 +75,6 @@ struct vsp1_pipeline {
unsigned int stream_count; unsigned int stream_count;
unsigned int buffers_ready; unsigned int buffers_ready;
unsigned int num_video;
unsigned int num_inputs; unsigned int num_inputs;
struct vsp1_rwpf *inputs[VSP1_MAX_RPF]; struct vsp1_rwpf *inputs[VSP1_MAX_RPF];
struct vsp1_rwpf *output; struct vsp1_rwpf *output;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment