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

Commit 7448e927 authored by Nagesh Subba Reddy's avatar Nagesh Subba Reddy Committed by Gerrit - the friendly Code Review server
Browse files

msm: Camera: Update the burst frame count



Intial sensor frame skip is applicable only for first stream,
Ignore sensor frame skip when streaming is in progress.

Change-Id: Iff8b35bf571ef6e56c4a3d6fd54fa67ec09460f9
Signed-off-by: default avatarNagesh Subba Reddy <nageshsreddy@codeaurora.org>
parent 6ced5906
Loading
Loading
Loading
Loading
+20 −8
Original line number Diff line number Diff line
@@ -461,6 +461,7 @@ void msm_isp_update_framedrop_reg(struct vfe_device *vfe_dev,
			(SRC_TO_INTF(stream_info->stream_src) == frame_src)) {
			if (stream_info->runtime_framedrop_update_burst) {
				stream_info->runtime_framedrop_update_burst = 0;

				stream_info->runtime_burst_frame_count =
					stream_info->runtime_init_frame_drop +
					(stream_info->runtime_num_burst_capture
@@ -469,11 +470,10 @@ void msm_isp_update_framedrop_reg(struct vfe_device *vfe_dev,
				msm_isp_cfg_framedrop_reg(vfe_dev, stream_info);
			} else {
				stream_info->runtime_burst_frame_count--;
				if ((stream_info->
					runtime_burst_frame_count <
				if ((stream_info->runtime_burst_frame_count <
					BURST_SKIP_THRESHOLD) &&
				    (stream_info->
					runtime_burst_frame_count >= 0)) {
					(stream_info->runtime_burst_frame_count
					>= 0)) {
					msm_isp_cfg_framedrop_reg(vfe_dev,
						stream_info);
				}
@@ -486,8 +486,19 @@ void msm_isp_reset_framedrop(struct vfe_device *vfe_dev,
	struct msm_vfe_axi_stream *stream_info)
{
	stream_info->runtime_init_frame_drop = stream_info->init_frame_drop;
	/*
	 * While deriving burst_frame_count, Initial frame skip
	 * is taken into consideration But if skip frame has already
	 * passed, burst count has to be updated accordingly
	 */
	if (vfe_dev->axi_data.src_info[VFE_PIX_0].frame_id == 0)
		stream_info->runtime_burst_frame_count =
			stream_info->burst_frame_count;
	else
		stream_info->runtime_burst_frame_count =
			stream_info->burst_frame_count -
			stream_info->runtime_init_frame_drop;

	stream_info->runtime_num_burst_capture =
		stream_info->num_burst_capture;
	stream_info->runtime_framedrop_update = stream_info->framedrop_update;
@@ -677,6 +688,7 @@ int msm_isp_request_axi_stream(struct vfe_device *vfe_dev, void *arg)

	stream_info->memory_input = stream_cfg_cmd->memory_input;


	msm_isp_axi_reserve_wm(&vfe_dev->axi_data, stream_info);

	if (stream_info->stream_src < RDI_INTF_0) {