mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
media: vsp1: Fix BRx conditional path in WPF
When a BRx is provided by a pipeline, the WPF must determine the master
layer. Currently the condition to check this identifies pipe->bru ||
pipe->num_inputs > 1.
The code then moves on to dereference pipe->bru, thus the check fails
static analysers on the possibility that pipe->num_inputs could be
greater than 1 without pipe->bru being set.
The reality is that the pipeline must have a BRx to support more than
one input, thus this could never cause a fault - however it also
identifies that the num_inputs > 1 check is redundant.
Remove the redundant check - and always configure the master layer
appropriately when we have a BRx configured in our pipeline.
Fixes: 6134148f60 ("v4l: vsp1: Add support for the BRS entity")
Cc: [email protected]
Suggested-by: Mauro Carvalho Chehab <[email protected]>
Signed-off-by: Kieran Bingham <[email protected]>
Reviewed-by: Laurent Pinchart <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
This commit is contained in:
parent
19ad26f9e6
commit
639fa43d59
1 changed files with 1 additions and 1 deletions
|
|
@ -452,7 +452,7 @@ static void wpf_configure(struct vsp1_entity *entity,
|
|||
: VI6_WPF_SRCRPF_RPF_ACT_SUB(input->entity.index);
|
||||
}
|
||||
|
||||
if (pipe->bru || pipe->num_inputs > 1)
|
||||
if (pipe->bru)
|
||||
srcrpf |= pipe->bru->type == VSP1_ENTITY_BRU
|
||||
? VI6_WPF_SRCRPF_VIRACT_MST
|
||||
: VI6_WPF_SRCRPF_VIRACT2_MST;
|
||||
|
|
|
|||
Loading…
Reference in a new issue