aboutsummaryrefslogtreecommitdiff
path: root/SOURCES/0002-drm-i915-add-kernel-parameter-to-disable-async-page-.patch
diff options
context:
space:
mode:
authorJan200101 <sentrycraft123@gmail.com>2023-03-13 19:18:44 +0100
committerJan200101 <sentrycraft123@gmail.com>2023-03-13 19:18:44 +0100
commitdfa9e804b976e592e66625167772e6ae3ed81d8a (patch)
tree2ffcacaabf258a4900c97f5f2379ffcd70b95a8d /SOURCES/0002-drm-i915-add-kernel-parameter-to-disable-async-page-.patch
parent07e8ea2c4e1d6adbbaf50e057951b6d6bfea4520 (diff)
downloadkernel-fsync-dfa9e804b976e592e66625167772e6ae3ed81d8a.tar.gz
kernel-fsync-dfa9e804b976e592e66625167772e6ae3ed81d8a.zip
kernel 6.1.16
Diffstat (limited to 'SOURCES/0002-drm-i915-add-kernel-parameter-to-disable-async-page-.patch')
-rw-r--r--SOURCES/0002-drm-i915-add-kernel-parameter-to-disable-async-page-.patch54
1 files changed, 54 insertions, 0 deletions
diff --git a/SOURCES/0002-drm-i915-add-kernel-parameter-to-disable-async-page-.patch b/SOURCES/0002-drm-i915-add-kernel-parameter-to-disable-async-page-.patch
new file mode 100644
index 0000000..09c5674
--- /dev/null
+++ b/SOURCES/0002-drm-i915-add-kernel-parameter-to-disable-async-page-.patch
@@ -0,0 +1,54 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Jan200101 <sentrycraft123@gmail.com>
+Date: Wed, 8 Mar 2023 20:51:16 +0100
+Subject: [PATCH] drm/i915: add kernel parameter to disable async page flipping
+
+Signed-off-by: Jan200101 <sentrycraft123@gmail.com>
+---
+ drivers/gpu/drm/i915/display/intel_display.c | 2 +-
+ drivers/gpu/drm/i915/i915_params.c | 4 ++++
+ drivers/gpu/drm/i915/i915_params.h | 3 ++-
+ 3 files changed, 7 insertions(+), 2 deletions(-)
+
+diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c
+index de77054195c6..43dbab8c46d0 100644
+--- a/drivers/gpu/drm/i915/display/intel_display.c
++++ b/drivers/gpu/drm/i915/display/intel_display.c
+@@ -8600,7 +8600,7 @@ static void intel_mode_config_init(struct drm_i915_private *i915)
+ mode_config->funcs = &intel_mode_funcs;
+ mode_config->helper_private = &intel_mode_config_funcs;
+
+- mode_config->async_page_flip = HAS_ASYNC_FLIPS(i915);
++ mode_config->async_page_flip = HAS_ASYNC_FLIPS(i915) && !i915->params.disable_async_page_flip;
+
+ /*
+ * Maximum framebuffer dimensions, chosen to match
+diff --git a/drivers/gpu/drm/i915/i915_params.c b/drivers/gpu/drm/i915/i915_params.c
+index d1e4d528cb17..b1281fcdc47b 100644
+--- a/drivers/gpu/drm/i915/i915_params.c
++++ b/drivers/gpu/drm/i915/i915_params.c
+@@ -219,6 +219,10 @@ i915_param_named_unsafe(lmem_size, uint, 0400,
+ i915_param_named_unsafe(lmem_bar_size, uint, 0400,
+ "Set the lmem bar size(in MiB).");
+
++i915_param_named_unsafe(disable_async_page_flip, bool, 0400,
++ "Disable async page flipping"
++ "(0=disabled [default], 1=enabled)");
++
+ static __always_inline void _print_param(struct drm_printer *p,
+ const char *name,
+ const char *type,
+diff --git a/drivers/gpu/drm/i915/i915_params.h b/drivers/gpu/drm/i915/i915_params.h
+index 2733cb6cfe09..d7b891bbd12b 100644
+--- a/drivers/gpu/drm/i915/i915_params.h
++++ b/drivers/gpu/drm/i915/i915_params.h
+@@ -84,7 +84,8 @@ struct drm_printer;
+ param(bool, verbose_state_checks, true, 0) \
+ param(bool, nuclear_pageflip, false, 0400) \
+ param(bool, enable_dp_mst, true, 0600) \
+- param(bool, enable_gvt, false, IS_ENABLED(CONFIG_DRM_I915_GVT) ? 0400 : 0)
++ param(bool, enable_gvt, false, IS_ENABLED(CONFIG_DRM_I915_GVT) ? 0400 : 0) \
++ param(bool, disable_async_page_flip, false, 0400)
+
+ #define MEMBER(T, member, ...) T member;
+ struct i915_params {