From 7b905f0583b2e6fe1494a85303a89aa0cd30b0b3 Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Tue, 17 Nov 2015 13:10:26 -0200 Subject: [media] v4l: vsp1: Create a new configure operation to setup modules The subdev s_stream operation is abused as a generic way to setup modules at every frame. Move the code out to a new VSP1 entity configure operation. Most modules now have an empty s_stream operation that can be removed. The only exception is the WPF module that needs to perform hardware configuration when stopping the stream. The code can be simplified accordingly as we know that that operation never fails. Signed-off-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab --- drivers/media/platform/vsp1/vsp1_entity.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'drivers/media/platform/vsp1/vsp1_entity.h') diff --git a/drivers/media/platform/vsp1/vsp1_entity.h b/drivers/media/platform/vsp1/vsp1_entity.h index f7a360823373..fe164f3163bc 100644 --- a/drivers/media/platform/vsp1/vsp1_entity.h +++ b/drivers/media/platform/vsp1/vsp1_entity.h @@ -59,10 +59,13 @@ struct vsp1_route { * @set_memory: Setup memory buffer access. This operation applies the settings * stored in the rwpf mem field to the hardware. Valid for RPF and * WPF only. + * @configure: Setup the hardware based on the entity state (pipeline, formats, + * selection rectangles, ...) */ struct vsp1_entity_operations { void (*destroy)(struct vsp1_entity *); void (*set_memory)(struct vsp1_entity *); + void (*configure)(struct vsp1_entity *); }; struct vsp1_entity { -- cgit v1.2.3-55-g7522