* [PATCH 1/2] drm/i915: DPI FIFO empty check is not needed @ 2014-07-03 11:05 Shobhit Kumar 2014-07-03 11:05 ` [PATCH 2/2] drm/i915: Update the DSI ULPS entry/exit sequence Shobhit Kumar 0 siblings, 1 reply; 4+ messages in thread From: Shobhit Kumar @ 2014-07-03 11:05 UTC (permalink / raw) To: intel-gfx; +Cc: Jani Nikula, Daniel Vetter While sending DPI SHUTDOWN command, we cannot wait for FIFO empty as pipes are not disabled at that time. In case of MIPI we disable port first and send SHUTDOWN command while pipe is still running and FIFOs will not be empty, causing spurious error log Signed-off-by: Shobhit Kumar <shobhit.kumar@intel.com> --- drivers/gpu/drm/i915/intel_dsi_cmd.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_dsi_cmd.c b/drivers/gpu/drm/i915/intel_dsi_cmd.c index 3eeb21b..933c863 100644 --- a/drivers/gpu/drm/i915/intel_dsi_cmd.c +++ b/drivers/gpu/drm/i915/intel_dsi_cmd.c @@ -404,12 +404,6 @@ int dpi_send_cmd(struct intel_dsi *intel_dsi, u32 cmd, bool hs) else cmd |= DPI_LP_MODE; - /* DPI virtual channel?! */ - - mask = DPI_FIFO_EMPTY; - if (wait_for((I915_READ(MIPI_GEN_FIFO_STAT(pipe)) & mask) == mask, 50)) - DRM_ERROR("Timeout waiting for DPI FIFO empty.\n"); - /* clear bit */ I915_WRITE(MIPI_INTR_STAT(pipe), SPL_PKT_SENT_INTERRUPT); -- 1.9.1 ^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 2/2] drm/i915: Update the DSI ULPS entry/exit sequence 2014-07-03 11:05 [PATCH 1/2] drm/i915: DPI FIFO empty check is not needed Shobhit Kumar @ 2014-07-03 11:05 ` Shobhit Kumar 2014-07-03 14:10 ` Chris Wilson 0 siblings, 1 reply; 4+ messages in thread From: Shobhit Kumar @ 2014-07-03 11:05 UTC (permalink / raw) To: intel-gfx; +Cc: Jani Nikula, Daniel Vetter We should keep DEVICE_READY bit set in the ULPS enter sequence. In exit sequence also we should set DEVICE_READY, but thats causing blankout for me. Also exit sequence is simplified as per hw team recommendation. This should fix - [drm:intel_dsi_clear_device_ready] *ERROR* DSI LP not going Low Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=80818 Signed-off-by: Shobhit Kumar <shobhit.kumar@intel.com> --- drivers/gpu/drm/i915/intel_dsi.c | 29 +++++++++++++++-------------- 1 file changed, 15 insertions(+), 14 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_dsi.c b/drivers/gpu/drm/i915/intel_dsi.c index a6a1355..967a5b6 100644 --- a/drivers/gpu/drm/i915/intel_dsi.c +++ b/drivers/gpu/drm/i915/intel_dsi.c @@ -117,17 +117,18 @@ static void intel_dsi_device_ready(struct intel_encoder *encoder) /* bandgap reset is needed after everytime we do power gate */ band_gap_reset(dev_priv); + I915_WRITE(MIPI_DEVICE_READY(pipe), ULPS_STATE_ENTER); + usleep_range(2500, 3000); + val = I915_READ(MIPI_PORT_CTRL(pipe)); I915_WRITE(MIPI_PORT_CTRL(pipe), val | LP_OUTPUT_HOLD); usleep_range(1000, 1500); - I915_WRITE(MIPI_DEVICE_READY(pipe), DEVICE_READY | ULPS_STATE_EXIT); - usleep_range(2000, 2500); - I915_WRITE(MIPI_DEVICE_READY(pipe), DEVICE_READY); - usleep_range(2000, 2500); - I915_WRITE(MIPI_DEVICE_READY(pipe), 0x00); - usleep_range(2000, 2500); + + I915_WRITE(MIPI_DEVICE_READY(pipe), ULPS_STATE_EXIT); + usleep_range(2500, 3000); + I915_WRITE(MIPI_DEVICE_READY(pipe), DEVICE_READY); - usleep_range(2000, 2500); + usleep_range(2500, 3000); } static void intel_dsi_enable(struct intel_encoder *encoder) @@ -271,23 +272,23 @@ static void intel_dsi_clear_device_ready(struct intel_encoder *encoder) DRM_DEBUG_KMS("\n"); - I915_WRITE(MIPI_DEVICE_READY(pipe), ULPS_STATE_ENTER); + I915_WRITE(MIPI_DEVICE_READY(pipe), DEVICE_READY | ULPS_STATE_ENTER); usleep_range(2000, 2500); - I915_WRITE(MIPI_DEVICE_READY(pipe), ULPS_STATE_EXIT); + I915_WRITE(MIPI_DEVICE_READY(pipe), DEVICE_READY | ULPS_STATE_EXIT); usleep_range(2000, 2500); - I915_WRITE(MIPI_DEVICE_READY(pipe), ULPS_STATE_ENTER); + I915_WRITE(MIPI_DEVICE_READY(pipe), DEVICE_READY | ULPS_STATE_ENTER); usleep_range(2000, 2500); - val = I915_READ(MIPI_PORT_CTRL(pipe)); - I915_WRITE(MIPI_PORT_CTRL(pipe), val & ~LP_OUTPUT_HOLD); - usleep_range(1000, 1500); - if (wait_for(((I915_READ(MIPI_PORT_CTRL(pipe)) & AFE_LATCHOUT) == 0x00000), 30)) DRM_ERROR("DSI LP not going Low\n"); + val = I915_READ(MIPI_PORT_CTRL(pipe)); + I915_WRITE(MIPI_PORT_CTRL(pipe), val & ~LP_OUTPUT_HOLD); + usleep_range(1000, 1500); + I915_WRITE(MIPI_DEVICE_READY(pipe), 0x00); usleep_range(2000, 2500); -- 1.9.1 ^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 2/2] drm/i915: Update the DSI ULPS entry/exit sequence 2014-07-03 11:05 ` [PATCH 2/2] drm/i915: Update the DSI ULPS entry/exit sequence Shobhit Kumar @ 2014-07-03 14:10 ` Chris Wilson 2014-07-04 14:26 ` Jani Nikula 0 siblings, 1 reply; 4+ messages in thread From: Chris Wilson @ 2014-07-03 14:10 UTC (permalink / raw) To: Shobhit Kumar; +Cc: Jani Nikula, Daniel Vetter, intel-gfx On Thu, Jul 03, 2014 at 04:35:41PM +0530, Shobhit Kumar wrote: > We should keep DEVICE_READY bit set in the ULPS enter sequence. In > exit sequence also we should set DEVICE_READY, but thats causing > blankout for me. Also exit sequence is simplified as per hw team > recommendation. > > This should fix - > [drm:intel_dsi_clear_device_ready] *ERROR* DSI LP not going Low > > Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=80818 > Signed-off-by: Shobhit Kumar <shobhit.kumar@intel.com> They silence that warning and appears to still work, Tested-by: Chris Wilson <chris@chris-wilson.co.uk> -Chris -- Chris Wilson, Intel Open Source Technology Centre ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 2/2] drm/i915: Update the DSI ULPS entry/exit sequence 2014-07-03 14:10 ` Chris Wilson @ 2014-07-04 14:26 ` Jani Nikula 0 siblings, 0 replies; 4+ messages in thread From: Jani Nikula @ 2014-07-04 14:26 UTC (permalink / raw) To: Chris Wilson, Shobhit Kumar; +Cc: Daniel Vetter, intel-gfx On Thu, 03 Jul 2014, Chris Wilson <chris@chris-wilson.co.uk> wrote: > On Thu, Jul 03, 2014 at 04:35:41PM +0530, Shobhit Kumar wrote: >> We should keep DEVICE_READY bit set in the ULPS enter sequence. In >> exit sequence also we should set DEVICE_READY, but thats causing >> blankout for me. Also exit sequence is simplified as per hw team >> recommendation. >> >> This should fix - >> [drm:intel_dsi_clear_device_ready] *ERROR* DSI LP not going Low >> >> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=80818 >> Signed-off-by: Shobhit Kumar <shobhit.kumar@intel.com> > > They silence that warning and appears to still work, > Tested-by: Chris Wilson <chris@chris-wilson.co.uk> Pushed to -fixes, thanks for the patches and testing. BR, Jani. > -Chris > > -- > Chris Wilson, Intel Open Source Technology Centre -- Jani Nikula, Intel Open Source Technology Center ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-07-04 14:27 UTC | newest] Thread overview: 4+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2014-07-03 11:05 [PATCH 1/2] drm/i915: DPI FIFO empty check is not needed Shobhit Kumar 2014-07-03 11:05 ` [PATCH 2/2] drm/i915: Update the DSI ULPS entry/exit sequence Shobhit Kumar 2014-07-03 14:10 ` Chris Wilson 2014-07-04 14:26 ` Jani Nikula
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox