scsi: ufs: add device quirk delay before putting UFS rails in LPM
authorYaniv Gardi <ygardi@codeaurora.org>
Thu, 10 Mar 2016 15:37:18 +0000 (17:37 +0200)
committerMartin K. Petersen <martin.petersen@oracle.com>
Tue, 15 Mar 2016 01:04:45 +0000 (21:04 -0400)
commitb799fdf754b5c6c4dad0016826fb6b3e79bccaea
tree8c096ba12a883e3b1e93b215c44fe88e333bc20c
parentf3099fbd9b90f94849bd155ebf690dd5a8cfa477
scsi: ufs: add device quirk delay before putting UFS rails in LPM

We put the UFS device in sleep state & UFS link in hibern8 state during
runtime suspend. After this we put all the UFS rails in low power
modes immediately but it seems some devices may still draw more than
sleep current from UFS rails (especially from VCCQ rail) at-least for
500us.
To avoid this situation, this change adds 2ms delay before putting
these UFS rails in LPM mode.

Reviewed-by: Gilad Broner <gbroner@codeaurora.org>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Subhash Jadavani <subhashj@codeaurora.org>
Signed-off-by: Yaniv Gardi <ygardi@codeaurora.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/ufs/ufs_quirks.h
drivers/scsi/ufs/ufshcd.c