summaryrefslogtreecommitdiff
path: root/drivers/crypto/tegra-se.c
diff options
context:
space:
mode:
authorSang-Hun Lee <sanlee@nvidia.com>2011-12-05 14:51:34 -0800
committerVarun Wadekar <vwadekar@nvidia.com>2011-12-08 18:05:57 +0530
commite017320aa5751f0427c432d68583af99abf3b468 (patch)
treeaa012703f4d6839bc5142ce2204b3cf4bd16082b /drivers/crypto/tegra-se.c
parentc7679148fccb75081385c3a7335117c6871c9368 (diff)
crypto: tegra-se: Fix device hang
Problem description: - runtime_idle is called even if the device is being used as it is called without a lock - This happens when power.usage_count is incremented during rpm_idle - In case runtime_idle is called when the device is being used, write to the bus can happen with clock disabled Fix description: - Instead of disabling clock on runtime_idle, disable on runtime_suspend Bug 904152 Change-Id: I1489c62a0c8cfd84eca788d53d2013487fb7f737 Signed-off-by: Sang-Hun Lee <sanlee@nvidia.com> Reviewed-on: http://git-master/r/68293 Reviewed-by: Thomas Cherry <tcherry@nvidia.com> Reviewed-by: Varun Wadekar <vwadekar@nvidia.com> Reviewed-by: Dan Willemsen <dwillemsen@nvidia.com>
Diffstat (limited to 'drivers/crypto/tegra-se.c')
-rw-r--r--drivers/crypto/tegra-se.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/crypto/tegra-se.c b/drivers/crypto/tegra-se.c
index 3999e5790d9e..633bb2393106 100644
--- a/drivers/crypto/tegra-se.c
+++ b/drivers/crypto/tegra-se.c
@@ -2366,7 +2366,7 @@ out:
#endif
#if defined(CONFIG_PM_RUNTIME)
-static int tegra_se_runtime_idle(struct device *dev)
+static int tegra_se_runtime_suspend(struct device *dev)
{
/*
* do a dummy read, to avoid scenarios where you have unposted writes
@@ -2385,7 +2385,7 @@ static int tegra_se_runtime_resume(struct device *dev)
}
static const struct dev_pm_ops tegra_se_dev_pm_ops = {
- .runtime_idle = tegra_se_runtime_idle,
+ .runtime_suspend = tegra_se_runtime_suspend,
.runtime_resume = tegra_se_runtime_resume,
};
#endif