[PATCH -next 1/7] crypto: sun4i-ss - Fix PM reference leak when pm_runtime_get_sync() fails
Herbert Xu
herbert at gondor.apana.org.au
Fri Apr 16 12:31:40 BST 2021
On Thu, Apr 08, 2021 at 03:18:31PM +0800, Shixin Liu wrote:
> pm_runtime_get_sync will increment pm usage counter even it failed.
> Forgetting to putting operation will result in reference leak here.
> Fix it by replacing it with pm_runtime_resume_and_get to keep usage
> counter balanced.
>
> Signed-off-by: Shixin Liu <liushixin2 at huawei.com>
> ---
> drivers/crypto/allwinner/sun4i-ss/sun4i-ss-cipher.c | 2 +-
> drivers/crypto/allwinner/sun4i-ss/sun4i-ss-core.c | 2 +-
> drivers/crypto/allwinner/sun4i-ss/sun4i-ss-hash.c | 2 +-
> drivers/crypto/allwinner/sun4i-ss/sun4i-ss-prng.c | 2 +-
> 4 files changed, 4 insertions(+), 4 deletions(-)
All applied. Thanks.
--
Email: Herbert Xu <herbert at gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
More information about the linux-arm-kernel
mailing list