[PATCH v2 0/2] Add UFS LINERESET handling

Can Guo
2020-09-03T02:25:35Z

PA Layer issues a LINERESET to the PHY at the recovery step in the Power
Mode change operation. If it happens during auto or mannual hibern8 enter,
even if hibern8 enter succeeds, UFS power mode shall be set to PWM-G1 mode
and kept in that mode after exit from hibern8, leading to bad performance.
Handle the LINERESET in the eh_work by restoring power mode to HS mode
after all pending reqs and tasks are cleared from doorbell.

Change since v1:
- Made some cleanup to the 2nd change.

Can Guo (2):
scsi: ufs: Abort tasks before clear them from doorbell
scsi: ufs: Handle LINERESET indication in err handler

drivers/scsi/ufs/ufshcd.c | 283 +++++++++++++++++++++++++++++++---------------
drivers/scsi/ufs/ufshcd.h | 2 +
drivers/scsi/ufs/ufshci.h | 1 +
drivers/scsi/ufs/unipro.h | 3 +
4 files changed, 196 insertions(+), 93 deletions(-)

--
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project.