mirror of
https://github.com/torvalds/linux.git
synced 2026-11-30 10:32:24 +00:00
drm/amd/display: Always pass connector_state to stream validation
We need the connector_state for colorspace and scaling information and can get it from connector->state. Signed-off-by: Harry Wentland <[email protected]> Reviewed-by: Joshua Ashton <[email protected]> Cc: Pekka Paalanen <[email protected]> Cc: Sebastian Wick <[email protected]> Cc: [email protected] Cc: Joshua Ashton <[email protected]> Cc: Simon Ser <[email protected]> Cc: Melissa Wen <[email protected]> Cc: [email protected] Cc: [email protected] Signed-off-by: Alex Deucher <[email protected]>
This commit is contained in:
committed by
Alex Deucher
parent
c265f340ea
commit
cb841d27b8
@@ -5955,15 +5955,14 @@ create_stream_for_sink(struct amdgpu_dm_connector *aconnector,
|
||||
{
|
||||
struct drm_display_mode *preferred_mode = NULL;
|
||||
struct drm_connector *drm_connector;
|
||||
const struct drm_connector_state *con_state =
|
||||
dm_state ? &dm_state->base : NULL;
|
||||
const struct drm_connector_state *con_state = &dm_state->base;
|
||||
struct dc_stream_state *stream = NULL;
|
||||
struct drm_display_mode mode;
|
||||
struct drm_display_mode saved_mode;
|
||||
struct drm_display_mode *freesync_mode = NULL;
|
||||
bool native_mode_found = false;
|
||||
bool recalculate_timing = false;
|
||||
bool scale = dm_state ? (dm_state->scaling != RMX_OFF) : false;
|
||||
bool scale = dm_state->scaling != RMX_OFF;
|
||||
int mode_refresh;
|
||||
int preferred_refresh = 0;
|
||||
enum color_transfer_func tf = TRANSFER_FUNC_UNKNOWN;
|
||||
@@ -6605,7 +6604,9 @@ enum drm_mode_status amdgpu_dm_connector_mode_valid(struct drm_connector *connec
|
||||
goto fail;
|
||||
}
|
||||
|
||||
stream = create_validate_stream_for_sink(aconnector, mode, NULL, NULL);
|
||||
stream = create_validate_stream_for_sink(aconnector, mode,
|
||||
to_dm_connector_state(connector->state),
|
||||
NULL);
|
||||
if (stream) {
|
||||
dc_stream_release(stream);
|
||||
result = MODE_OK;
|
||||
|
||||
Reference in New Issue
Block a user