Re: [PATCH 16/21] drm/omap: Merge HPD enable operation with HPD callback registration

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

 



Hi,

On Wed, Jun 06, 2018 at 12:36:45PM +0300, Laurent Pinchart wrote:
> The omap_dss_device .enable_hpd() and .disable_hpd() are used to enable
> and disable hot-plug detection at omapdrm probe and remove time. This is
> required to avoid reporting hot-plug detection events before the DRM
> infrastructure is ready to accept them, as that could result in crashes
> or other malfunction.
> 
> Hot-plug event reporting is conditioned by both HPD being enabled
> through the .enable_hpd() operation and by the HPD callback being
> registered though the .register_hpd_cb() operation. We thus don't need a
> separate enable operation if we can guarantee that callbacks won't be
> registered too early.
> 
> HPD callbacks are registered at connector initialization time, which is
> too early to start reporting HPD events. There's however nothing
> blocking a move of callback registration to a later time when the
> omapdrm driver calls the HPD enable operations. Do so, and remove the
> HPD enable operation completely from omap_dss_device drivers.
> 
> Signed-off-by: Laurent Pinchart <laurent.pinchart@xxxxxxxxxxxxxxxx>
> ---
>
> [...]
>
> @@ -391,12 +387,8 @@ static void omap_modeset_disable_external_hpd(struct drm_device *ddev)
>  	struct omap_drm_private *priv = ddev->dev_private;
>  	int i;
>  
> -	for (i = 0; i < priv->num_pipes; i++) {
> -		struct omap_dss_device *display = priv->pipes[i].display;
> -
> -		if (display->ops->disable_hpd)
> -			display->ops->disable_hpd(display);
> -	}
> +	for (i = 0; i < priv->num_pipes; i++)
> +		omap_connector_enable_hpd(priv->pipes[i].connector);
>  }
>  
>  /*
> -- 

omap_connector_disable_hpd... Otherwise:

Reviewed-by: Sebastian Reichel <sebastian.reichel@xxxxxxxxxxxxxxx>

-- Sebastian

Attachment: signature.asc
Description: PGP signature

_______________________________________________
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