drm/i915/psr: Check vblank against IO buffer wake time on Lunarlake

As Lunarlake doesn't have block count configuration vblank should be
checked against IO buffer wake time.

Bspec: 68920

Signed-off-by: Jouni Högander <jouni.hogander@intel.com>
Reviewed-by: Animesh Manna <animesh.manna@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240607134917.1327574-13-jouni.hogander@intel.com
This commit is contained in:
Jouni Högander 2024-06-07 16:49:16 +03:00
parent aeafa46ee3
commit 99fcf46390

View File

@ -1246,9 +1246,13 @@ static int intel_psr_entry_setup_frames(struct intel_dp *intel_dp,
static bool wake_lines_fit_into_vblank(struct intel_dp *intel_dp,
const struct intel_crtc_state *crtc_state)
{
struct drm_i915_private *i915 = dp_to_i915(intel_dp);
int vblank = crtc_state->hw.adjusted_mode.crtc_vblank_end -
crtc_state->hw.adjusted_mode.crtc_vblank_start;
int wake_lines = psr2_block_count_lines(intel_dp);
int wake_lines;
wake_lines = DISPLAY_VER(i915) < 20 ? psr2_block_count_lines(intel_dp) :
intel_dp->alpm_parameters.io_wake_lines;
if (crtc_state->req_psr2_sdp_prior_scanline)
vblank -= 1;