Commit 405dac89 authored by Hans de Goede's avatar Hans de Goede Committed by Mauro Carvalho Chehab

media: atomisp: Drop unnecessary first_streamoff check

Drop an unnecessary first_streamoff check from atomisp_streamoff(),
above the check there is a:

	if (!first_streamoff)
		goto stop_sensor;

Code block which will jump over the code with the test, so the test
is only executed when first_streamoff is true and therefor the test
is not necessary.
Reviewed-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: default avatarHans de Goede <hdegoede@redhat.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@kernel.org>
parent d7306735
...@@ -1880,10 +1880,10 @@ int atomisp_streamoff(struct file *file, void *fh, enum v4l2_buf_type type) ...@@ -1880,10 +1880,10 @@ int atomisp_streamoff(struct file *file, void *fh, enum v4l2_buf_type type)
cancel_work_sync(&asd->delayed_init_work); cancel_work_sync(&asd->delayed_init_work);
asd->delayed_init = ATOMISP_DELAYED_INIT_NOT_QUEUED; asd->delayed_init = ATOMISP_DELAYED_INIT_NOT_QUEUED;
} }
if (first_streamoff) {
css_pipe_id = atomisp_get_css_pipe_id(asd); css_pipe_id = atomisp_get_css_pipe_id(asd);
atomisp_css_stop(asd, css_pipe_id, false); atomisp_css_stop(asd, css_pipe_id, false);
}
/* cancel work queue*/ /* cancel work queue*/
if (asd->video_out_capture.users) { if (asd->video_out_capture.users) {
capture_pipe = &asd->video_out_capture; capture_pipe = &asd->video_out_capture;
......
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