msm: camera: icp: Print lx7 status registers
If lx7 collapse/resume fails dump status registers to help narrow down the cause. The change also adds a write barrier post HOST2ICP trigger. CRs-Fixed: 2841729 Change-Id: I8201a1c84e0455044fccf88cc86a865bb89356a7 Signed-off-by: Karthik Anantha Ram <kartanan@codeaurora.org>
This commit is contained in:

committed by
Gerrit - the friendly Code Review server

parent
97a5608106
commit
c357648fcd
@@ -214,6 +214,9 @@ int hfi_write_cmd(void *cmd_ptr)
|
|||||||
*/
|
*/
|
||||||
wmb();
|
wmb();
|
||||||
hfi_irq_raise(g_hfi);
|
hfi_irq_raise(g_hfi);
|
||||||
|
|
||||||
|
/* Ensure HOST2ICP trigger is received by FW */
|
||||||
|
wmb();
|
||||||
err:
|
err:
|
||||||
mutex_unlock(&hfi_cmd_q_mutex);
|
mutex_unlock(&hfi_cmd_q_mutex);
|
||||||
return rc;
|
return rc;
|
||||||
|
@@ -695,8 +695,15 @@ static int cam_lx7_core_control(
|
|||||||
if (core_info->use_sec_pil) {
|
if (core_info->use_sec_pil) {
|
||||||
rc = qcom_scm_set_remote_state(state, CAM_FW_PAS_ID);
|
rc = qcom_scm_set_remote_state(state, CAM_FW_PAS_ID);
|
||||||
if (rc)
|
if (rc)
|
||||||
CAM_ERR(CAM_ICP, "remote state set to %s failed rc=%d",
|
CAM_ERR(CAM_ICP,
|
||||||
state == TZ_STATE_RESUME ? "resume" : "suspend", rc);
|
"remote state set to %s failed rc=%d IB_status0=0x%x IB_Status1=0x%x PFault=0x%x",
|
||||||
|
state == TZ_STATE_RESUME ? "resume" : "suspend", rc,
|
||||||
|
cam_io_r_mb(lx7_info->soc_info.reg_map[LX7_CIRQ_BASE].mem_base +
|
||||||
|
ICP_LX7_CIRQ_IB_STATUS0),
|
||||||
|
cam_io_r_mb(lx7_info->soc_info.reg_map[LX7_CIRQ_BASE].mem_base +
|
||||||
|
ICP_LX7_CIRQ_IB_STATUS1),
|
||||||
|
cam_io_r_mb(lx7_info->soc_info.reg_map[LX7_CIRQ_BASE].mem_base +
|
||||||
|
ICP_LX7_CIRQ_PFAULT_INFO));
|
||||||
} else {
|
} else {
|
||||||
if (state == TZ_STATE_RESUME) {
|
if (state == TZ_STATE_RESUME) {
|
||||||
rc = __cam_lx7_power_resume(lx7_info);
|
rc = __cam_lx7_power_resume(lx7_info);
|
||||||
|
@@ -30,7 +30,10 @@
|
|||||||
#define ICP_LX7_CIRQ_OB_IRQ_CMD 0x10
|
#define ICP_LX7_CIRQ_OB_IRQ_CMD 0x10
|
||||||
#define LX7_IRQ_CLEAR_CMD (1 << 1)
|
#define LX7_IRQ_CLEAR_CMD (1 << 1)
|
||||||
|
|
||||||
#define ICP_LX7_CIRQ_HOST2ICPINT 0x124
|
#define ICP_LX7_CIRQ_IB_STATUS0 0x70
|
||||||
|
#define ICP_LX7_CIRQ_IB_STATUS1 0x74
|
||||||
|
#define ICP_LX7_CIRQ_HOST2ICPINT 0x124
|
||||||
|
#define ICP_LX7_CIRQ_PFAULT_INFO 0x128
|
||||||
#define LX7_HOST2ICPINT (1 << 0)
|
#define LX7_HOST2ICPINT (1 << 0)
|
||||||
|
|
||||||
#endif /* _CAM_LX7_REG_H_ */
|
#endif /* _CAM_LX7_REG_H_ */
|
||||||
|
Reference in New Issue
Block a user