Commit 5922f453 authored by Mitul Golani's avatar Mitul Golani Committed by Suraj Kandpal
Browse files

drm/i915/display: Compute vrr vsync params



Compute vrr vsync params in case of FAVT as well instead of
only to AVT mode of operation.

--v2:
- Remove redundant computation for vrr_vsync_start
and vrr_vsync_end(Ankit).

--v3:
- vrr.enable and cmrr.enable check together is not required as both
will be true at the same point in time. (Ankit)
- Replace vrr.enable flag to cmrr.enable, mistakenly added. (Ankit)

Signed-off-by: default avatarMitul Golani <mitulkumar.ajitkumar.golani@intel.com>
Reviewed-by: default avatarAnkit Nautiyal <ankit.k.nautiyal@intel.com>
Signed-off-by: default avatarSuraj Kandpal <suraj.kandpal@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240610072203.24956-9-mitulkumar.ajitkumar.golani@intel.com
parent 0612514d
Loading
Loading
Loading
Loading
+9 −8
Original line number Diff line number Diff line
@@ -175,6 +175,8 @@ intel_vrr_compute_config(struct intel_crtc_state *crtc_state,
	if (crtc_state->uapi.vrr_enabled) {
		crtc_state->vrr.enable = true;
		crtc_state->mode_flags |= I915_MODE_FLAG_VRR;
	}

	if (intel_dp_as_sdp_supported(intel_dp)) {
		crtc_state->vrr.vsync_start =
			(crtc_state->hw.adjusted_mode.crtc_vtotal -
@@ -184,7 +186,6 @@ intel_vrr_compute_config(struct intel_crtc_state *crtc_state,
			 crtc_state->hw.adjusted_mode.vsync_end);
	}
}
}

static u32 trans_vrr_ctl(const struct intel_crtc_state *crtc_state)
{