Patchwork [DPU,PATCH ] drm/msm/dpu: Fix clock issue after bind failure

login
register
mail settings
Submitter Jayant Shekhar
Date Dec. 5, 2018, 4:21 p.m.
Message ID <1544026907-24267-1-git-send-email-jshekhar@codeaurora.org>
Download mbox | patch
Permalink /patch/673293/
State New
Headers show

Comments

Jayant Shekhar - Dec. 5, 2018, 4:21 p.m.
In case of msm drm bind failure, pm runtime put sync
is called from dsi driver which issues an asynchronous
put on mdss device. Subsequently when dpu_mdss_destroy
is triggered the change will make sure to put the mdss
device in suspend and clearing pending work if not
scheduled.

Signed-off-by: Jayant Shekhar <jshekhar@codeaurora.org>
---
 drivers/gpu/drm/msm/disp/dpu1/dpu_mdss.c | 1 +
 1 file changed, 1 insertion(+)
Sean Paul - Dec. 6, 2018, 4:11 p.m.
On Wed, Dec 05, 2018 at 09:51:47PM +0530, Jayant Shekhar wrote:
> In case of msm drm bind failure, pm runtime put sync
> is called from dsi driver which issues an asynchronous
> put on mdss device. Subsequently when dpu_mdss_destroy
> is triggered the change will make sure to put the mdss
> device in suspend and clearing pending work if not
> scheduled.
> 
> Signed-off-by: Jayant Shekhar <jshekhar@codeaurora.org>

Thanks for sending this, pushed to dpu-staging/for-next

Sean

> ---
>  drivers/gpu/drm/msm/disp/dpu1/dpu_mdss.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_mdss.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_mdss.c
> index 2d66025..030229a 100644
> --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_mdss.c
> +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_mdss.c
> @@ -191,6 +191,7 @@ static void dpu_mdss_destroy(struct drm_device *dev)
>  	struct dss_module_power *mp = &dpu_mdss->mp;
>  	int i;
>  
> +	pm_runtime_suspend(dev->dev);
>  	pm_runtime_disable(dev->dev);
>  	_dpu_mdss_irq_domain_fini(dpu_mdss);
>  	free_irq(platform_get_irq(pdev, 0), dpu_mdss);
> -- 
> The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
> a Linux Foundation Collaborative Project
>

Patch

diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_mdss.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_mdss.c
index 2d66025..030229a 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_mdss.c
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_mdss.c
@@ -191,6 +191,7 @@  static void dpu_mdss_destroy(struct drm_device *dev)
 	struct dss_module_power *mp = &dpu_mdss->mp;
 	int i;
 
+	pm_runtime_suspend(dev->dev);
 	pm_runtime_disable(dev->dev);
 	_dpu_mdss_irq_domain_fini(dpu_mdss);
 	free_irq(platform_get_irq(pdev, 0), dpu_mdss);