Once we have chosen the target CRTC, check for an error when querying the current MSC so we can report the error before attempting to record the uninitialised MSC/UST, and subsequently feeding garbage values to drmWaitVBlank.
Signed-off-by: Chris Wilson <[email protected]> --- present/present.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/present/present.c b/present/present.c index 1ce587e..4a1cf0c 100644 --- a/present/present.c +++ b/present/present.c @@ -727,7 +727,9 @@ present_pixmap(WindowPtr window, else if (!target_crtc) target_crtc = present_get_crtc(window); - present_get_ust_msc(screen, target_crtc, &ust, &crtc_msc); + ret = present_get_ust_msc(screen, target_crtc, &ust, &crtc_msc); + if (ret) + return ret; target_msc = present_window_to_crtc_msc(window, target_crtc, window_msc, crtc_msc); -- 2.1.4 _______________________________________________ [email protected]: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: http://lists.x.org/mailman/listinfo/xorg-devel
