• cpaul@redhat.com's avatar
    drm/i915/gen9: Get rid of redundant watermark values · d8c0fafc
    cpaul@redhat.com authored
    Now that we've make skl_wm_levels make a little more sense, we can
    remove all of the redundant wm information. Up until now we'd been
    storing two copies of all of the skl watermarks: one being the
    skl_pipe_wm structs, the other being the global wm struct in
    drm_i915_private containing the raw register values. This is confusing
    and problematic, since it means we're prone to accidentally letting the
    two copies go out of sync. So, get rid of all of the functions
    responsible for computing the register values and just use a single
    helper, skl_write_wm_level(), to convert and write the new watermarks on
    the fly.
    
    Changes since v1:
    - Fixup skl_write_wm_level()
    - Fixup skl_wm_level_from_reg_val()
    - Don't forget to copy *active to intel_crtc->wm.active.skl
    Changes since v2:
    - Fix usage of wrong cstate
    Changes since v3 (by Paulo):
    - Rebase
    Reviewed-by: default avatarMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
    Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com> (v2)
    Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
    Cc: Matt Roper <matthew.d.roper@intel.com>
    Cc: Paulo Zanoni <paulo.r.zanoni@intel.com>
    Signed-off-by: default avatarLyude <cpaul@redhat.com>
    Signed-off-by: default avatarPaulo Zanoni <paulo.r.zanoni@intel.com>
    Link: http://patchwork.freedesktop.org/patch/msgid/1476814189-6062-1-git-send-email-paulo.r.zanoni@intel.com
    d8c0fafc
intel_drv.h 60.9 KB