Message ID | 1349371203-15130-1-git-send-email-daniel.vetter@ffwll.ch (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Thu, 2012-10-04 at 19:20 +0200, Daniel Vetter wrote: > I've discovered this on my ivb machine while stress-testing the new > flip_tests. Only harmful effect observed is that the timestamp is a > bit bogus. > > Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> I've seen the same issue on an ivb ultrabook machine and the patch gets rid of it, so: Tested-by: Imre Deak <imre.deak@intel.com> > --- > drivers/gpu/drm/i915/intel_display.c | 10 ++++++++++ > 1 file changed, 10 insertions(+) > > diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c > index 67912fe..9cecfd7 100644 > --- a/drivers/gpu/drm/i915/intel_display.c > +++ b/drivers/gpu/drm/i915/intel_display.c > @@ -3253,6 +3253,16 @@ static void ironlake_crtc_enable(struct drm_crtc *crtc) > > if (HAS_PCH_CPT(dev)) > intel_cpt_verify_modeset(dev, intel_crtc->pipe); > + > + /* > + * There seems to be a race in PCH platform hw (at least on some > + * outputs) where an enabled pipe still completes any pageflip right > + * away (as if the pipe is off) instead of waiting for vblank. As soon > + * as the first vblank happend, everything works as expected. Hence just > + * wait for one vblank before returning to avoid strange things > + * happening. > + */ > + intel_wait_for_vblank(dev, intel_crtc->pipe); > } > > static void ironlake_crtc_disable(struct drm_crtc *crtc)
On Mon, Oct 08, 2012 at 08:19:20PM +0300, Imre Deak wrote: > On Thu, 2012-10-04 at 19:20 +0200, Daniel Vetter wrote: > > I've discovered this on my ivb machine while stress-testing the new > > flip_tests. Only harmful effect observed is that the timestamp is a > > bit bogus. > > > > Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> > > I've seen the same issue on an ivb ultrabook machine and the patch gets > rid of it, so: > > Tested-by: Imre Deak <imre.deak@intel.com> Applied with the commit message extended as per our irc discussion, and with your irc r-b applied. Thanks for testing&review. -Daniel
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index 67912fe..9cecfd7 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c @@ -3253,6 +3253,16 @@ static void ironlake_crtc_enable(struct drm_crtc *crtc) if (HAS_PCH_CPT(dev)) intel_cpt_verify_modeset(dev, intel_crtc->pipe); + + /* + * There seems to be a race in PCH platform hw (at least on some + * outputs) where an enabled pipe still completes any pageflip right + * away (as if the pipe is off) instead of waiting for vblank. As soon + * as the first vblank happend, everything works as expected. Hence just + * wait for one vblank before returning to avoid strange things + * happening. + */ + intel_wait_for_vblank(dev, intel_crtc->pipe); } static void ironlake_crtc_disable(struct drm_crtc *crtc)
I've discovered this on my ivb machine while stress-testing the new flip_tests. Only harmful effect observed is that the timestamp is a bit bogus. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> --- drivers/gpu/drm/i915/intel_display.c | 10 ++++++++++ 1 file changed, 10 insertions(+)