Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ae026700 authored by Venu Yeshala's avatar Venu Yeshala
Browse files

msm: camera: isp: Simplify updating burst count in reset case



During axi reset burst count value needs to be restored.
It can be updated directly without a call to the framedrop API.
This simplifies code logic and avoids unnecessay initializations
needed when using the API.

Change-Id: Ib13a2af724517b74aa0842cb72c833fb1f643920
CRs-fixed: 708260
Signed-off-by: default avatarVenu Yeshala <vyeshala@codeaurora.org>
parent 191ce512
Loading
Loading
Loading
Loading
+7 −9
Original line number Diff line number Diff line
@@ -1399,21 +1399,19 @@ static void msm_isp_process_overflow_irq(
void msm_isp_reset_burst_count_and_frame_drop(
	struct vfe_device *vfe_dev, struct msm_vfe_axi_stream *stream_info)
{
	struct msm_vfe_axi_stream_request_cmd stream_cfg_cmd;
	uint32_t framedrop_period = 0;
	if (stream_info->state != ACTIVE ||
		stream_info->stream_type != BURST_STREAM) {
		return;
	}
	if (stream_info->stream_type == BURST_STREAM &&
		stream_info->num_burst_capture != 0) {
		stream_cfg_cmd.burst_count =
			stream_info->num_burst_capture;
		stream_cfg_cmd.frame_skip_pattern =
			stream_info->frame_skip_pattern;
		stream_cfg_cmd.init_frame_drop =
			stream_info->init_frame_drop;
		msm_isp_calculate_framedrop(&vfe_dev->axi_data,
			&stream_cfg_cmd);
		framedrop_period = msm_isp_get_framedrop_period(
		   stream_info->frame_skip_pattern);
		stream_info->burst_frame_count =
			stream_info->init_frame_drop +
			(stream_info->num_burst_capture - 1) *
			framedrop_period + 1;
		msm_isp_reset_framedrop(vfe_dev, stream_info);
	}
}