Commit 3aa059ae authored by Alex Dewar's avatar Alex Dewar Committed by Mauro Carvalho Chehab

media: staging: media: atomisp: Remove unnecessary if statement

The bodies of the if and else sections are the same, so just remove the
check.

Link: https://lore.kernel.org/linux-media/20201017142810.26967-2-alex.dewar90@gmail.comSigned-off-by: default avatarAlex Dewar <alex.dewar90@gmail.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab+huawei@kernel.org>
parent 32abe915
...@@ -5407,28 +5407,13 @@ static int atomisp_set_fmt_to_isp(struct video_device *vdev, ...@@ -5407,28 +5407,13 @@ static int atomisp_set_fmt_to_isp(struct video_device *vdev,
return -EINVAL; return -EINVAL;
} }
if (asd->continuous_mode->val && ret = configure_pp_input(asd, isp_sink_crop->width, isp_sink_crop->height);
(configure_pp_input == atomisp_css_preview_configure_pp_input ||
configure_pp_input == atomisp_css_video_configure_pp_input)) {
/* for isp 2.2, configure pp input is available for continuous
* mode */
ret = configure_pp_input(asd, isp_sink_crop->width,
isp_sink_crop->height);
if (ret) { if (ret) {
dev_err(isp->dev, "configure_pp_input %ux%u\n", dev_err(isp->dev, "configure_pp_input %ux%u\n",
isp_sink_crop->width, isp_sink_crop->width,
isp_sink_crop->height); isp_sink_crop->height);
return -EINVAL; return -EINVAL;
} }
} else {
ret = configure_pp_input(asd, isp_sink_crop->width,
isp_sink_crop->height);
if (ret) {
dev_err(isp->dev, "configure_pp_input %ux%u\n",
isp_sink_crop->width, isp_sink_crop->height);
return -EINVAL;
}
}
if (asd->copy_mode) if (asd->copy_mode)
ret = atomisp_css_copy_get_output_frame_info(asd, stream_index, ret = atomisp_css_copy_get_output_frame_info(asd, stream_index,
output_info); output_info);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment