aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915
diff options
context:
space:
mode:
authorShobhit Kumar <shobhit.kumar@intel.com>2014-04-09 04:29:33 -0400
committerDaniel Vetter <daniel.vetter@ffwll.ch>2014-04-09 15:54:29 -0400
commitf1c79f16d76f4698174a85921c5afb2c06ac614f (patch)
treea613e80ea2288dc788a4d1040556802a1c205149 /drivers/gpu/drm/i915
parent20e5bf667aa714e8010b0faa36fbb89ac2757e86 (diff)
drm/i915: Parameterize the Clockstop and escape_clk_div
In preparation for Generic driver Signed-off-by: Shobhit Kumar <shobhit.kumar@intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/i915')
-rw-r--r--drivers/gpu/drm/i915/intel_dsi.c11
-rw-r--r--drivers/gpu/drm/i915/intel_dsi.h4
2 files changed, 12 insertions, 3 deletions
diff --git a/drivers/gpu/drm/i915/intel_dsi.c b/drivers/gpu/drm/i915/intel_dsi.c
index 4793a5b3e00f..dfcdb1068495 100644
--- a/drivers/gpu/drm/i915/intel_dsi.c
+++ b/drivers/gpu/drm/i915/intel_dsi.c
@@ -495,10 +495,17 @@ static void intel_dsi_mode_set(struct intel_encoder *intel_encoder)
495 /* dphy stuff */ 495 /* dphy stuff */
496 496
497 /* in terms of low power clock */ 497 /* in terms of low power clock */
498 I915_WRITE(MIPI_INIT_COUNT(pipe), txclkesc(ESCAPE_CLOCK_DIVIDER_1, 100)); 498 I915_WRITE(MIPI_INIT_COUNT(pipe), txclkesc(intel_dsi->escape_clk_div, 100));
499
500 val = 0;
501 if (intel_dsi->eotp_pkt == 0)
502 val |= EOT_DISABLE;
503
504 if (intel_dsi->clock_stop)
505 val |= CLOCKSTOP;
499 506
500 /* recovery disables */ 507 /* recovery disables */
501 I915_WRITE(MIPI_EOT_DISABLE(pipe), intel_dsi->eot_disable); 508 I915_WRITE(MIPI_EOT_DISABLE(pipe), val);
502 509
503 /* in terms of txbyteclkhs. actual high to low switch + 510 /* in terms of txbyteclkhs. actual high to low switch +
504 * MIPI_STOP_STATE_STALL * MIPI_LP_BYTECLK. 511 * MIPI_STOP_STATE_STALL * MIPI_LP_BYTECLK.
diff --git a/drivers/gpu/drm/i915/intel_dsi.h b/drivers/gpu/drm/i915/intel_dsi.h
index b4a27cec882f..550714c7860e 100644
--- a/drivers/gpu/drm/i915/intel_dsi.h
+++ b/drivers/gpu/drm/i915/intel_dsi.h
@@ -95,8 +95,10 @@ struct intel_dsi {
95 u32 video_mode_format; 95 u32 video_mode_format;
96 96
97 /* eot for MIPI_EOT_DISABLE register */ 97 /* eot for MIPI_EOT_DISABLE register */
98 u32 eot_disable; 98 u8 eotp_pkt;
99 u8 clock_stop;
99 100
101 u8 escape_clk_div;
100 u32 port_bits; 102 u32 port_bits;
101 u32 bw_timer; 103 u32 bw_timer;
102 u32 dphy_reg; 104 u32 dphy_reg;