diff mbox

drm/exynos/fimc: fix runtime pm support

Message ID 1428569160-20628-1-git-send-email-m.szyprowski@samsung.com (mailing list archive)
State New, archived
Headers show

Commit Message

Marek Szyprowski April 9, 2015, 8:46 a.m. UTC
Once pm_runtime_set_active() gets called, the kernel assumes that given
device has already enabled runtime pm and will call pm_runtime_suspend()
without matching pm_runtime_resume(). In case of DRM FIMC IPP driver,
this will result in calling clk_disable() without respective call to
clk_enable(). This patch removes call to pm_runtime_set_active() to
ensure that pm_runtime_suspend/resume calls will match.

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
---
 drivers/gpu/drm/exynos/exynos_drm_fimc.c | 1 -
 1 file changed, 1 deletion(-)

Comments

Tobias Jakobi July 12, 2015, 4:24 p.m. UTC | #1
Hello,

looks like this patch was forgotten. At least I can't find it in 4.2-rc1.

With best wishes,
Tobias


Marek Szyprowski wrote:
> Once pm_runtime_set_active() gets called, the kernel assumes that given
> device has already enabled runtime pm and will call pm_runtime_suspend()
> without matching pm_runtime_resume(). In case of DRM FIMC IPP driver,
> this will result in calling clk_disable() without respective call to
> clk_enable(). This patch removes call to pm_runtime_set_active() to
> ensure that pm_runtime_suspend/resume calls will match.
> 
> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
> ---
>  drivers/gpu/drm/exynos/exynos_drm_fimc.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimc.c b/drivers/gpu/drm/exynos/exynos_drm_fimc.c
> index 842d6b8dc3c4..2a652359af64 100644
> --- a/drivers/gpu/drm/exynos/exynos_drm_fimc.c
> +++ b/drivers/gpu/drm/exynos/exynos_drm_fimc.c
> @@ -1745,7 +1745,6 @@ static int fimc_probe(struct platform_device *pdev)
>  	spin_lock_init(&ctx->lock);
>  	platform_set_drvdata(pdev, ctx);
>  
> -	pm_runtime_set_active(dev);
>  	pm_runtime_enable(dev);
>  
>  	ret = exynos_drm_ippdrv_register(ippdrv);
>
Marek Szyprowski Aug. 6, 2015, 10:13 a.m. UTC | #2
Hello,

On 2015-04-09 10:46, Marek Szyprowski wrote:
> Once pm_runtime_set_active() gets called, the kernel assumes that given
> device has already enabled runtime pm and will call pm_runtime_suspend()
> without matching pm_runtime_resume(). In case of DRM FIMC IPP driver,
> this will result in calling clk_disable() without respective call to
> clk_enable(). This patch removes call to pm_runtime_set_active() to
> ensure that pm_runtime_suspend/resume calls will match.
>
> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>

Gentle ping...

> ---
>   drivers/gpu/drm/exynos/exynos_drm_fimc.c | 1 -
>   1 file changed, 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimc.c b/drivers/gpu/drm/exynos/exynos_drm_fimc.c
> index 842d6b8dc3c4..2a652359af64 100644
> --- a/drivers/gpu/drm/exynos/exynos_drm_fimc.c
> +++ b/drivers/gpu/drm/exynos/exynos_drm_fimc.c
> @@ -1745,7 +1745,6 @@ static int fimc_probe(struct platform_device *pdev)
>   	spin_lock_init(&ctx->lock);
>   	platform_set_drvdata(pdev, ctx);
>   
> -	pm_runtime_set_active(dev);
>   	pm_runtime_enable(dev);
>   
>   	ret = exynos_drm_ippdrv_register(ippdrv);

Best regards
Inki Dae Aug. 6, 2015, 11:57 a.m. UTC | #3
On 2015? 08? 06? 19:13, Marek Szyprowski wrote:
> Hello,
> 
> On 2015-04-09 10:46, Marek Szyprowski wrote:
>> Once pm_runtime_set_active() gets called, the kernel assumes that given
>> device has already enabled runtime pm and will call pm_runtime_suspend()
>> without matching pm_runtime_resume(). In case of DRM FIMC IPP driver,
>> this will result in calling clk_disable() without respective call to
>> clk_enable(). This patch removes call to pm_runtime_set_active() to
>> ensure that pm_runtime_suspend/resume calls will match.
>>
>> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
> 
> Gentle ping...

Sorry, I missed it. Merged.

Thanks,
Inki Dae

> 
>> ---
>>   drivers/gpu/drm/exynos/exynos_drm_fimc.c | 1 -
>>   1 file changed, 1 deletion(-)
>>
>> diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimc.c
>> b/drivers/gpu/drm/exynos/exynos_drm_fimc.c
>> index 842d6b8dc3c4..2a652359af64 100644
>> --- a/drivers/gpu/drm/exynos/exynos_drm_fimc.c
>> +++ b/drivers/gpu/drm/exynos/exynos_drm_fimc.c
>> @@ -1745,7 +1745,6 @@ static int fimc_probe(struct platform_device *pdev)
>>       spin_lock_init(&ctx->lock);
>>       platform_set_drvdata(pdev, ctx);
>>   -    pm_runtime_set_active(dev);
>>       pm_runtime_enable(dev);
>>         ret = exynos_drm_ippdrv_register(ippdrv);
> 
> Best regards
diff mbox

Patch

diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimc.c b/drivers/gpu/drm/exynos/exynos_drm_fimc.c
index 842d6b8dc3c4..2a652359af64 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_fimc.c
+++ b/drivers/gpu/drm/exynos/exynos_drm_fimc.c
@@ -1745,7 +1745,6 @@  static int fimc_probe(struct platform_device *pdev)
 	spin_lock_init(&ctx->lock);
 	platform_set_drvdata(pdev, ctx);
 
-	pm_runtime_set_active(dev);
 	pm_runtime_enable(dev);
 
 	ret = exynos_drm_ippdrv_register(ippdrv);