public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
* [PATCH] drm: Fix error path in drm_mode_page_flip_ioctl()
@ 2016-09-07 17:23 Imre Deak
  2016-09-07 17:54 ` ✗ Fi.CI.BAT: failure for " Patchwork
  2016-09-08  3:39 ` [PATCH] " Michel Dänzer
  0 siblings, 2 replies; 4+ messages in thread
From: Imre Deak @ 2016-09-07 17:23 UTC (permalink / raw)
  To: dri-devel; +Cc: intel-gfx, Michel Dänzer

This fixes the error path for platforms that don't define the new
page_flip_target() hook.

Fixes: c229bfbbd04 ("drm: Add page_flip_target CRTC hook v2")
Testcase: igt/kms_flip/basic-flip-vs-dpms
CC: Michel Dänzer <michel.daenzer@amd.com>
Signed-off-by: Imre Deak <imre.deak@intel.com>
---
 drivers/gpu/drm/drm_crtc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/drm_crtc.c b/drivers/gpu/drm/drm_crtc.c
index 0f797ee..d84a0ea 100644
--- a/drivers/gpu/drm/drm_crtc.c
+++ b/drivers/gpu/drm/drm_crtc.c
@@ -2047,7 +2047,7 @@ int drm_mode_page_flip_ioctl(struct drm_device *dev,
 	}
 
 out:
-	if (ret)
+	if (ret && crtc->funcs->page_flip_target)
 		drm_crtc_vblank_put(crtc);
 	if (fb)
 		drm_framebuffer_unreference(fb);
-- 
2.5.0

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2016-09-08  9:15 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-09-07 17:23 [PATCH] drm: Fix error path in drm_mode_page_flip_ioctl() Imre Deak
2016-09-07 17:54 ` ✗ Fi.CI.BAT: failure for " Patchwork
2016-09-08  3:39 ` [PATCH] " Michel Dänzer
2016-09-08  9:15   ` Jani Nikula

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox