]> git.proxmox.com Git - mirror_ubuntu-disco-kernel.git/commit
drm/i915/cnl: Fix wrpll math for higher freqs.
authorRodrigo Vivi <rodrigo.vivi@intel.com>
Tue, 14 Nov 2017 23:42:23 +0000 (15:42 -0800)
committerRodrigo Vivi <rodrigo.vivi@intel.com>
Thu, 16 Nov 2017 17:44:48 +0000 (09:44 -0800)
commit063c886197f677f79f37fa62ce77b9df9bb0c3cf
tree422903ae7e6637e989bdc809289b57b249c41125
parent5eca81de88927f3e43fdd6e90e8fa5204be996b7
drm/i915/cnl: Fix wrpll math for higher freqs.

Spec describe all values in MHz. We handle our
clocks in KHz. This includes the best_dco_centrality that was
forgot in the same unity as spec. Consequently we couldn't
get a good divider for high frequenies. Hence HDMI 2.0 wasn't
working.

Spec tells 999999 for initial best_dco_centrality meaning the
max value in MHz.
Since we convert dco from MHz to KHz we also need to convert
this initial best_doc_centrality to 999999000 or 999999999
or even better, to the max that its variable allow.

This patch also replaces the use of "* KHz(1)" with the values
directly on KHz to avoid future confusion.

v2: Use U32_MAX instead of random 99999 as spec tells. (Ville).

Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Cc: Shashank Sharma <shashank.sharma@intel.com>
Cc: Mika Kahola <mika.kahola@intel.com>
Cc: Manasi Navare <manasi.d.navare@intel.com>
Cc: James Ausmus <james.ausmus@intel.com>
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20171114234223.10600-1-rodrigo.vivi@intel.com
drivers/gpu/drm/i915/intel_dpll_mgr.c