qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Akihiko Odaki <akihiko.odaki@daynix.com>
To: "Dmitry Osipenko" <dmitry.osipenko@collabora.com>,
	"Marc-André Lureau" <marcandre.lureau@redhat.com>,
	"Philippe Mathieu-Daudé" <philmd@linaro.org>,
	"Gerd Hoffmann" <kraxel@redhat.com>,
	"Alex Bennée" <alex.bennee@linaro.org>
Cc: Gert Wollny <gert.wollny@collabora.com>,
	qemu-devel@nongnu.org,
	Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Subject: Re: [PATCH v1 1/2] ui/sdl2: Don't disable scanout when display is refreshed
Date: Tue, 8 Oct 2024 03:15:11 +0900	[thread overview]
Message-ID: <6ae662db-fba6-43a5-8be9-8de01dd4f476@daynix.com> (raw)
In-Reply-To: <20241006234353.3201037-2-dmitry.osipenko@collabora.com>

On 2024/10/07 8:43, Dmitry Osipenko wrote:
> 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.
> 
> Signed-off-by: Dmitry Osipenko <dmitry.osipenko@collabora.com>

Reviewed-by: Akihiko Odaki <akihiko.odaki@daynix.com>

> ---
>   ui/sdl2-gl.c | 1 -
>   1 file changed, 1 deletion(-)
> 
> diff --git a/ui/sdl2-gl.c b/ui/sdl2-gl.c
> index e01d9ab0c7bf..4975d923db38 100644
> --- a/ui/sdl2-gl.c
> +++ b/ui/sdl2-gl.c
> @@ -51,7 +51,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);



  reply	other threads:[~2024-10-07 18:15 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-06 23:43 [PATCH v1 0/2] GTK/SDL fixes for a black screen displayed by virtio-gpu Dmitry Osipenko
2024-10-06 23:43 ` [PATCH v1 1/2] ui/sdl2: Don't disable scanout when display is refreshed Dmitry Osipenko
2024-10-07 18:15   ` Akihiko Odaki [this message]
2024-10-07 19:17     ` Bernhard Beschow
2024-11-18 16:24     ` Dmitry Osipenko
2024-10-06 23:43 ` [PATCH v1 2/2] ui/gtk: " Dmitry Osipenko
2024-10-07 18:15   ` Akihiko Odaki
2024-10-07 19:26 ` [PATCH v1 0/2] GTK/SDL fixes for a black screen displayed by virtio-gpu Michael Tokarev
2024-10-07 20:19   ` Dmitry Osipenko
2024-10-07 20:48     ` Michael Tokarev
2024-10-07 20:59       ` Dmitry Osipenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6ae662db-fba6-43a5-8be9-8de01dd4f476@daynix.com \
    --to=akihiko.odaki@daynix.com \
    --cc=alex.bennee@linaro.org \
    --cc=dmitry.osipenko@collabora.com \
    --cc=gert.wollny@collabora.com \
    --cc=kraxel@redhat.com \
    --cc=marcandre.lureau@redhat.com \
    --cc=philmd@linaro.org \
    --cc=pierre-eric.pelloux-prayer@amd.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).