drm/amd/display: add more link_hwss types and method to decide which one

[why]
as we add more link_hwss we are making a generic way to determine which type
of link_hwss we should use.
Later on we may think of introduce a link policy layer. it could be a thin layer
that decide the type of link_hwss we use. So instead of passing in link and link_res
we can just pass in link_policy and swtich based on link_policy->get_link_hwss_type.

Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Reviewed-by: Aric Cyr <Aric.Cyr@amd.com>
Acked-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Signed-off-by: Wenjing Liu <wenjing.liu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
Wenjing Liu
2022-01-19 16:24:40 +08:00
committed by Alex Deucher
parent 5279e09161
commit ccba4e5bc8
2 changed files with 50 additions and 6 deletions

View File

@@ -78,6 +78,9 @@ struct fixed31_32;
struct pipe_ctx;
struct dc_link_hwss {
/* you must define a dummy implementation and assign the function to
* dummy_link_hwss if you don't want to check for NULL pointer
*/
void (*set_throttled_vcp_size)(struct pipe_ctx *pipe_ctx,
struct fixed31_32 throttled_vcp_size);