crypto: ccree - fix pm wrongful error reporting

pm_runtime_get_sync() can return 1 as a valid (none error) return
code. Treat it as such.

Signed-off-by: Gilad Ben-Yossef <gilad@benyossef.com>
Cc: stable@vger.kernel.org # v4.19+
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
This commit is contained in:
Gilad Ben-Yossef 2020-01-16 12:14:40 +02:00 committed by Herbert Xu
parent c7b31c88da
commit cedca59fae

View File

@ -85,7 +85,7 @@ int cc_pm_get(struct device *dev)
else
pm_runtime_get_noresume(dev);
return rc;
return (rc == 1 ? 0 : rc);
}
int cc_pm_put_suspend(struct device *dev)