From: Ville Syrjälä Date: Mon, 20 Oct 2025 18:50:23 +0000 (+0300) Subject: drm/i915/vrr: Move compute_fixed_rr_timings() X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=291119eb180e2cc6a3517e33a6327296ad027321;p=thirdparty%2Fkernel%2Flinux.git drm/i915/vrr: Move compute_fixed_rr_timings() Relocate intel_vrr_compute_fixed_rr_timings() next to its VRR and CMRR counterparts. Signed-off-by: Ville Syrjälä Link: https://patchwork.freedesktop.org/patch/msgid/20251020185038.4272-8-ville.syrjala@linux.intel.com Reviewed-by: Ankit Nautiyal --- diff --git a/drivers/gpu/drm/i915/display/intel_vrr.c b/drivers/gpu/drm/i915/display/intel_vrr.c index 9179ad53a2e76..99e10943368d2 100644 --- a/drivers/gpu/drm/i915/display/intel_vrr.c +++ b/drivers/gpu/drm/i915/display/intel_vrr.c @@ -246,6 +246,15 @@ void intel_vrr_compute_vrr_timings(struct intel_crtc_state *crtc_state, crtc_state->mode_flags |= I915_MODE_FLAG_VRR; } +static +void intel_vrr_compute_fixed_rr_timings(struct intel_crtc_state *crtc_state) +{ + /* For fixed rr, vmin = vmax = flipline */ + crtc_state->vrr.vmax = crtc_state->hw.adjusted_mode.crtc_vtotal; + crtc_state->vrr.vmin = crtc_state->vrr.vmax; + crtc_state->vrr.flipline = crtc_state->vrr.vmin; +} + static int intel_vrr_hw_value(const struct intel_crtc_state *crtc_state, int value) { @@ -308,15 +317,6 @@ void intel_vrr_set_fixed_rr_timings(const struct intel_crtc_state *crtc_state) intel_vrr_fixed_rr_hw_flipline(crtc_state) - 1); } -static -void intel_vrr_compute_fixed_rr_timings(struct intel_crtc_state *crtc_state) -{ - /* For fixed rr, vmin = vmax = flipline */ - crtc_state->vrr.vmax = crtc_state->hw.adjusted_mode.crtc_vtotal; - crtc_state->vrr.vmin = crtc_state->vrr.vmax; - crtc_state->vrr.flipline = crtc_state->vrr.vmin; -} - static int intel_vrr_compute_vmin(struct intel_crtc_state *crtc_state) {