diff options
author | Meera Gande <mgande@codeaurora.org> | 2019-12-31 14:23:36 +0530 |
---|---|---|
committer | Sumalatha Malothu <smalot@codeaurora.org> | 2020-02-10 14:51:27 +0530 |
commit | 0f793d310e340ee8873c413c3c828ae4642711d5 (patch) | |
tree | 489941f79ec11c5c90ef1743347a3c66e4b31e32 /drivers/media | |
parent | f1a61bc4b50922e542f3af2d0325198268520884 (diff) |
mm-camera2:isp2: Notify dual cam drop
In case of drop due to sw sync logic in
dual camera, need to update the isp page
with the number of frames that are dropped.
Change-Id: I18c4bbf781a5f1f2bf2f48518464b2e459ac7892
Signed-off-by: Meera Gande <mgande@codeaurora.org>
Signed-off-by: Sumalatha Malothu <smalot@codeaurora.org>
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/platform/msm/camera_v2/isp/msm_isp_axi_util.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/drivers/media/platform/msm/camera_v2/isp/msm_isp_axi_util.c b/drivers/media/platform/msm/camera_v2/isp/msm_isp_axi_util.c index 1af55fe257af..9d83bf2a4ad4 100644 --- a/drivers/media/platform/msm/camera_v2/isp/msm_isp_axi_util.c +++ b/drivers/media/platform/msm/camera_v2/isp/msm_isp_axi_util.c @@ -1,4 +1,4 @@ -/* Copyright (c) 2013-2019, The Linux Foundation. All rights reserved. +/* Copyright (c) 2013-2020, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and @@ -879,6 +879,9 @@ static void msm_isp_sync_dual_cam_frame_id( ms_res->src_info[i]->dual_hw_ms_info.index); } } + /* the number of frames that are dropped */ + vfe_dev->isp_page->dual_cam_drop = + frame_id - (src_info->frame_id + 1); ms_res->active_src_mask |= (1 << src_info->dual_hw_ms_info.index); src_info->frame_id = frame_id; src_info->dual_hw_ms_info.sync_state = MSM_ISP_DUAL_CAM_SYNC; @@ -916,6 +919,8 @@ void msm_isp_increment_frame_id(struct vfe_device *vfe_dev, src_info->dual_hw_ms_info.index)) { pr_err_ratelimited("Frame out of sync on vfe %d\n", vfe_dev->pdev->id); + /* Notify to do reconfig at SW sync drop*/ + vfe_dev->isp_page->dual_cam_drop_detected = 1; /* * set this isp as async mode to force *it sync again at the next sof @@ -2258,8 +2263,8 @@ static int msm_isp_process_done_buf(struct vfe_device *vfe_dev, MSM_ISP_BUFFER_STATE_PUT_BUF; buf->buf_debug.put_state_last ^= 1; rc = vfe_dev->buf_mgr->ops->buf_done(vfe_dev->buf_mgr, - buf->bufq_handle, buf->buf_idx, time_stamp, - frame_id, stream_info->runtime_output_format); + buf->bufq_handle, buf->buf_idx, time_stamp, + frame_id, stream_info->runtime_output_format); if (rc == -EFAULT) { msm_isp_halt_send_error(vfe_dev, ISP_EVENT_BUF_FATAL_ERROR); |