drm/fsl-dcu: avoid disabling pixel clock twice on suspend
Subsystems (3)
Stefan Agner
maintainerPATCH 1/2 drm/fsl-dcu: avoid disabling pixel clock twice on suspend
With commit 0a70c998d0c5 ("drm/fsl-dcu: enable pixel clock when enabling CRTC") the pixel clock is controlled by the CRTC code. Disabling the pixel clock in suspend leads to a warning due to the second clk_disable_unprepare call:
WARNING: CPU: 0 PID: 359 at drivers/clk/clk.c:594 clk_core_disable+0x8c/0x90
Remove clk_disable_unprepare call for pixel clock to avoid unbalanced clock disable on suspend.
--- drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 1 - 1 file changed, 1 deletion(-)
drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c +0 -1
@@ -202,7 +202,6 @@ static int fsl_dcu_drm_pm_suspend(struct device *dev)return ret; } -clk_disable_unprepare (fsl_dev->pix_clk);clk_disable_unprepare (fsl_dev->clk);return 0 ;
Signature · 6 lines
2.14.2 _______________________________________________ dri-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/dri-devel
Stefan Agner
maintainerPATCH 2/2 drm/fsl-dcu: enable IRQ before drm_atomic_helper_resume()
The resume helpers wait for a vblank to occurre hence IRQ need to be enabled. This avoids a warning as follows during resume:
WARNING: CPU: 0 PID: 314 at drivers/gpu/drm/drm_atomic_helper.c:1249 drm_atomic_helper_wait_for_vblanks.part.1+0x284/0x288 [CRTC:28:crtc-0] vblank wait timed out
--- drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c +1 -2
@@ -225,9 +225,8 @@ static int fsl_dcu_drm_pm_resume(struct device *dev)fsl_tcon_bypass_enable (fsl_dev->tcon);fsl_dcu_drm_init_planes (fsl_dev->drm); -drm_mode_config_helper_resume (fsl_dev->drm); -enable_irq (fsl_dev->irq); +drm_mode_config_helper_resume (fsl_dev->drm);return 0 ; }
Signature · 6 lines
2.14.2 _______________________________________________ dri-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/dri-devel
Re: [PATCH 2/2] drm/fsl-dcu: enable IRQ before drm_atomic_helper_resume()
Den 10.11.2017 17.25, skrev Stefan Agner:
Quoted 15 lines
The resume helpers wait for a vblank to occurre hence IRQ need to be enabled. This avoids a warning as follows during resume:
WARNING: CPU: 0 PID: 314 at drivers/gpu/drm/drm_atomic_helper.c:1249 drm_atomic_helper_wait_for_vblanks.part.1+0x284/0x288 [CRTC:28:crtc-0] vblank wait timed outSigned-off-by Stefan Agner <[email protected]>--- drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c +0
-0
drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c static int fsl_dcu_drm_pm_resume(struct device *dev) · line 232
Quoted 10 lines
drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c +1
-2@@ -225,9 +225,8 @@ static int fsl_dcu_drm_pm_resume(struct device *dev)fsl_tcon_bypass_enable (fsl_dev->tcon);fsl_dcu_drm_init_planes (fsl_dev->drm); -drm_mode_config_helper_resume (fsl_dev->drm); -enable_irq (fsl_dev->irq); +drm_mode_config_helper_resume (fsl_dev->drm);return 0 ; }
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
Den 10.11.2017 17.25, skrev Stefan Agner:
Quoted 20 lines
With commit
0a70c998d0c5("drm/fsl-dcu: enable pixel clock when enabling CRTC") the pixel clock is controlled by the CRTC code. Disabling the pixel clock in suspend leads to a warning due to the secondclk_disable_unpreparecall:WARNING: CPU: 0 PID: 359 at drivers/clk/clk.c:594 clk_core_disable+0x8c/0x90Remove
clk_disable_unpreparecall for pixel clock to avoid unbalanced clock disable on suspend.Fixes 0a70c998d0c5 ("drm/fsl-dcu: enable pixel clock when enabling CRTC")Signed-off-by Stefan Agner <[email protected]>--- drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c | 1 - 1 file changed, 1 deletion(-)drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c +0
-0
drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c static int fsl_dcu_drm_pm_suspend(struct device *dev) · line 207
Quoted 7 lines
drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_drv.c +0
-1@@ -202,7 +202,6 @@ static int fsl_dcu_drm_pm_suspend(struct device *dev)return ret; } -clk_disable_unprepare (fsl_dev->pix_clk);clk_disable_unprepare (fsl_dev->clk);return 0 ;
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel