diff options
Diffstat (limited to 'drivers/crypto/ccree/cc_pm.c')
-rw-r--r-- | drivers/crypto/ccree/cc_pm.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/drivers/crypto/ccree/cc_pm.c b/drivers/crypto/ccree/cc_pm.c index d990f472e89f..6ff7e75ad90e 100644 --- a/drivers/crypto/ccree/cc_pm.c +++ b/drivers/crypto/ccree/cc_pm.c | |||
@@ -100,20 +100,19 @@ int cc_pm_put_suspend(struct device *dev) | |||
100 | 100 | ||
101 | int cc_pm_init(struct cc_drvdata *drvdata) | 101 | int cc_pm_init(struct cc_drvdata *drvdata) |
102 | { | 102 | { |
103 | int rc = 0; | ||
104 | struct device *dev = drvdata_to_dev(drvdata); | 103 | struct device *dev = drvdata_to_dev(drvdata); |
105 | 104 | ||
106 | /* must be before the enabling to avoid resdundent suspending */ | 105 | /* must be before the enabling to avoid resdundent suspending */ |
107 | pm_runtime_set_autosuspend_delay(dev, CC_SUSPEND_TIMEOUT); | 106 | pm_runtime_set_autosuspend_delay(dev, CC_SUSPEND_TIMEOUT); |
108 | pm_runtime_use_autosuspend(dev); | 107 | pm_runtime_use_autosuspend(dev); |
109 | /* activate the PM module */ | 108 | /* activate the PM module */ |
110 | rc = pm_runtime_set_active(dev); | 109 | return pm_runtime_set_active(dev); |
111 | if (rc) | 110 | } |
112 | return rc; | ||
113 | /* enable the PM module*/ | ||
114 | pm_runtime_enable(dev); | ||
115 | 111 | ||
116 | return rc; | 112 | /* enable the PM module*/ |
113 | void cc_pm_go(struct cc_drvdata *drvdata) | ||
114 | { | ||
115 | pm_runtime_enable(drvdata_to_dev(drvdata)); | ||
117 | } | 116 | } |
118 | 117 | ||
119 | void cc_pm_fini(struct cc_drvdata *drvdata) | 118 | void cc_pm_fini(struct cc_drvdata *drvdata) |