Commit 5ad8e63e authored by Noralf Trønnes's avatar Noralf Trønnes

drm/gud: Enable synchronous flushing by default

gud has a module parameter that controls whether framebuffer flushing
happens synchronously during the commit or asynchronously in a worker.

GNOME before version 3.38 handled all displays in the same rendering loop.
This lead to gud slowing down the refresh rate for a faster monitor. This
has now been fixed so lets change the default.

The plan is to remove async flushing in the future. The code is now
structured in a way that makes it easy to do this.

Link: https://blogs.gnome.org/shell-dev/2020/07/02/splitting-up-the-frame-clock/Suggested-by: default avatarThomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: default avatarThomas Zimmermann <tzimmermann@suse.de>
Signed-off-by: default avatarNoralf Trønnes <noralf@tronnes.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20221122-gud-shadow-plane-v2-6-435037990a83@tronnes.org
parent c17d0486
...@@ -25,17 +25,13 @@ ...@@ -25,17 +25,13 @@
#include "gud_internal.h" #include "gud_internal.h"
/* /*
* Some userspace rendering loops runs all displays in the same loop. * Some userspace rendering loops run all displays in the same loop.
* This means that a fast display will have to wait for a slow one. * This means that a fast display will have to wait for a slow one.
* For this reason gud does flushing asynchronous by default. * Such users might want to enable this module parameter.
* The down side is that in e.g. a single display setup userspace thinks
* the display is insanely fast since the driver reports back immediately
* that the flush/pageflip is done. This wastes CPU and power.
* Such users might want to set this module parameter to false.
*/ */
static bool gud_async_flush = true; static bool gud_async_flush;
module_param_named(async_flush, gud_async_flush, bool, 0644); module_param_named(async_flush, gud_async_flush, bool, 0644);
MODULE_PARM_DESC(async_flush, "Enable asynchronous flushing [default=true]"); MODULE_PARM_DESC(async_flush, "Enable asynchronous flushing [default=0]");
/* /*
* FIXME: The driver is probably broken on Big Endian machines. * FIXME: The driver is probably broken on Big Endian machines.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment