summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorVenkat Gopalakrishnan <venkatg@codeaurora.org>2016-10-04 10:01:31 -0700
committerVenkat Gopalakrishnan <venkatg@codeaurora.org>2016-10-10 17:13:38 -0700
commitdfd06cdff2c74deae4e08d759d39d63579a14885 (patch)
tree183601a665c2a294f09a1984dd680474f97cad93 /drivers
parente9239e3f350828c14e67c21469004c79ac71cd69 (diff)
scsi: ufs: reduce auto hibern8 timeout to save power
The PA_Hibern8Time and PA_TActivate time in most devices are well under 1ms combined thereby the overall hibern8 enter/exit latencies are under 1ms as well. Entering hibern8 as soon as possible saves power consumption, hence reduce the auto hibern8 timeout to 1ms. Change-Id: If58590fc397ec8eb88906c103247bb48710805db Signed-off-by: Venkat Gopalakrishnan <venkatg@codeaurora.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/scsi/ufs/ufshcd.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
index dcc2cb8193a1..d254faacfcfe 100644
--- a/drivers/scsi/ufs/ufshcd.c
+++ b/drivers/scsi/ufs/ufshcd.c
@@ -1948,6 +1948,7 @@ static void ufshcd_init_hibern8_on_idle(struct ufs_hba *hba)
return;
if (ufshcd_is_auto_hibern8_supported(hba)) {
+ hba->hibern8_on_idle.delay_ms = 1;
hba->hibern8_on_idle.state = AUTO_HIBERN8;
/*
* Disable SW hibern8 enter on idle in case
@@ -1955,13 +1956,13 @@ static void ufshcd_init_hibern8_on_idle(struct ufs_hba *hba)
*/
hba->caps &= ~UFSHCD_CAP_HIBERN8_ENTER_ON_IDLE;
} else {
+ hba->hibern8_on_idle.delay_ms = 10;
INIT_DELAYED_WORK(&hba->hibern8_on_idle.enter_work,
ufshcd_hibern8_enter_work);
INIT_WORK(&hba->hibern8_on_idle.exit_work,
ufshcd_hibern8_exit_work);
}
- hba->hibern8_on_idle.delay_ms = 10;
hba->hibern8_on_idle.is_enabled = true;
hba->hibern8_on_idle.delay_attr.show =