]> git.baikalelectronics.ru Git - kernel.git/commitdiff
drm/i915/dg2: Don't read DRAM info
authorMatt Roper <matthew.d.roper@intel.com>
Wed, 21 Jul 2021 22:30:42 +0000 (15:30 -0700)
committerMatt Roper <matthew.d.roper@intel.com>
Thu, 22 Jul 2021 16:31:39 +0000 (09:31 -0700)
DG2 does not use system DRAM information for BW_BUDDY programming or
watermark workarounds, so there's no need to read this out at startup.

Cc: Anusha Srivatsa <anusha.srivatsa@intel.com>
Signed-off-by: Matt Roper <matthew.d.roper@intel.com>
Reviewed-by: Anusha Srivatsa <anusha.srivatsa@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20210721223043.834562-18-matthew.d.roper@intel.com
drivers/gpu/drm/i915/intel_dram.c

index 879b0f007be31a525b0b420538a885652b8fa46e..9675bb94b70b7a625288b7b8f26816c71af0335d 100644 (file)
@@ -494,15 +494,15 @@ void intel_dram_detect(struct drm_i915_private *i915)
        struct dram_info *dram_info = &i915->dram_info;
        int ret;
 
+       if (GRAPHICS_VER(i915) < 9 || IS_DG2(i915) || !HAS_DISPLAY(i915))
+               return;
+
        /*
         * Assume level 0 watermark latency adjustment is needed until proven
         * otherwise, this w/a is not needed by bxt/glk.
         */
        dram_info->wm_lv_0_adjust_needed = !IS_GEN9_LP(i915);
 
-       if (GRAPHICS_VER(i915) < 9 || !HAS_DISPLAY(i915))
-               return;
-
        if (GRAPHICS_VER(i915) >= 12)
                ret = gen12_get_dram_info(i915);
        else if (GRAPHICS_VER(i915) >= 11)