mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
synced 2026-10-09 18:15:49 +00:00
media: atomisp: Remove atomisp_try_fmt() call from atomisp_set_fmt()
atomisp_set_fmt() first calls:
v4l2_subdev_call(isp->inputs[asd->input_curr].camera,
pad, set_fmt, ...);
with v4l2_subdev_format.which set to V4L2_SUBDEV_FORMAT_ACTIVE and then
reduces width + height by padding_w / padding_h followed by calling
atomisp_try_fmt() which then sets res_overflow if the requested resolution
is larger then the sensor's max resolution, but that will never happen
since we are requesting for the result of a set_fmt call minus padding,
so res_overflow will always be false.
And when called with a res_overflow parameter, combined with there
being no overflow then atomisp_try_fmt() does not change the passed
in width/height.
Except when using JPEG or CUSTOM_M10MO_RAW as pixelformat, then
atomisp_try_fmt() does change the width/height but in that case
atomisp_set_fmt actually restores the old widht/height which it
has saved before the atomisp_try_fmt() call. So this too is a no-op.
TL;DR: The atomisp_try_fmt() call in atomisp_set_fmt() is a no-op,
remove it.
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
This commit is contained in:
parent
ec1d974fcf
commit
df1697fa17
1 changed files with 6 additions and 50 deletions
Loading…
Add table
Add a link
Reference in a new issue