OSDN Git Service

drm/i915/gen11+: Only load DRAM information from pcode
authorJosé Roberto de Souza <jose.souza@intel.com>
Thu, 28 Jan 2021 16:43:11 +0000 (08:43 -0800)
committerJosé Roberto de Souza <jose.souza@intel.com>
Fri, 29 Jan 2021 13:50:49 +0000 (05:50 -0800)
commit5d0c938ec9cc96fc7b8abcff0ca8b2a084e9c90c
tree9ceb126b2e31958960b566e6597c1cc372808fa6
parentf0b29707baa9e6f3d7b90090fcce62d2f1023fa1
drm/i915/gen11+: Only load DRAM information from pcode

Up to now we were reading some DRAM information from MCHBAR register
and from pcode what is already not good but some GEN12(TGL-H and ADL-S)
platforms have MCHBAR DRAM information in different offsets.

This was notified to HW team that decided that the best alternative is
always apply the 16gb_dimm watermark adjustment for GEN12+ platforms
and read the remaning DRAM information needed to other display
programming from pcode.

So here moving the DRAM pcode function to intel_dram.c, removing
the duplicated fields from intel_qgv_info, setting and using
information from dram_info.

v2:
- bring back num_points to intel_qgv_info as num_qgv_point can be
overwritten in icl_get_qgv_points()
- add gen12_get_dram_info() and simplify gen11_get_dram_info()

Reviewed-by: Lucas De Marchi <lucas.demarchi@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20210128164312.91160-2-jose.souza@intel.com
drivers/gpu/drm/i915/display/intel_bw.c
drivers/gpu/drm/i915/i915_drv.c
drivers/gpu/drm/i915/i915_drv.h
drivers/gpu/drm/i915/intel_dram.c