Skip to content

Commit 6d7a793

Browse files
committed
drm/i915/display: Allow fastsets when DP_SDP_VSC infoframe do not match with PSR enabled
When PSR is enabled it handles DP_SDP_VSC, changing revision and all the other fields as necessary. It can also enabled and disable this SDP as needed without a full modeset. So here masking DP_SDP_VSC bit when previous and future state PSR enabled, it will still be checked when comparing the asked state to what was programmed to hardware. Cc: Gwan-gyeong Mun <[email protected]> Cc: Radhakrishna Sripada <[email protected]> Reported-by: Ville Syrjälä <[email protected]> Fixes: 78b772e ("drm/i915/display: Fill PSR state during hardware configuration read out") Signed-off-by: José Roberto de Souza <[email protected]> Reviewed-by: Gwan-gyeong Mun <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
1 parent 9b2e49a commit 6d7a793

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

drivers/gpu/drm/i915/display/intel_display.c

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8315,6 +8315,16 @@ intel_pipe_config_compare(const struct intel_crtc_state *current_config,
83158315
} \
83168316
} while (0)
83178317

8318+
#define PIPE_CONF_CHECK_X_WITH_MASK(name, mask) do { \
8319+
if ((current_config->name & (mask)) != (pipe_config->name & (mask))) { \
8320+
pipe_config_mismatch(fastset, crtc, __stringify(name), \
8321+
"(expected 0x%08x, found 0x%08x)", \
8322+
current_config->name & (mask), \
8323+
pipe_config->name & (mask)); \
8324+
ret = false; \
8325+
} \
8326+
} while (0)
8327+
83188328
#define PIPE_CONF_CHECK_I(name) do { \
83198329
if (current_config->name != pipe_config->name) { \
83208330
pipe_config_mismatch(fastset, crtc, __stringify(name), \
@@ -8661,7 +8671,12 @@ intel_pipe_config_compare(const struct intel_crtc_state *current_config,
86618671
PIPE_CONF_CHECK_I(min_voltage_level);
86628672
}
86638673

8664-
PIPE_CONF_CHECK_X(infoframes.enable);
8674+
if (fastset && (current_config->has_psr || pipe_config->has_psr))
8675+
PIPE_CONF_CHECK_X_WITH_MASK(infoframes.enable,
8676+
~intel_hdmi_infoframe_enable(DP_SDP_VSC));
8677+
else
8678+
PIPE_CONF_CHECK_X(infoframes.enable);
8679+
86658680
PIPE_CONF_CHECK_X(infoframes.gcp);
86668681
PIPE_CONF_CHECK_INFOFRAME(avi);
86678682
PIPE_CONF_CHECK_INFOFRAME(spd);

0 commit comments

Comments
 (0)