diff options
author | Jun Lei | 2019-01-15 16:46:46 +0100 |
---|---|---|
committer | Alex Deucher | 2019-03-05 21:09:32 +0100 |
commit | 0f1a6ad724cd5270c7c7d1bba98ac1222a0943b6 (patch) | |
tree | 3a36f3eaaaf08b5693b68f088d92f14f9b0153d1 /drivers/gpu/drm/amd/display/dc/dml | |
parent | drm/amd/display: Add disable triple buffering DC debug option (diff) | |
download | kernel-qcow2-linux-0f1a6ad724cd5270c7c7d1bba98ac1222a0943b6.tar.gz kernel-qcow2-linux-0f1a6ad724cd5270c7c7d1bba98ac1222a0943b6.tar.xz kernel-qcow2-linux-0f1a6ad724cd5270c7c7d1bba98ac1222a0943b6.zip |
drm/amd/display: PPLIB Hookup
[Why]
Make dml and integration with pplib clearer.
[How]
Change the way the dml formula is initialized to make its values more
clear. Restructure DC interface with pplib into rv_funcs.
Cap clocks received from pplib.
Signed-off-by: Jun Lei <Jun.Lei@amd.com>
Signed-off-by: Eryk Brol <eryk.brol@amd.com>
Reviewed-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@amd.com>
Acked-by: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/display/dc/dml')
-rw-r--r-- | drivers/gpu/drm/amd/display/dc/dml/display_mode_lib.c | 24 | ||||
-rw-r--r-- | drivers/gpu/drm/amd/display/dc/dml/display_mode_lib.h | 5 |
2 files changed, 29 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/dml/display_mode_lib.c b/drivers/gpu/drm/amd/display/dc/dml/display_mode_lib.c index d303b789adfe..a2bd3a651781 100644 --- a/drivers/gpu/drm/amd/display/dc/dml/display_mode_lib.c +++ b/drivers/gpu/drm/amd/display/dc/dml/display_mode_lib.c @@ -29,6 +29,12 @@ extern const struct _vcs_dpi_ip_params_st dcn1_0_ip; extern const struct _vcs_dpi_soc_bounding_box_st dcn1_0_soc; +static void set_soc_bounding_box_v2(struct display_mode_lib *lib, + const struct _vcs_dpi_soc_bounding_box_st *soc_bb) +{ + lib->soc = *soc_bb; +} + static void set_soc_bounding_box(struct _vcs_dpi_soc_bounding_box_st *soc, enum dml_project project) { switch (project) { @@ -41,6 +47,12 @@ static void set_soc_bounding_box(struct _vcs_dpi_soc_bounding_box_st *soc, enum } } +static void set_ip_params_v2(struct display_mode_lib *lib, + const struct _vcs_dpi_ip_params_st *ip_params) +{ + lib->ip = *ip_params; +} + static void set_ip_params(struct _vcs_dpi_ip_params_st *ip, enum dml_project project) { switch (project) { @@ -62,6 +74,18 @@ void dml_init_instance(struct display_mode_lib *lib, enum dml_project project) } } +void dml_init_instance_v2(struct display_mode_lib *lib, + const struct _vcs_dpi_soc_bounding_box_st *soc_bb, + const struct _vcs_dpi_ip_params_st *ip_params, + enum dml_project project) +{ + if (lib->project != project) { + set_soc_bounding_box_v2(lib, soc_bb); + set_ip_params_v2(lib, ip_params); + lib->project = project; + } +} + const char *dml_get_status_message(enum dm_validation_status status) { switch (status) { diff --git a/drivers/gpu/drm/amd/display/dc/dml/display_mode_lib.h b/drivers/gpu/drm/amd/display/dc/dml/display_mode_lib.h index a730e0209c05..93c0197ff272 100644 --- a/drivers/gpu/drm/amd/display/dc/dml/display_mode_lib.h +++ b/drivers/gpu/drm/amd/display/dc/dml/display_mode_lib.h @@ -43,6 +43,11 @@ struct display_mode_lib { void dml_init_instance(struct display_mode_lib *lib, enum dml_project project); +void dml_init_instance_v2(struct display_mode_lib *lib, + const struct _vcs_dpi_soc_bounding_box_st *soc_bb, + const struct _vcs_dpi_ip_params_st *ip_params, + enum dml_project project); + const char *dml_get_status_message(enum dm_validation_status status); #endif |