|
@@ -1428,7 +1428,7 @@ static int cam_ife_hw_mgr_release_hw_for_ctx(
|
|
|
|
|
|
/* clean up the callback function */
|
|
|
ife_ctx->common.cb_priv = NULL;
|
|
|
- memset(ife_ctx->common.event_cb, 0, sizeof(ife_ctx->common.event_cb));
|
|
|
+ ife_ctx->common.event_cb = NULL;
|
|
|
|
|
|
ife_ctx->flags.need_csid_top_cfg = false;
|
|
|
|
|
@@ -4658,9 +4658,7 @@ static int cam_ife_mgr_acquire_hw(void *hw_mgr_priv, void *acquire_hw_args)
|
|
|
|
|
|
ife_ctx->common.cb_priv = acquire_args->context_data;
|
|
|
ife_ctx->flags.internal_cdm = false;
|
|
|
- for (i = 0; i < CAM_ISP_HW_EVENT_MAX; i++)
|
|
|
- ife_ctx->common.event_cb[i] = acquire_args->event_cb;
|
|
|
-
|
|
|
+ ife_ctx->common.event_cb = acquire_args->event_cb;
|
|
|
ife_ctx->hw_mgr = ife_hw_mgr;
|
|
|
ife_ctx->cdm_ops = cam_cdm_publish_ops();
|
|
|
|
|
@@ -4967,8 +4965,7 @@ static int cam_ife_mgr_acquire_dev(void *hw_mgr_priv, void *acquire_hw_args)
|
|
|
|
|
|
ife_ctx->cdm_handle = 0;
|
|
|
ife_ctx->common.cb_priv = acquire_args->context_data;
|
|
|
- for (i = 0; i < CAM_ISP_HW_EVENT_MAX; i++)
|
|
|
- ife_ctx->common.event_cb[i] = acquire_args->event_cb;
|
|
|
+ ife_ctx->common.event_cb = acquire_args->event_cb;
|
|
|
|
|
|
ife_ctx->hw_mgr = ife_hw_mgr;
|
|
|
ife_ctx->cdm_ops = cam_cdm_publish_ops();
|
|
@@ -10371,7 +10368,6 @@ static int cam_ife_hw_mgr_find_affected_ctx(
|
|
|
struct cam_ife_hw_mgr_ctx *ife_hwr_mgr_ctx = NULL;
|
|
|
cam_hw_event_cb_func notify_err_cb;
|
|
|
struct cam_ife_hw_mgr *ife_hwr_mgr = NULL;
|
|
|
- enum cam_isp_hw_event_type event_type = CAM_ISP_HW_EVENT_ERROR;
|
|
|
uint32_t i = 0;
|
|
|
|
|
|
if (!recovery_data) {
|
|
@@ -10400,7 +10396,7 @@ static int cam_ife_hw_mgr_find_affected_ctx(
|
|
|
}
|
|
|
|
|
|
atomic_set(&ife_hwr_mgr_ctx->overflow_pending, 1);
|
|
|
- notify_err_cb = ife_hwr_mgr_ctx->common.event_cb[event_type];
|
|
|
+ notify_err_cb = ife_hwr_mgr_ctx->common.event_cb;
|
|
|
|
|
|
/* Add affected_context in list of recovery data */
|
|
|
CAM_DBG(CAM_ISP, "Add affected ctx %d to list",
|
|
@@ -10485,8 +10481,7 @@ static int cam_ife_hw_mgr_handle_csid_rup(
|
|
|
cam_hw_event_cb_func ife_hwr_irq_rup_cb;
|
|
|
struct cam_isp_hw_reg_update_event_data rup_event_data;
|
|
|
|
|
|
- ife_hwr_irq_rup_cb =
|
|
|
- ife_hw_mgr_ctx->common.event_cb[CAM_ISP_HW_EVENT_REG_UPDATE];
|
|
|
+ ife_hwr_irq_rup_cb = ife_hw_mgr_ctx->common.event_cb;
|
|
|
|
|
|
switch (event_info->res_id) {
|
|
|
case CAM_IFE_PIX_PATH_RES_IPP:
|
|
@@ -10706,8 +10701,7 @@ static int cam_ife_hw_mgr_handle_hw_rup(
|
|
|
cam_hw_event_cb_func ife_hwr_irq_rup_cb;
|
|
|
struct cam_isp_hw_reg_update_event_data rup_event_data;
|
|
|
|
|
|
- ife_hwr_irq_rup_cb =
|
|
|
- ife_hw_mgr_ctx->common.event_cb[CAM_ISP_HW_EVENT_REG_UPDATE];
|
|
|
+ ife_hwr_irq_rup_cb = ife_hw_mgr_ctx->common.event_cb;
|
|
|
|
|
|
switch (event_info->res_id) {
|
|
|
case CAM_ISP_HW_VFE_IN_CAMIF:
|
|
@@ -10759,8 +10753,7 @@ static int cam_ife_hw_mgr_handle_hw_epoch(
|
|
|
cam_hw_event_cb_func ife_hw_irq_epoch_cb;
|
|
|
struct cam_isp_hw_epoch_event_data epoch_done_event_data;
|
|
|
|
|
|
- ife_hw_irq_epoch_cb =
|
|
|
- ife_hw_mgr_ctx->common.event_cb[CAM_ISP_HW_EVENT_EPOCH];
|
|
|
+ ife_hw_irq_epoch_cb = ife_hw_mgr_ctx->common.event_cb;
|
|
|
|
|
|
switch (event_info->res_id) {
|
|
|
case CAM_ISP_HW_VFE_IN_CAMIF:
|
|
@@ -10805,8 +10798,7 @@ static int cam_ife_hw_mgr_handle_hw_sof(
|
|
|
|
|
|
memset(&sof_done_event_data, 0, sizeof(sof_done_event_data));
|
|
|
|
|
|
- ife_hw_irq_sof_cb =
|
|
|
- ife_hw_mgr_ctx->common.event_cb[CAM_ISP_HW_EVENT_SOF];
|
|
|
+ ife_hw_irq_sof_cb = ife_hw_mgr_ctx->common.event_cb;
|
|
|
|
|
|
switch (event_info->res_id) {
|
|
|
case CAM_ISP_HW_VFE_IN_CAMIF:
|
|
@@ -10881,8 +10873,7 @@ static int cam_ife_hw_mgr_handle_hw_eof(
|
|
|
cam_hw_event_cb_func ife_hw_irq_eof_cb;
|
|
|
struct cam_isp_hw_eof_event_data eof_done_event_data;
|
|
|
|
|
|
- ife_hw_irq_eof_cb =
|
|
|
- ife_hw_mgr_ctx->common.event_cb[CAM_ISP_HW_EVENT_EOF];
|
|
|
+ ife_hw_irq_eof_cb = ife_hw_mgr_ctx->common.event_cb;
|
|
|
|
|
|
switch (event_info->res_id) {
|
|
|
case CAM_ISP_HW_VFE_IN_CAMIF:
|
|
@@ -10973,8 +10964,7 @@ static int cam_ife_hw_mgr_handle_hw_buf_done(
|
|
|
struct cam_isp_hw_event_info *event_info = evt_info;
|
|
|
int32_t rc = 0;
|
|
|
|
|
|
- ife_hwr_irq_wm_done_cb =
|
|
|
- ife_hw_mgr_ctx->common.event_cb[CAM_ISP_HW_EVENT_DONE];
|
|
|
+ ife_hwr_irq_wm_done_cb = ife_hw_mgr_ctx->common.event_cb;
|
|
|
|
|
|
buf_done_event_data.num_handles = 1;
|
|
|
buf_done_event_data.resource_handle[0] = event_info->res_id;
|