[PATCH v2 14/15] drm/i2c/ch7006: Use helper to turn off CRTC

Francisco Jerez currojerez at riseup.net
Sat Jun 11 21:57:58 UTC 2016


Lukas Wunner <lukas at wunner.de> writes:

> Use shiny new drm_crtc_force_disable() instead of open coding the same.
> No functional change intended.
>
> Cc: Francisco Jerez <currojerez at riseup.net>
> Signed-off-by: Lukas Wunner <lukas at wunner.de>

Reviewed-by: Francisco Jerez <currojerez at riseup.net>

> ---
>  drivers/gpu/drm/i2c/ch7006_drv.c | 9 ++-------
>  1 file changed, 2 insertions(+), 7 deletions(-)
>
> diff --git a/drivers/gpu/drm/i2c/ch7006_drv.c b/drivers/gpu/drm/i2c/ch7006_drv.c
> index 0594c45..e9e8ae2 100644
> --- a/drivers/gpu/drm/i2c/ch7006_drv.c
> +++ b/drivers/gpu/drm/i2c/ch7006_drv.c
> @@ -361,13 +361,8 @@ static int ch7006_encoder_set_property(struct drm_encoder *encoder,
>  
>  		/* Disable the crtc to ensure a full modeset is
>  		 * performed whenever it's turned on again. */
> -		if (crtc) {
> -			struct drm_mode_set modeset = {
> -				.crtc = crtc,
> -			};
> -
> -			drm_mode_set_config_internal(&modeset);
> -		}
> +		if (crtc)
> +			drm_crtc_force_disable(crtc);
>  	}
>  
>  	return 0;
> -- 
> 2.8.1
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 212 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/dri-devel/attachments/20160611/8843899b/attachment.sig>


More information about the dri-devel mailing list