Loading drivers/cam_isp/isp_hw_mgr/cam_ife_hw_mgr.c +15 −17 Original line number Diff line number Diff line Loading @@ -3540,6 +3540,7 @@ static int cam_ife_mgr_config_hw(void *hw_mgr_priv, struct cam_cdm_bl_request *cdm_cmd; struct cam_ife_hw_mgr_ctx *ctx; struct cam_isp_prepare_hw_update_data *hw_update_data; unsigned long rem_jiffies = 0; if (!hw_mgr_priv || !config_hw_args) { CAM_ERR(CAM_ISP, Loading Loading @@ -3652,22 +3653,19 @@ static int cam_ife_mgr_config_hw(void *hw_mgr_priv, } if (cfg->init_packet) { rc = wait_for_completion_timeout( rem_jiffies = wait_for_completion_timeout( &ctx->config_done_complete, msecs_to_jiffies(30)); if (rc <= 0) { if (rem_jiffies == 0) { CAM_ERR(CAM_ISP, "config done completion timeout for req_id=%llu rc=%d ctx_index %d", cfg->request_id, rc, ctx->ctx_index); if (rc == 0) "config done completion timeout for req_id=%llu ctx_index %d", cfg->request_id, ctx->ctx_index); rc = -ETIMEDOUT; } else { rc = 0; } else CAM_DBG(CAM_ISP, "config done Success for req_id=%llu ctx_index %d", cfg->request_id, ctx->ctx_index); } } } else { CAM_ERR(CAM_ISP, "No commands to config"); } Loading Loading @@ -3814,6 +3812,7 @@ static int cam_ife_mgr_stop_hw(void *hw_mgr_priv, void *stop_hw_args) struct cam_ife_hw_mgr_ctx *ctx; enum cam_ife_csid_halt_cmd csid_halt_type; uint32_t i, master_base_idx = 0; unsigned long rem_jiffies = 0; if (!hw_mgr_priv || !stop_hw_args) { CAM_ERR(CAM_ISP, "Invalid arguments"); Loading Loading @@ -3913,9 +3912,9 @@ static int cam_ife_mgr_stop_hw(void *hw_mgr_priv, void *stop_hw_args) cam_ife_mgr_pause_hw(ctx); rc = wait_for_completion_timeout(&ctx->config_done_complete, rem_jiffies = wait_for_completion_timeout(&ctx->config_done_complete, msecs_to_jiffies(10)); if (rc == 0) { if (rem_jiffies == 0) { CAM_WARN(CAM_ISP, "config done completion timeout for last applied req_id=%llu rc=%d ctx_index %d", ctx->applied_req_id, rc, ctx->ctx_index); Loading Loading @@ -6147,6 +6146,7 @@ static int cam_ife_mgr_cmd(void *hw_mgr_priv, void *cmd_args) hw_cmd_args->ctxt_to_hw_map; struct cam_isp_hw_cmd_args *isp_hw_cmd_args = NULL; struct cam_packet *packet; unsigned long rem_jiffies = 0; if (!hw_mgr_priv || !cmd_args) { CAM_ERR(CAM_ISP, "Invalid arguments"); Loading Loading @@ -6220,15 +6220,13 @@ static int cam_ife_mgr_cmd(void *hw_mgr_priv, void *cmd_args) if (ctx->last_dump_flush_req_id == ctx->applied_req_id) return 0; rc = wait_for_completion_timeout( rem_jiffies = wait_for_completion_timeout( &ctx->config_done_complete, msecs_to_jiffies(30)); if (rc <= 0) { if (rem_jiffies == 0) CAM_ERR(CAM_ISP, "config done completion timeout, Reg dump will be unreliable rc=%d ctx_index %d", rc, ctx->ctx_index); rc = 0; } "config done completion timeout, Reg dump will be unreliable ctx_index %d", ctx->ctx_index); ctx->last_dump_flush_req_id = ctx->applied_req_id; rc = cam_ife_mgr_handle_reg_dump(ctx, ctx->reg_dump_buf_desc, Loading drivers/cam_isp/isp_hw_mgr/isp_hw/ife_csid_hw/cam_ife_csid_core.c +9 −10 Original line number Diff line number Diff line Loading @@ -3284,7 +3284,7 @@ static int cam_ife_csid_reset_regs( csid_hw->csid_info->csid_reg; struct cam_hw_soc_info *soc_info; uint32_t val = 0; unsigned long flags; unsigned long flags, rem_jiffies = 0; soc_info = &csid_hw->hw_info->soc_info; Loading Loading @@ -3327,9 +3327,9 @@ static int cam_ife_csid_reset_regs( spin_unlock_irqrestore(&csid_hw->hw_info->hw_lock, flags); CAM_DBG(CAM_ISP, "CSID reset start"); rc = wait_for_completion_timeout(&csid_hw->csid_top_complete, rem_jiffies = wait_for_completion_timeout(&csid_hw->csid_top_complete, msecs_to_jiffies(IFE_CSID_TIMEOUT)); if (rc <= 0) { if (rem_jiffies == 0) { val = cam_io_r_mb(soc_info->reg_map[0].mem_base + csid_reg->cmn_reg->csid_top_irq_status_addr); if (val & 0x1) { Loading @@ -3341,19 +3341,18 @@ static int cam_ife_csid_reset_regs( CAM_DBG(CAM_ISP, "CSID:%d %s reset completed %d", csid_hw->hw_intf->hw_idx, reset_hw ? "hw" : "sw", rc); rc = 0; rem_jiffies); goto end; } CAM_ERR(CAM_ISP, "CSID:%d csid_reset %s fail rc = %d", csid_hw->hw_intf->hw_idx, reset_hw ? "hw" : "sw", rc); csid_hw->hw_intf->hw_idx, reset_hw ? "hw" : "sw", rem_jiffies); rc = -ETIMEDOUT; goto end; } else { } else CAM_DBG(CAM_ISP, "CSID:%d %s reset completed %d", csid_hw->hw_intf->hw_idx, reset_hw ? "hw" : "sw", rc); rc = 0; } csid_hw->hw_intf->hw_idx, reset_hw ? "hw" : "sw", rem_jiffies); end: return rc; Loading Loading
drivers/cam_isp/isp_hw_mgr/cam_ife_hw_mgr.c +15 −17 Original line number Diff line number Diff line Loading @@ -3540,6 +3540,7 @@ static int cam_ife_mgr_config_hw(void *hw_mgr_priv, struct cam_cdm_bl_request *cdm_cmd; struct cam_ife_hw_mgr_ctx *ctx; struct cam_isp_prepare_hw_update_data *hw_update_data; unsigned long rem_jiffies = 0; if (!hw_mgr_priv || !config_hw_args) { CAM_ERR(CAM_ISP, Loading Loading @@ -3652,22 +3653,19 @@ static int cam_ife_mgr_config_hw(void *hw_mgr_priv, } if (cfg->init_packet) { rc = wait_for_completion_timeout( rem_jiffies = wait_for_completion_timeout( &ctx->config_done_complete, msecs_to_jiffies(30)); if (rc <= 0) { if (rem_jiffies == 0) { CAM_ERR(CAM_ISP, "config done completion timeout for req_id=%llu rc=%d ctx_index %d", cfg->request_id, rc, ctx->ctx_index); if (rc == 0) "config done completion timeout for req_id=%llu ctx_index %d", cfg->request_id, ctx->ctx_index); rc = -ETIMEDOUT; } else { rc = 0; } else CAM_DBG(CAM_ISP, "config done Success for req_id=%llu ctx_index %d", cfg->request_id, ctx->ctx_index); } } } else { CAM_ERR(CAM_ISP, "No commands to config"); } Loading Loading @@ -3814,6 +3812,7 @@ static int cam_ife_mgr_stop_hw(void *hw_mgr_priv, void *stop_hw_args) struct cam_ife_hw_mgr_ctx *ctx; enum cam_ife_csid_halt_cmd csid_halt_type; uint32_t i, master_base_idx = 0; unsigned long rem_jiffies = 0; if (!hw_mgr_priv || !stop_hw_args) { CAM_ERR(CAM_ISP, "Invalid arguments"); Loading Loading @@ -3913,9 +3912,9 @@ static int cam_ife_mgr_stop_hw(void *hw_mgr_priv, void *stop_hw_args) cam_ife_mgr_pause_hw(ctx); rc = wait_for_completion_timeout(&ctx->config_done_complete, rem_jiffies = wait_for_completion_timeout(&ctx->config_done_complete, msecs_to_jiffies(10)); if (rc == 0) { if (rem_jiffies == 0) { CAM_WARN(CAM_ISP, "config done completion timeout for last applied req_id=%llu rc=%d ctx_index %d", ctx->applied_req_id, rc, ctx->ctx_index); Loading Loading @@ -6147,6 +6146,7 @@ static int cam_ife_mgr_cmd(void *hw_mgr_priv, void *cmd_args) hw_cmd_args->ctxt_to_hw_map; struct cam_isp_hw_cmd_args *isp_hw_cmd_args = NULL; struct cam_packet *packet; unsigned long rem_jiffies = 0; if (!hw_mgr_priv || !cmd_args) { CAM_ERR(CAM_ISP, "Invalid arguments"); Loading Loading @@ -6220,15 +6220,13 @@ static int cam_ife_mgr_cmd(void *hw_mgr_priv, void *cmd_args) if (ctx->last_dump_flush_req_id == ctx->applied_req_id) return 0; rc = wait_for_completion_timeout( rem_jiffies = wait_for_completion_timeout( &ctx->config_done_complete, msecs_to_jiffies(30)); if (rc <= 0) { if (rem_jiffies == 0) CAM_ERR(CAM_ISP, "config done completion timeout, Reg dump will be unreliable rc=%d ctx_index %d", rc, ctx->ctx_index); rc = 0; } "config done completion timeout, Reg dump will be unreliable ctx_index %d", ctx->ctx_index); ctx->last_dump_flush_req_id = ctx->applied_req_id; rc = cam_ife_mgr_handle_reg_dump(ctx, ctx->reg_dump_buf_desc, Loading
drivers/cam_isp/isp_hw_mgr/isp_hw/ife_csid_hw/cam_ife_csid_core.c +9 −10 Original line number Diff line number Diff line Loading @@ -3284,7 +3284,7 @@ static int cam_ife_csid_reset_regs( csid_hw->csid_info->csid_reg; struct cam_hw_soc_info *soc_info; uint32_t val = 0; unsigned long flags; unsigned long flags, rem_jiffies = 0; soc_info = &csid_hw->hw_info->soc_info; Loading Loading @@ -3327,9 +3327,9 @@ static int cam_ife_csid_reset_regs( spin_unlock_irqrestore(&csid_hw->hw_info->hw_lock, flags); CAM_DBG(CAM_ISP, "CSID reset start"); rc = wait_for_completion_timeout(&csid_hw->csid_top_complete, rem_jiffies = wait_for_completion_timeout(&csid_hw->csid_top_complete, msecs_to_jiffies(IFE_CSID_TIMEOUT)); if (rc <= 0) { if (rem_jiffies == 0) { val = cam_io_r_mb(soc_info->reg_map[0].mem_base + csid_reg->cmn_reg->csid_top_irq_status_addr); if (val & 0x1) { Loading @@ -3341,19 +3341,18 @@ static int cam_ife_csid_reset_regs( CAM_DBG(CAM_ISP, "CSID:%d %s reset completed %d", csid_hw->hw_intf->hw_idx, reset_hw ? "hw" : "sw", rc); rc = 0; rem_jiffies); goto end; } CAM_ERR(CAM_ISP, "CSID:%d csid_reset %s fail rc = %d", csid_hw->hw_intf->hw_idx, reset_hw ? "hw" : "sw", rc); csid_hw->hw_intf->hw_idx, reset_hw ? "hw" : "sw", rem_jiffies); rc = -ETIMEDOUT; goto end; } else { } else CAM_DBG(CAM_ISP, "CSID:%d %s reset completed %d", csid_hw->hw_intf->hw_idx, reset_hw ? "hw" : "sw", rc); rc = 0; } csid_hw->hw_intf->hw_idx, reset_hw ? "hw" : "sw", rem_jiffies); end: return rc; Loading