Re: [PATCH] drm: Fix drm_atomic_get_new_crtc_state call error

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Feb 01, 2021 at 05:33:44PM +0800, Zhaoge Zhang wrote:
> This position is to clear the previous mask flags,
> so drm_atomic_get_crtc_state should be used.
> 
> Signed-off-by: Zhaoge Zhang <zhangzhaoge@xxxxxxxxxxx>
> ---
>  drivers/gpu/drm/drm_atomic_uapi.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/gpu/drm/drm_atomic_uapi.c b/drivers/gpu/drm/drm_atomic_uapi.c
> index 268bb69..07fe01b 100644
> --- a/drivers/gpu/drm/drm_atomic_uapi.c
> +++ b/drivers/gpu/drm/drm_atomic_uapi.c
> @@ -313,8 +313,8 @@ drm_atomic_set_crtc_for_connector(struct drm_connector_state *conn_state,
>  		return 0;
>  
>  	if (conn_state->crtc) {
> -		crtc_state = drm_atomic_get_new_crtc_state(conn_state->state,
> -							   conn_state->crtc);
> +		crtc_state = drm_atomic_get_crtc_state(conn_state->state,
> +							conn_state->crtc);

drm_atomic_get_new_crtc_state() should be fine here since
drm_atomic_get_connector_state() will have added the old
crtc to the state already.

>  
>  		crtc_state->connector_mask &=
>  			~drm_connector_mask(conn_state->connector);
> -- 
> 2.7.4
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel@xxxxxxxxxxxxxxxxxxxxx
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

-- 
Ville Syrjälä
Intel
_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/dri-devel




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux