lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Wed, 24 Oct 2018 12:28:46 +0200
From:   Daniel Vetter <daniel@...ll.ch>
To:     Gerd Hoffmann <kraxel@...hat.com>
Cc:     dri-devel@...ts.freedesktop.org, David Airlie <airlied@...ux.ie>,
        open list <linux-kernel@...r.kernel.org>,
        Sean Paul <sean@...rly.run>
Subject: Re: [PATCH v3 1/2] drm: add drm_connector_attach_edid_property()

On Tue, Oct 02, 2018 at 01:10:40PM +0200, Gerd Hoffmann wrote:
> drm_connector_init doesn't attach the edid property for some connector
> types, drm_connector_attach_edid_property() can be used to enable the
> edid property in these cases.
> 
> Signed-off-by: Gerd Hoffmann <kraxel@...hat.com>
> Reviewed-by: Daniel Vetter <daniel.vetter@...ll.ch>
> ---
>  include/drm/drm_connector.h     |  1 +
>  drivers/gpu/drm/drm_connector.c | 23 ++++++++++++++++++++---
>  2 files changed, 21 insertions(+), 3 deletions(-)
> 
> diff --git a/include/drm/drm_connector.h b/include/drm/drm_connector.h
> index 97ea41dc67..4d58966b54 100644
> --- a/include/drm/drm_connector.h
> +++ b/include/drm/drm_connector.h
> @@ -1083,6 +1083,7 @@ int drm_connector_init(struct drm_device *dev,
>  		       struct drm_connector *connector,
>  		       const struct drm_connector_funcs *funcs,
>  		       int connector_type);
> +void drm_connector_attach_edid_property(struct drm_connector *connector);
>  int drm_connector_register(struct drm_connector *connector);
>  void drm_connector_unregister(struct drm_connector *connector);
>  int drm_connector_attach_encoder(struct drm_connector *connector,
> diff --git a/drivers/gpu/drm/drm_connector.c b/drivers/gpu/drm/drm_connector.c
> index 6011d769d5..486b784e4d 100644
> --- a/drivers/gpu/drm/drm_connector.c
> +++ b/drivers/gpu/drm/drm_connector.c
> @@ -256,9 +256,7 @@ int drm_connector_init(struct drm_device *dev,
>  
>  	if (connector_type != DRM_MODE_CONNECTOR_VIRTUAL &&
>  	    connector_type != DRM_MODE_CONNECTOR_WRITEBACK)
> -		drm_object_attach_property(&connector->base,
> -					      config->edid_property,
> -					      0);
> +		drm_connector_attach_edid_property(connector);
>  
>  	drm_object_attach_property(&connector->base,
>  				      config->dpms_property, 0);
> @@ -291,6 +289,25 @@ int drm_connector_init(struct drm_device *dev,
>  EXPORT_SYMBOL(drm_connector_init);
>  
>  /**
> + * drm_connector_attach_edid_property - attach edid property.
> + * @dev: DRM device

this makes kerneldoc unhappy. Can you pls run make htmldocs and fix?

Thanks, Daniel

> + * @connector: the connector
> + *
> + * Some connector types like DRM_MODE_CONNECTOR_VIRTUAL do not get a
> + * edid property attached by default.  This function can be used to
> + * explicitly enable the edid property in these cases.
> + */
> +void drm_connector_attach_edid_property(struct drm_connector *connector)
> +{
> +	struct drm_mode_config *config = &connector->dev->mode_config;
> +
> +	drm_object_attach_property(&connector->base,
> +				   config->edid_property,
> +				   0);
> +}
> +EXPORT_SYMBOL(drm_connector_attach_edid_property);
> +
> +/**
>   * drm_connector_attach_encoder - attach a connector to an encoder
>   * @connector: connector to attach
>   * @encoder: encoder to attach @connector to
> -- 
> 2.9.3
> 
> _______________________________________________
> dri-devel mailing list
> dri-devel@...ts.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ