Commit 5d0beeec authored by Takanari Hayama's avatar Takanari Hayama Committed by Mauro Carvalho Chehab

[media] v4l: vsp1: Always enable virtual RPF when BRU is in use

Regardless of a number of inputs, we should always enable virtual RPF
when BRU is used. This allows the case when there's only one input to
BRU, and a size of the input is smaller than a size of an output of BRU.
Signed-off-by: default avatarTakanari Hayama <taki@igel.co.jp>
Signed-off-by: default avatarLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@osg.samsung.com>
parent 857161fc
...@@ -92,19 +92,20 @@ static int wpf_s_stream(struct v4l2_subdev *subdev, int enable) ...@@ -92,19 +92,20 @@ static int wpf_s_stream(struct v4l2_subdev *subdev, int enable)
return 0; return 0;
} }
/* Sources. If the pipeline has a single input configure it as the /* Sources. If the pipeline has a single input and BRU is not used,
* master layer. Otherwise configure all inputs as sub-layers and * configure it as the master layer. Otherwise configure all
* select the virtual RPF as the master layer. * inputs as sub-layers and select the virtual RPF as the master
* layer.
*/ */
for (i = 0; i < pipe->num_inputs; ++i) { for (i = 0; i < pipe->num_inputs; ++i) {
struct vsp1_rwpf *input = pipe->inputs[i]; struct vsp1_rwpf *input = pipe->inputs[i];
srcrpf |= pipe->num_inputs == 1 srcrpf |= (!pipe->bru && pipe->num_inputs == 1)
? VI6_WPF_SRCRPF_RPF_ACT_MST(input->entity.index) ? VI6_WPF_SRCRPF_RPF_ACT_MST(input->entity.index)
: VI6_WPF_SRCRPF_RPF_ACT_SUB(input->entity.index); : VI6_WPF_SRCRPF_RPF_ACT_SUB(input->entity.index);
} }
if (pipe->num_inputs > 1) if (pipe->bru || pipe->num_inputs > 1)
srcrpf |= VI6_WPF_SRCRPF_VIRACT_MST; srcrpf |= VI6_WPF_SRCRPF_VIRACT_MST;
vsp1_wpf_write(wpf, VI6_WPF_SRCRPF, srcrpf); vsp1_wpf_write(wpf, VI6_WPF_SRCRPF, srcrpf);
......
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