Patch "crypto: omap-sham - Use pm_runtime_resume_and_get() in omap_sham_probe()" has been added to the 5.10-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    crypto: omap-sham - Use pm_runtime_resume_and_get() in omap_sham_probe()

to the 5.10-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     crypto-omap-sham-use-pm_runtime_resume_and_get-in-om.patch
and it can be found in the queue-5.10 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 7b884c71bdcff10128094af70511fab9f5ab4d73
Author: Shang XiaoJing <shangxiaojing@xxxxxxxxxx>
Date:   Thu Nov 24 14:49:40 2022 +0800

    crypto: omap-sham - Use pm_runtime_resume_and_get() in omap_sham_probe()
    
    [ Upstream commit 7bcceb4c9896b1b672b636ae70fe75110d6bf1ad ]
    
    omap_sham_probe() calls pm_runtime_get_sync() and calls
    pm_runtime_put_sync() latter to put usage_counter. However,
    pm_runtime_get_sync() will increment usage_counter even it failed. Fix
    it by replacing it with pm_runtime_resume_and_get() to keep usage
    counter balanced.
    
    Fixes: b359f034c8bf ("crypto: omap-sham - Convert to use pm_runtime API")
    Signed-off-by: Shang XiaoJing <shangxiaojing@xxxxxxxxxx>
    Acked-by: Mark Greer <mgreer@xxxxxxxxxxxxxxx>
    Signed-off-by: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/crypto/omap-sham.c b/drivers/crypto/omap-sham.c
index 48f78e34cf8d..5a57617441b8 100644
--- a/drivers/crypto/omap-sham.c
+++ b/drivers/crypto/omap-sham.c
@@ -2130,7 +2130,7 @@ static int omap_sham_probe(struct platform_device *pdev)
 	pm_runtime_enable(dev);
 	pm_runtime_irq_safe(dev);
 
-	err = pm_runtime_get_sync(dev);
+	err = pm_runtime_resume_and_get(dev);
 	if (err < 0) {
 		dev_err(dev, "failed to get sync: %d\n", err);
 		goto err_pm;



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux