[PATCH 9/9] drm/amd/display: Implement MST Aux device registration

Kazlauskas, Nicholas Nicholas.Kazlauskas at amd.com
Wed Jul 24 20:05:36 UTC 2019


On 7/23/19 7:28 PM, sunpeng.li at amd.com wrote:
> From: Leo Li <sunpeng.li at amd.com>
> 
> Implement late_register and early_unregister hooks for MST connectors.
> Call drm helpers for MST connector registration, which registers the
> AUX devices.
> 
> Cc: Jerry Zuo <Jerry.Zuo at amd.com>
> Cc: Nicholas Kazlauskas <nicholas.kazlauskas at amd.com>
> Cc: Harry Wentland <harry.wentland at amd.com>
> Signed-off-by: Leo Li <sunpeng.li at amd.com>

Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas at amd.com>

BTW: I already reviewed patch 5, feel free to add my R-B.

Nicholas Kazlauskas

> ---
>   .../display/amdgpu_dm/amdgpu_dm_mst_types.c   | 24 ++++++++++++++++++-
>   1 file changed, 23 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_mst_types.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_mst_types.c
> index 53d2cfe62e13..16218a202b59 100644
> --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_mst_types.c
> +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_mst_types.c
> @@ -156,6 +156,26 @@ dm_dp_mst_connector_destroy(struct drm_connector *connector)
>   	kfree(amdgpu_dm_connector);
>   }
>   
> +static int
> +amdgpu_dm_mst_connector_late_register(struct drm_connector *connector)
> +{
> +	struct amdgpu_dm_connector *amdgpu_dm_connector =
> +		to_amdgpu_dm_connector(connector);
> +	struct drm_dp_mst_port *port = amdgpu_dm_connector->port;
> +
> +	return drm_dp_mst_connector_late_register(connector, port);
> +}
> +
> +static void
> +amdgpu_dm_mst_connector_early_unregister(struct drm_connector *connector)
> +{
> +	struct amdgpu_dm_connector *amdgpu_dm_connector =
> +		to_amdgpu_dm_connector(connector);
> +	struct drm_dp_mst_port *port = amdgpu_dm_connector->port;
> +
> +	drm_dp_mst_connector_early_unregister(connector, port);
> +}
> +
>   static const struct drm_connector_funcs dm_dp_mst_connector_funcs = {
>   	.detect = dm_dp_mst_detect,
>   	.fill_modes = drm_helper_probe_single_connector_modes,
> @@ -164,7 +184,9 @@ static const struct drm_connector_funcs dm_dp_mst_connector_funcs = {
>   	.atomic_duplicate_state = amdgpu_dm_connector_atomic_duplicate_state,
>   	.atomic_destroy_state = drm_atomic_helper_connector_destroy_state,
>   	.atomic_set_property = amdgpu_dm_connector_atomic_set_property,
> -	.atomic_get_property = amdgpu_dm_connector_atomic_get_property
> +	.atomic_get_property = amdgpu_dm_connector_atomic_get_property,
> +	.late_register = amdgpu_dm_mst_connector_late_register,
> +	.early_unregister = amdgpu_dm_mst_connector_early_unregister,
>   };
>   
>   static int dm_dp_mst_get_modes(struct drm_connector *connector)
> 



More information about the dri-devel mailing list