]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
crypto: ccree - make cc_pm_put_suspend() void
authorGilad Ben-Yossef <gilad@benyossef.com>
Thu, 16 Jan 2020 10:14:45 +0000 (12:14 +0200)
committerHerbert Xu <herbert@gondor.apana.org.au>
Wed, 22 Jan 2020 08:21:10 +0000 (16:21 +0800)
cc_pm_put_suspend() return value was never checked and is not
useful. Turn it into a void functions.

Signed-off-by: Gilad Ben-Yossef <gilad@benyossef.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/ccree/cc_pm.c
drivers/crypto/ccree/cc_pm.h

index ee9e9cba2fbb16999d24b4cf5c7b643468bfcdba..24c368b866f6b5ea87c526800bb8eb9543cc2ddf 100644 (file)
@@ -73,17 +73,14 @@ int cc_pm_get(struct device *dev)
        return (rc == 1 ? 0 : rc);
 }
 
-int cc_pm_put_suspend(struct device *dev)
+void cc_pm_put_suspend(struct device *dev)
 {
-       int rc = 0;
        struct cc_drvdata *drvdata = dev_get_drvdata(dev);
 
        if (drvdata->pm_on) {
                pm_runtime_mark_last_busy(dev);
-               rc = pm_runtime_put_autosuspend(dev);
+               pm_runtime_put_autosuspend(dev);
        }
-
-       return rc;
 }
 
 bool cc_pm_is_dev_suspended(struct device *dev)
index a7d98a5da2e1030076077d63435de2bc4f297762..04289beb6e3ea1c957432b0ce128551e2916d76c 100644 (file)
@@ -21,7 +21,7 @@ void cc_pm_fini(struct cc_drvdata *drvdata);
 int cc_pm_suspend(struct device *dev);
 int cc_pm_resume(struct device *dev);
 int cc_pm_get(struct device *dev);
-int cc_pm_put_suspend(struct device *dev);
+void cc_pm_put_suspend(struct device *dev);
 bool cc_pm_is_dev_suspended(struct device *dev);
 
 #else
@@ -50,10 +50,7 @@ static inline int cc_pm_get(struct device *dev)
        return 0;
 }
 
-static inline int cc_pm_put_suspend(struct device *dev)
-{
-       return 0;
-}
+static inline void cc_pm_put_suspend(struct device *dev) {}
 
 static inline bool cc_pm_is_dev_suspended(struct device *dev)
 {