drm/amd/display: Find max flickerless instant vtotal delta

[WHAT & HOW]
 - Populate dml 2 callback with get_max_flickerless_instant_vtotal_increase
 - Use long long when necessary to prevent overflow
 - Add asic specific default values, currently disabled by
   default for every asic
 - Use the pre-existing debug option to protect the call to
   get_max_flickerless_instant_vtotal_increase

Reviewed-by: Alvin Lee <alvin.lee2@amd.com>
Acked-by: Alex Hung <alex.hung@amd.com>
Signed-off-by: Ethan Bitnun <etbitnun@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
Ethan Bitnun
2024-04-01 13:50:10 -04:00
committed by Alex Deucher
parent 2eb7d4b987
commit bd051aa2fc
5 changed files with 79 additions and 7 deletions

View File

@@ -58,4 +58,18 @@ bool dc_stream_is_refresh_rate_range_flickerless(struct dc_stream_state *stream,
int hz2,
bool is_gaming);
/*
* Determines the max instant vtotal delta increase that can be applied without
* flickering for a given stream
*/
unsigned int dc_stream_get_max_flickerless_instant_vtotal_decrease(struct dc_stream_state *stream,
bool is_gaming);
/*
* Determines the max instant vtotal delta decrease that can be applied without
* flickering for a given stream
*/
unsigned int dc_stream_get_max_flickerless_instant_vtotal_increase(struct dc_stream_state *stream,
bool is_gaming);
#endif // _DC_STREAM_PRIV_H_