From: Ville Syrjälä <ville.syrjala@xxxxxxxxxxxxxxx> Once we've switched to using the swcursor (possibly due to the cursor ioctl failing) we currently keep using the swcursor until the modeset. That's not particularly great as the swcursor has several issues. Apart from the (presumably expected) flicker, the cursor also tends to leave horrible trails behind around dri2/3 windows (happens with tearfree at least). To avoid some of that let's try to switch back to the hwcursor a bit sooner. We can do that neatly via the convenient swcursor block handler. References: https://bugs.freedesktop.org/show_bug.cgi?id=106935 Signed-off-by: Ville Syrjälä <ville.syrjala@xxxxxxxxxxxxxxx> --- src/sna/sna_display.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/sna/sna_display.c b/src/sna/sna_display.c index 96e7b1bc50d3..4fdeebd2497c 100644 --- a/src/sna/sna_display.c +++ b/src/sna/sna_display.c @@ -6285,10 +6285,15 @@ static void enable_fb_access(ScrnInfoPtr scrn, int state) static void __restore_swcursor(ScrnInfoPtr scrn) { + struct sna *sna = to_sna(scrn); + DBG(("%s: attempting to restore SW cursor\n", __FUNCTION__)); enable_fb_access(scrn, FALSE); enable_fb_access(scrn, TRUE); + /* Try to switch back to the HW cursor on the next cursor update */ + sna->cursor.disable = false; + RemoveBlockAndWakeupHandlers((void *)__restore_swcursor, (void *)NoopDDA, scrn); -- 2.18.1 _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx