1
0
mirror of https://github.com/openbsd/src.git synced 2026-06-18 07:13:36 +02:00

drm/i915/psr: Apply Intel DPCD workaround when SDP on prior line used

From Jouni Hogander
487393023feb57ce5305e00eaae21dd50520f3d0 in linux-6.18.y/6.18.35
4703049f768fc1c1caac754134118bee1a3af189 in mainline linux
This commit is contained in:
jsg
2026-06-09 23:57:49 +00:00
parent 16db0c9d8b
commit 440984bd8b
+27 -1
View File
@@ -29,6 +29,7 @@
#include <drm/drm_vblank.h>
#include "i915_reg.h"
#include "i915_utils.h"
#include "intel_alpm.h"
#include "intel_atomic.h"
#include "intel_crtc.h"
@@ -1315,6 +1316,30 @@ static bool psr2_granularity_check(struct intel_dp *intel_dp,
return true;
}
static bool apply_scanline_indication_wa(struct intel_dp *intel_dp,
struct intel_crtc_state *crtc_state)
{
u8 early_scanline_support = intel_dp->intel_wa_dpcd &
INTEL_DPCD_INTEL_WA_REGISTER_CAPS_PSR2_EARLYSCANLINE_SDP_SUPPORT_MASK;
if (intel_dp->edp_dpcd[0] >= DP_EDP_15)
return true;
switch (early_scanline_support) {
case INTEL_DPCD_INTEL_WA_REGISTER_CAPS_FALL_BACK_TO_PSR1:
crtc_state->req_psr2_sdp_prior_scanline = false;
return false;
case INTEL_DPCD_INTEL_WA_REGISTER_CAPS_PSR2_WITH_EARLY_SCANLINE:
return true;
case INTEL_DPCD_INTEL_WA_REGISTER_CAPS_PSR2_WITHOUT_EARLY_SCANLINE:
crtc_state->req_psr2_sdp_prior_scanline = false;
return true;
default:
MISSING_CASE(early_scanline_support);
return false;
}
}
static bool _compute_psr2_sdp_prior_scanline_indication(struct intel_dp *intel_dp,
struct intel_crtc_state *crtc_state)
{
@@ -1336,7 +1361,8 @@ static bool _compute_psr2_sdp_prior_scanline_indication(struct intel_dp *intel_d
return false;
crtc_state->req_psr2_sdp_prior_scanline = true;
return true;
return apply_scanline_indication_wa(intel_dp, crtc_state);
}
static int intel_psr_entry_setup_frames(struct intel_dp *intel_dp,