Loading drivers/scsi/ufs/ufs-qcom.h +1 −0 Original line number Diff line number Diff line Loading @@ -164,6 +164,7 @@ enum ufs_qcom_phy_init_type { UFS_QCOM_DBG_PRINT_TEST_BUS_EN) /* QUniPro Vendor specific attributes */ #define PA_VS_STATUS_REG1 0x9001 #define PA_VS_CONFIG_REG1 0x9000 #define SAVECONFIGTIME_MODE_MASK 0x6000 #define DME_VS_CORE_CLK_CTRL 0xD002 Loading drivers/scsi/ufs/ufshcd.c +14 −5 Original line number Diff line number Diff line Loading @@ -51,6 +51,7 @@ #include "ufs-sysfs.h" #include "ufs_bsg.h" #include "ufshcd-crypto.h" #include "ufs-qcom.h" #define CREATE_TRACE_POINTS #include <trace/events/ufs.h> Loading Loading @@ -5742,17 +5743,25 @@ static void ufshcd_err_handler(struct work_struct *work) goto skip_err_handling; } spin_unlock_irqrestore(hba->host->host_lock, flags); ufshcd_vops_dbg_register_dump(hba); spin_lock_irqsave(hba->host->host_lock, flags); if ((hba->saved_err & INT_FATAL_ERRORS) || (hba->saved_err & UFSHCD_UIC_HIBERN8_MASK) || ((hba->saved_err & UIC_ERROR) && (hba->saved_uic_err & (UFSHCD_UIC_DL_PA_INIT_ERROR | UFSHCD_UIC_DL_NAC_RECEIVED_ERROR | UFSHCD_UIC_DL_TCx_REPLAY_ERROR)))) UFSHCD_UIC_DL_TCx_REPLAY_ERROR)))) { u32 pa_vs_status_reg1 = 0; int ret; spin_unlock_irqrestore(hba->host->host_lock, flags); ret = ufshcd_dme_get(hba, UIC_ARG_MIB(PA_VS_STATUS_REG1), &pa_vs_status_reg1); dev_err(hba->dev, "%s: pa_vs_status_reg1 0x%x, ret %d\n", __func__, pa_vs_status_reg1, ret); ufshcd_vops_dbg_register_dump(hba); spin_lock_irqsave(hba->host->host_lock, flags); needs_reset = true; } /* * if host reset is required then skip clearing the pending Loading Loading
drivers/scsi/ufs/ufs-qcom.h +1 −0 Original line number Diff line number Diff line Loading @@ -164,6 +164,7 @@ enum ufs_qcom_phy_init_type { UFS_QCOM_DBG_PRINT_TEST_BUS_EN) /* QUniPro Vendor specific attributes */ #define PA_VS_STATUS_REG1 0x9001 #define PA_VS_CONFIG_REG1 0x9000 #define SAVECONFIGTIME_MODE_MASK 0x6000 #define DME_VS_CORE_CLK_CTRL 0xD002 Loading
drivers/scsi/ufs/ufshcd.c +14 −5 Original line number Diff line number Diff line Loading @@ -51,6 +51,7 @@ #include "ufs-sysfs.h" #include "ufs_bsg.h" #include "ufshcd-crypto.h" #include "ufs-qcom.h" #define CREATE_TRACE_POINTS #include <trace/events/ufs.h> Loading Loading @@ -5742,17 +5743,25 @@ static void ufshcd_err_handler(struct work_struct *work) goto skip_err_handling; } spin_unlock_irqrestore(hba->host->host_lock, flags); ufshcd_vops_dbg_register_dump(hba); spin_lock_irqsave(hba->host->host_lock, flags); if ((hba->saved_err & INT_FATAL_ERRORS) || (hba->saved_err & UFSHCD_UIC_HIBERN8_MASK) || ((hba->saved_err & UIC_ERROR) && (hba->saved_uic_err & (UFSHCD_UIC_DL_PA_INIT_ERROR | UFSHCD_UIC_DL_NAC_RECEIVED_ERROR | UFSHCD_UIC_DL_TCx_REPLAY_ERROR)))) UFSHCD_UIC_DL_TCx_REPLAY_ERROR)))) { u32 pa_vs_status_reg1 = 0; int ret; spin_unlock_irqrestore(hba->host->host_lock, flags); ret = ufshcd_dme_get(hba, UIC_ARG_MIB(PA_VS_STATUS_REG1), &pa_vs_status_reg1); dev_err(hba->dev, "%s: pa_vs_status_reg1 0x%x, ret %d\n", __func__, pa_vs_status_reg1, ret); ufshcd_vops_dbg_register_dump(hba); spin_lock_irqsave(hba->host->host_lock, flags); needs_reset = true; } /* * if host reset is required then skip clearing the pending Loading