diff mbox series

drm/rockchip: vop: add rk3188 hs_start interrupt as dsp_hold equivalent

Message ID 20180923123730.14706-1-heiko@sntech.de (mailing list archive)
State New, archived
Headers show
Series drm/rockchip: vop: add rk3188 hs_start interrupt as dsp_hold equivalent | expand

Commit Message

Heiko Stübner Sept. 23, 2018, 12:37 p.m. UTC
The hs_start interrupt on rk3188 fires at the start of a new frame, so
serves essentially the same purpose as the dsp_hold_valid irq in checking
when the last frame got delivered when going to standby. So define it
to fix a hang on atomic_disable of the vop because the completion never
really completed before.

Fixes: 428e15cc41e3 ("drm/rockchip: vop: add rk3188 vop definitions")
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
---
 drivers/gpu/drm/rockchip/rockchip_vop_reg.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

Comments

黄家钗 Sept. 26, 2018, 12:42 p.m. UTC | #1
Hi heiko,
nice solution.

Reviewed-by: Sandy Huang <hjc@rock-chips.com>

在 2018/9/23 20:37, Heiko Stuebner 写道:
> The hs_start interrupt on rk3188 fires at the start of a new frame, so
> serves essentially the same purpose as the dsp_hold_valid irq in checking
> when the last frame got delivered when going to standby. So define it
> to fix a hang on atomic_disable of the vop because the completion never
> really completed before.
> 
> Fixes: 428e15cc41e3 ("drm/rockchip: vop: add rk3188 vop definitions")
> Signed-off-by: Heiko Stuebner <heiko@sntech.de>
> ---
>   drivers/gpu/drm/rockchip/rockchip_vop_reg.c | 6 +++++-
>   1 file changed, 5 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/rockchip/rockchip_vop_reg.c b/drivers/gpu/drm/rockchip/rockchip_vop_reg.c
> index c482da41bb5d..226bb2a1720e 100644
> --- a/drivers/gpu/drm/rockchip/rockchip_vop_reg.c
> +++ b/drivers/gpu/drm/rockchip/rockchip_vop_reg.c
> @@ -465,7 +465,11 @@ static const struct vop_win_data rk3188_vop_win_data[] = {
>   };
>   
>   static const int rk3188_vop_intrs[] = {
> -	0,
> +	/*
> +	 * hs_start interrupt fires at frame-start, so serves
> +	 * the same purpose as dsp_hold in the driver.
> +	 */
> +	DSP_HOLD_VALID_INTR,
>   	FS_INTR,
>   	LINE_FLAG_INTR,
>   	BUS_ERROR_INTR,
>
黄家钗 Sept. 26, 2018, 12:44 p.m. UTC | #2
Hi heiko,
nice solution.

Reviewed-by: Sandy Huang <hjc@rock-chips.com>

在 2018/9/23 20:37, Heiko Stuebner 写道:
> The hs_start interrupt on rk3188 fires at the start of a new frame, so
> serves essentially the same purpose as the dsp_hold_valid irq in checking
> when the last frame got delivered when going to standby. So define it
> to fix a hang on atomic_disable of the vop because the completion never
> really completed before.
> 
> Fixes: 428e15cc41e3 ("drm/rockchip: vop: add rk3188 vop definitions")
> Signed-off-by: Heiko Stuebner <heiko@sntech.de>
> ---
>   drivers/gpu/drm/rockchip/rockchip_vop_reg.c | 6 +++++-
>   1 file changed, 5 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/rockchip/rockchip_vop_reg.c b/drivers/gpu/drm/rockchip/rockchip_vop_reg.c
> index c482da41bb5d..226bb2a1720e 100644
> --- a/drivers/gpu/drm/rockchip/rockchip_vop_reg.c
> +++ b/drivers/gpu/drm/rockchip/rockchip_vop_reg.c
> @@ -465,7 +465,11 @@ static const struct vop_win_data rk3188_vop_win_data[] = {
>   };
>   
>   static const int rk3188_vop_intrs[] = {
> -	0,
> +	/*
> +	 * hs_start interrupt fires at frame-start, so serves
> +	 * the same purpose as dsp_hold in the driver.
> +	 */
> +	DSP_HOLD_VALID_INTR,
>   	FS_INTR,
>   	LINE_FLAG_INTR,
>   	BUS_ERROR_INTR,
>
Heiko Stübner Sept. 27, 2018, 10:14 a.m. UTC | #3
Am Sonntag, 23. September 2018, 14:37:30 CEST schrieb Heiko Stuebner:
> The hs_start interrupt on rk3188 fires at the start of a new frame, so
> serves essentially the same purpose as the dsp_hold_valid irq in checking
> when the last frame got delivered when going to standby. So define it
> to fix a hang on atomic_disable of the vop because the completion never
> really completed before.
> 
> Fixes: 428e15cc41e3 ("drm/rockchip: vop: add rk3188 vop definitions")
> Signed-off-by: Heiko Stuebner <heiko@sntech.de>

applied to drm-misc-next with Sandy's Review.
diff mbox series

Patch

diff --git a/drivers/gpu/drm/rockchip/rockchip_vop_reg.c b/drivers/gpu/drm/rockchip/rockchip_vop_reg.c
index c482da41bb5d..226bb2a1720e 100644
--- a/drivers/gpu/drm/rockchip/rockchip_vop_reg.c
+++ b/drivers/gpu/drm/rockchip/rockchip_vop_reg.c
@@ -465,7 +465,11 @@  static const struct vop_win_data rk3188_vop_win_data[] = {
 };
 
 static const int rk3188_vop_intrs[] = {
-	0,
+	/*
+	 * hs_start interrupt fires at frame-start, so serves
+	 * the same purpose as dsp_hold in the driver.
+	 */
+	DSP_HOLD_VALID_INTR,
 	FS_INTR,
 	LINE_FLAG_INTR,
 	BUS_ERROR_INTR,