mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-14 18:06:48 +07:00
media: rcar-vin: Do not reset the crop and compose rectangles in s_fmt
The crop and compose rectangles are reset when s_fmt is called resulting in potentially valid rectangles being lost when updating the format. Fix this by mapping the rectangles inside the new format. Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
This commit is contained in:
parent
20aca4a33b
commit
104464f573
@ -283,8 +283,8 @@ static int rvin_s_fmt_vid_cap(struct file *file, void *priv,
|
||||
return ret;
|
||||
|
||||
vin->format = f->fmt.pix;
|
||||
vin->crop = crop;
|
||||
vin->compose = compose;
|
||||
v4l2_rect_map_inside(&vin->crop, &crop);
|
||||
v4l2_rect_map_inside(&vin->compose, &compose);
|
||||
vin->src_rect = crop;
|
||||
|
||||
return 0;
|
||||
|
Loading…
Reference in New Issue
Block a user