lkml.org 
[lkml]   [2021]   [Jun]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] drm/stm: ltdc: improve pm_runtime to stop clocks
From
Date
On 6/29/21 1:58 PM, Raphael GALLAIS-POU - foss wrote:

[...]

> +++ b/drivers/gpu/drm/stm/ltdc.c
> @@ -425,10 +425,17 @@ static void ltdc_crtc_atomic_enable(struct drm_crtc *crtc,
> {
> struct ltdc_device *ldev = crtc_to_ltdc(crtc);
> struct drm_device *ddev = crtc->dev;
> + int ret;
>
> DRM_DEBUG_DRIVER("\n");
>
> - pm_runtime_get_sync(ddev->dev);
> + if (!pm_runtime_active(ddev->dev)) {
> + ret = pm_runtime_get_sync(ddev->dev);

All these if (!pm_runtime_active()) then pm_runtime_get_sync() calls
look like workaround for some larger issue. Shouldn't the pm_runtime do
some refcounting on its own , so this shouldn't be needed ?

\
 
 \ /
  Last update: 2021-06-30 02:35    [W:0.080 / U:0.128 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site