Skip to content

Commit

Permalink
[media] v4l: vsp1: Fix wrong entities links creation
Browse files Browse the repository at this point in the history
The Media Control framework now requires entities to be registered with
the media device before creating links so commit c7621b3 ("[media]
v4l: vsp1: separate links creation from entities init") separated link
creation from entities init.

But unfortunately that patch introduced a regression since wrong links
were created causing a boot failure on Renesas boards.

This patch fixes the boot issue and also the media graph was compared
by Geert Uytterhoeven to make sure that the driver changes required by
the Media Control framework next generation did not affect the graph.

Reported-by: Geert Uytterhoeven <[email protected]>
Signed-off-by: Javier Martinez Canillas <[email protected]>
Tested-by: Geert Uytterhoeven <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
  • Loading branch information
Javier Martinez Canillas authored and mchehab committed Jan 25, 2016
1 parent 92e963f commit 5017e1b
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions drivers/media/platform/vsp1/vsp1_drv.c
Original file line number Diff line number Diff line change
Expand Up @@ -256,15 +256,18 @@ static int vsp1_create_entities(struct vsp1_device *vsp1)

/* Create links. */
list_for_each_entry(entity, &vsp1->entities, list_dev) {
if (entity->type == VSP1_ENTITY_LIF) {
if (entity->type == VSP1_ENTITY_WPF) {
ret = vsp1_wpf_create_links(vsp1, entity);
if (ret < 0)
goto done;
} else if (entity->type == VSP1_ENTITY_RPF) {
ret = vsp1_rpf_create_links(vsp1, entity);
if (ret < 0)
goto done;
} else {
}

if (entity->type != VSP1_ENTITY_LIF &&
entity->type != VSP1_ENTITY_RPF) {
ret = vsp1_create_links(vsp1, entity);
if (ret < 0)
goto done;
Expand Down

0 comments on commit 5017e1b

Please sign in to comment.