drm/i915/icl: Fix DDI/TC port clk_off bits
authorMahesh Kumar <mahesh1.kumar@intel.com>
Tue, 16 Oct 2018 02:37:52 +0000 (19:37 -0700)
committerRodrigo Vivi <rodrigo.vivi@intel.com>
Tue, 16 Oct 2018 16:01:01 +0000 (09:01 -0700)
commitbb1c7edc6d4d5cc6917814d858d47b22d2e93cde
treec77c9e654d12b7d35514f9325d19db1a46efb9cd
parent4e53840fdfdd054f645a03fa27f79296fa0d5d15
drm/i915/icl: Fix DDI/TC port clk_off bits

DDI/TC clock-off bits are not equally distanced. TC1-3 bits are
from offset 12 & TC4 is at offset 21.
Create a function to choose correct clk-off bit.

v2: Add fixes tag (Lucas)

Fixes: c27e917e2bda ("drm/i915/icl: add basic support for the ICL clocks")
Signed-off-by: Mahesh Kumar <mahesh1.kumar@intel.com>
Signed-off-by: Vandita Kulkarni <vandita.kulkarni@intel.com>
Reviewed-by: Lucas De Marchi <lucas.demarchi@intel.com>
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20181016023752.9285-1-lucas.demarchi@intel.com
drivers/gpu/drm/i915/i915_reg.h
drivers/gpu/drm/i915/intel_ddi.c