drm/i915/display: Extract code required to calculate max qgv/psf gv point
authorStanislav Lisovskiy <stanislav.lisovskiy@intel.com>
Fri, 5 Apr 2024 11:35:29 +0000 (14:35 +0300)
committerVinod Govindapillai <vinod.govindapillai@intel.com>
Fri, 19 Apr 2024 13:11:24 +0000 (16:11 +0300)
commit193caff1369e7dcfb9dafd69451b6e3a8d8caa85
tree4175d0ba3d835a98af91058ae395a3d50b1e92d0
parent92363681945088d4813341b749d89d22a1e5592d
drm/i915/display: Extract code required to calculate max qgv/psf gv point

We need that in order to force disable SAGV in next patch.
Also it is beneficial to separate that code, as in majority cases,
when SAGV is enabled, we don't even need those calculations.
Also we probably need to determine max PSF GV point as well, however
currently we don't do that when we disable SAGV, which might be
actually causing some issues in that case.

v2: - Introduce helper adl_qgv_bw(counterpart to adl_psf_bw)
      (Ville Syrjälä)
    - Don't restrict psf gv points for SAGV disable case
      (Ville Syrjälä)
v3: - Update icl_max_bw_qgv_point_mask to return max qgv point
      mask (Vinod)
v4: - Minor changes in icl_find_qgv_points (Vinod)
v5: - use max_bw_point instead of max_bw_point_mask (stan)

Reviewed-by: Jouni Högander <jouni.hogander@intel.com>
Signed-off-by: Stanislav Lisovskiy <stanislav.lisovskiy@intel.com>
Signed-off-by: Vinod Govindapillai <vinod.govindapillai@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240405113533.338553-3-vinod.govindapillai@intel.com
drivers/gpu/drm/i915/display/intel_bw.c