Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

drm/i915/alpm: Allow LOBF only if window1 > alpm check_entry lines

LOBF must be disabled if the number of lines within Window 1 is not greater
than ALPM_CTL[ALPM Entry Check]

v2: Consider the case where SCL is in the active region. (Ville)

Bspec:71041
Signed-off-by: Ankit Nautiyal <ankit.k.nautiyal@intel.com>
Reviewed-by: Michał Grzelak <michal.grzelak@intel.com>
Link: https://patch.msgid.link/20260204050250.762718-3-ankit.k.nautiyal@intel.com

+22
+22
drivers/gpu/drm/i915/display/intel_alpm.c
··· 270 270 return first_sdp_position + waketime_in_lines + crtc_state->set_context_latency; 271 271 } 272 272 273 + static bool intel_alpm_lobf_is_window1_sufficient(struct intel_crtc_state *crtc_state) 274 + { 275 + struct drm_display_mode *adjusted_mode = &crtc_state->hw.adjusted_mode; 276 + int vblank = adjusted_mode->crtc_vtotal - adjusted_mode->crtc_vdisplay; 277 + int window1; 278 + 279 + /* 280 + * LOBF must be disabled if the number of lines within Window 1 is not 281 + * greater than ALPM_CTL[ALPM Entry Check] 282 + */ 283 + window1 = vblank - min(vblank, 284 + crtc_state->vrr.guardband + 285 + crtc_state->set_context_latency); 286 + 287 + return window1 > crtc_state->alpm_state.check_entry_lines; 288 + } 289 + 273 290 void intel_alpm_lobf_compute_config_late(struct intel_dp *intel_dp, 274 291 struct intel_crtc_state *crtc_state) 275 292 { ··· 295 278 296 279 if (!crtc_state->has_lobf) 297 280 return; 281 + 282 + if (!intel_alpm_lobf_is_window1_sufficient(crtc_state)) { 283 + crtc_state->has_lobf = false; 284 + return; 285 + } 298 286 299 287 /* 300 288 * LOBF can only be enabled if the time from the start of the SCL+Guardband