From 40650268787afed3600e91599b7d8570be42bf96 Mon Sep 17 00:00:00 2001 From: Kieran Bingham Date: Fri, 4 Aug 2017 12:32:42 -0400 Subject: media: v4l: vsp1: Move partition rectangles to struct and operate directly As we develop the partition algorithm, we need to store more information per partition to describe the phase and other parameters. To keep this data together, further abstract the existing v4l2_rect into a partition specific structure. As partitions only have horizontal coordinates, store the left and width values only. When generating the partition windows, operate directly on the partition struct rather than copying and duplicating the processed data Signed-off-by: Kieran Bingham Reviewed-by: Laurent Pinchart Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab --- drivers/media/platform/vsp1/vsp1_rpf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'drivers/media/platform/vsp1/vsp1_rpf.c') diff --git a/drivers/media/platform/vsp1/vsp1_rpf.c b/drivers/media/platform/vsp1/vsp1_rpf.c index 8feddd59cf8d..126741f00ae3 100644 --- a/drivers/media/platform/vsp1/vsp1_rpf.c +++ b/drivers/media/platform/vsp1/vsp1_rpf.c @@ -108,9 +108,9 @@ static void rpf_configure(struct vsp1_entity *entity, output = vsp1_entity_get_pad_format(wpf, wpf->config, RWPF_PAD_SINK); - crop.width = pipe->partition.width * input_width + crop.width = pipe->partition->width * input_width / output->width; - crop.left += pipe->partition.left * input_width + crop.left += pipe->partition->left * input_width / output->width; } -- cgit v1.2.3