[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v5 6/8] ui/sdl2: Don't disable scanout when display is refreshed
From: |
Dmitry Osipenko |
Subject: |
[PATCH v5 6/8] ui/sdl2: Don't disable scanout when display is refreshed |
Date: |
Mon, 20 Jan 2025 01:00:48 +0300 |
Display refreshment is invoked by a timer and it erroneously disables
the active scanout if it happens to be invoked after scanout has been
enabled. This offending scanout-disable race condition with a timer
can be easily hit when Qemu runs with a disabled vsync by using SDL or
GTK displays (with vblank_mode=0 for GTK). Refreshment of display's
content shouldn't disable the active display. Fix it by keeping the
scanout's state unchanged when display is redrawn.
Reviewed-by: Akihiko Odaki <akihiko.odaki@daynix.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Dmitry Osipenko <dmitry.osipenko@collabora.com>
---
ui/sdl2-gl.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/ui/sdl2-gl.c b/ui/sdl2-gl.c
index 8d53e340d40d..31f8fbe03286 100644
--- a/ui/sdl2-gl.c
+++ b/ui/sdl2-gl.c
@@ -53,7 +53,6 @@ static void sdl2_gl_render_surface(struct sdl2_console *scon)
int ww, wh;
SDL_GL_MakeCurrent(scon->real_window, scon->winctx);
- sdl2_set_scanout_mode(scon, false);
SDL_GetWindowSize(scon->real_window, &ww, &wh);
surface_gl_setup_viewport(scon->gls, scon->surface, ww, wh);
--
2.47.1
[PATCH v5 5/8] virtio-gpu: Support DRM native context, Dmitry Osipenko, 2025/01/19
Message not available
Re: [PATCH v5 0/8] Support virtio-gpu DRM native context, Alex Bennée, 2025/01/22