diff mbox series

[V2] media: s3c-camif: fix missing disable in tegra_adma_probe().

Message ID 20200524034616.31625-1-wu000273@umn.edu (mailing list archive)
State Not Applicable
Headers show
Series [V2] media: s3c-camif: fix missing disable in tegra_adma_probe(). | expand

Commit Message

wu000273@umn.edu May 24, 2020, 3:46 a.m. UTC
From: Qiushi Wu <wu000273@umn.edu>

"pm_runtime_enable()" was not handled by "pm_runtime_disable()"
after a call of the function “pm_runtime_get_sync()” failed.
Thus move the jump target “err_pm” before calling function 
"calling pm_runtime_disable()".

Fixes: babde1c243b2 ("[media] V4L: Add driver for S3C24XX/S3C64XX SoC series camera interface")
Signed-off-by: Qiushi Wu <wu000273@umn.edu>
---

V2: improving commit messages.

---
 drivers/media/platform/s3c-camif/camif-core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Sylwester Nawrocki May 24, 2020, 7:03 p.m. UTC | #1
Hi,

On 5/24/20 05:46, wu000273@umn.edu wrote:
> From: Qiushi Wu <wu000273@umn.edu>
> 
> "pm_runtime_enable()" was not handled by "pm_runtime_disable()"
> after a call of the function “pm_runtime_get_sync()” failed.
> Thus move the jump target “err_pm” before calling function
> "calling pm_runtime_disable()".
> 
> Fixes: babde1c243b2 ("[media] V4L: Add driver for S3C24XX/S3C64XX SoC series camera interface")
> Signed-off-by: Qiushi Wu <wu000273@umn.edu>
> ---
> 
> V2: improving commit messages.

Thanks for the patch. It seems you have got typo in the subject line.
With tegra_adma_probe changed to s3c_camif_probe feel free to add:

Reviewed-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Sylwester Nawrocki May 24, 2020, 7:27 p.m. UTC | #2
On 5/24/20 21:03, Sylwester Nawrocki wrote:
> On 5/24/20 05:46, wu000273@umn.edu wrote:
>> From: Qiushi Wu <wu000273@umn.edu>
>>
>> "pm_runtime_enable()" was not handled by "pm_runtime_disable()"
>> after a call of the function “pm_runtime_get_sync()” failed.
>> Thus move the jump target “err_pm” before calling function
>> "calling pm_runtime_disable()".
>>
>> Fixes: babde1c243b2 ("[media] V4L: Add driver for S3C24XX/S3C64XX SoC 
>> series camera interface")
>> Signed-off-by: Qiushi Wu <wu000273@umn.edu>
>> ---
>>
>> V2: improving commit messages.
> 
> Thanks for the patch. It seems you have got typo in the subject line.
> With tegra_adma_probe changed to s3c_camif_probe feel free to add:
> 
> Reviewed-by: Sylwester Nawrocki <s.nawrocki@samsung.com>

I just noticed this patch https://patchwork.linuxtv.org/patch/63976
which includes your fix and handles one more issue. Thus it might be
better to apply the patch from Dinghao Liu instead.
diff mbox series

Patch

diff --git a/drivers/media/platform/s3c-camif/camif-core.c b/drivers/media/platform/s3c-camif/camif-core.c
index c6fbcd7036d6..12ee49638f44 100644
--- a/drivers/media/platform/s3c-camif/camif-core.c
+++ b/drivers/media/platform/s3c-camif/camif-core.c
@@ -500,8 +500,8 @@  static int s3c_camif_probe(struct platform_device *pdev)
 	camif_unregister_media_entities(camif);
 err_alloc:
 	pm_runtime_put(dev);
-	pm_runtime_disable(dev);
 err_pm:
+	pm_runtime_disable(dev);
 	camif_clk_put(camif);
 err_clk:
 	s3c_camif_unregister_subdev(camif);