drm/amd/display: Make DML2.1 P-State method force per stream
[WHY & HOW] Currently the force only works for a single display, make it so it can be forced per stream. Reviewed-by: Alvin Lee <alvin.lee2@amd.com> Cc: Mario Limonciello <mario.limonciello@amd.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org Signed-off-by: Alex Hung <alex.hung@amd.com> Signed-off-by: Dillon Varone <dillon.varone@amd.com> Tested-by: Daniel Wheeler <daniel.wheeler@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
committed by
Alex Deucher
parent
871512e36f
commit
020fccbe8f
@@ -1038,7 +1038,7 @@ struct dc_debug_options {
|
||||
bool force_chroma_subsampling_1tap;
|
||||
bool disable_422_left_edge_pixel;
|
||||
bool dml21_force_pstate_method;
|
||||
uint32_t dml21_force_pstate_method_value;
|
||||
uint32_t dml21_force_pstate_method_values[MAX_PIPES];
|
||||
uint32_t dml21_disable_pstate_method_mask;
|
||||
union dmub_fams2_global_feature_config fams2_config;
|
||||
bool enable_legacy_clock_update;
|
||||
|
||||
@@ -1000,7 +1000,7 @@ bool dml21_map_dc_state_into_dml_display_cfg(const struct dc *in_dc, struct dc_s
|
||||
/* apply forced pstate policy */
|
||||
if (dml_ctx->config.pmo.force_pstate_method_enable) {
|
||||
dml_dispcfg->plane_descriptors[disp_cfg_plane_location].overrides.uclk_pstate_change_strategy =
|
||||
dml21_force_pstate_method_to_uclk_state_change_strategy(dml_ctx->config.pmo.force_pstate_method_value);
|
||||
dml21_force_pstate_method_to_uclk_state_change_strategy(dml_ctx->config.pmo.force_pstate_method_values[stream_index]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -47,7 +47,8 @@ static void dml21_apply_debug_options(const struct dc *in_dc, struct dml2_contex
|
||||
/* UCLK P-State options */
|
||||
if (in_dc->debug.dml21_force_pstate_method) {
|
||||
dml_ctx->config.pmo.force_pstate_method_enable = true;
|
||||
dml_ctx->config.pmo.force_pstate_method_value = in_dc->debug.dml21_force_pstate_method_value;
|
||||
for (int i = 0; i < MAX_PIPES; i++)
|
||||
dml_ctx->config.pmo.force_pstate_method_values[i] = in_dc->debug.dml21_force_pstate_method_values[i];
|
||||
} else {
|
||||
dml_ctx->config.pmo.force_pstate_method_enable = false;
|
||||
}
|
||||
|
||||
@@ -230,7 +230,7 @@ struct dml2_configuration_options {
|
||||
struct socbb_ip_params_external *external_socbb_ip_params;
|
||||
struct {
|
||||
bool force_pstate_method_enable;
|
||||
enum dml2_force_pstate_methods force_pstate_method_value;
|
||||
enum dml2_force_pstate_methods force_pstate_method_values[MAX_PIPES];
|
||||
} pmo;
|
||||
bool map_dc_pipes_with_callbacks;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user