summaryrefslogtreecommitdiff
path: root/extra/mesa
diff options
context:
space:
mode:
authordavidovski <david@davidovski.xyz>2022-04-11 13:30:34 +0100
committerdavidovski <david@davidovski.xyz>2022-04-11 13:30:34 +0100
commitbce4ac0f65ffb8bedcdcbdb94eb796457b12f9e1 (patch)
tree5070b9f21b192e6aa0f2a92584a7cbbc6a00d68c /extra/mesa
parent65f2daa1e41f38db5e29a73af9c02d6c390b1d24 (diff)
added files for pam and shadow
Diffstat (limited to 'extra/mesa')
-rw-r--r--extra/mesa/0001-radeonsi-On-Aarch64-force-persistent-buffers-to-GTT.patch38
-rw-r--r--extra/mesa/add-use-elf-tls.patch29
-rw-r--r--extra/mesa/disable-rgb10-by-default.patch25
-rw-r--r--extra/mesa/musl-fix-includes.patch13
4 files changed, 105 insertions, 0 deletions
diff --git a/extra/mesa/0001-radeonsi-On-Aarch64-force-persistent-buffers-to-GTT.patch b/extra/mesa/0001-radeonsi-On-Aarch64-force-persistent-buffers-to-GTT.patch
new file mode 100644
index 0000000..ea855f6
--- /dev/null
+++ b/extra/mesa/0001-radeonsi-On-Aarch64-force-persistent-buffers-to-GTT.patch
@@ -0,0 +1,38 @@
+From d72aa8ae74ffb7329003f9f23ffa05833af951ab Mon Sep 17 00:00:00 2001
+From: Jon Nettleton <jon@solid-run.com>
+Date: Fri, 14 Aug 2020 13:36:08 +0200
+Subject: [PATCH] radeonsi: On Aarch64 force persistent buffers to GTT
+
+This fixes a glamore corruption issue on the HoneyComb and by
+internet reports should also fix problems seen on Huaweii
+Kunpeng hardware.
+
+The root cause of the corruption needs to be worked out, but
+this patch also adds a noticable performance improvement. The
+aquarium webgl demo under chromium increases from 39-49 FPS
+when 5000 fish being rendered is selected. Glmark scores also
+improve by ~200 with no specific tests showing any regression.
+
+Signed-off-by: Jon Nettleton <jon@solid-run.com>
+---
+ src/gallium/drivers/radeonsi/si_buffer.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/src/gallium/drivers/radeonsi/si_buffer.c b/src/gallium/drivers/radeonsi/si_buffer.c
+index 6b58aebee2d..c9e983367a0 100644
+--- a/src/gallium/drivers/radeonsi/si_buffer.c
++++ b/src/gallium/drivers/radeonsi/si_buffer.c
+@@ -151,6 +151,11 @@ void si_init_resource_fields(struct si_screen *sscreen, struct si_resource *res,
+ */
+ if (!sscreen->info.kernel_flushes_hdp_before_ib || !sscreen->info.is_amdgpu)
+ res->domains = RADEON_DOMAIN_GTT;
++
++#if defined(PIPE_ARCH_AARCH64)
++ if (size <= 1024 * 512)
++ res->domains = RADEON_DOMAIN_GTT;
++#endif
+ }
+
+ /* Tiled textures are unmappable. Always put them in VRAM. */
+--
+2.26.2
diff --git a/extra/mesa/add-use-elf-tls.patch b/extra/mesa/add-use-elf-tls.patch
new file mode 100644
index 0000000..629c5ac
--- /dev/null
+++ b/extra/mesa/add-use-elf-tls.patch
@@ -0,0 +1,29 @@
+diff --git a/meson.build b/meson.build
+index e1e94e7..b355f94 100644
+--- a/meson.build
++++ b/meson.build
+@@ -447,7 +447,9 @@ endif
+
+ # Android uses emutls for versions <= P/28. For USE_ELF_TLS we need ELF TLS.
+ use_elf_tls = false
+-if (not ['freebsd', 'openbsd', 'haiku'].contains(host_machine.system()) and
++with_use_elf_tls = get_option('use-elf-tls')
++if with_use_elf_tls and
++ (not ['freebsd', 'openbsd', 'haiku'].contains(host_machine.system()) and
+ (not with_platform_android or get_option('platform-sdk-version') >= 29) and
+ (not with_platform_windows or not with_shared_glapi))
+ pre_args += '-DUSE_ELF_TLS'
+diff --git a/meson_options.txt b/meson_options.txt
+index a7030ab..73bd28e 100644
+--- a/meson_options.txt
++++ b/meson_options.txt
+@@ -465,3 +465,9 @@ option(
+ value : true,
+ description : 'use msse2 flag for mingw x86. Default: true',
+ )
++option(
++ 'use-elf-tls',
++ type : 'boolean',
++ value : false,
++ description : 'Build support for initial-exec TLS model'
++)
diff --git a/extra/mesa/disable-rgb10-by-default.patch b/extra/mesa/disable-rgb10-by-default.patch
new file mode 100644
index 0000000..6e1158b
--- /dev/null
+++ b/extra/mesa/disable-rgb10-by-default.patch
@@ -0,0 +1,25 @@
+From b33c8b56abcc4837f96f7f106b108681858482e0 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Jonas=20=C3=85dahl?= <jadahl@gmail.com>
+Date: Tue, 24 Apr 2018 09:46:41 +0200
+Subject: [PATCH] gallium: Disable rgb10 configs by default
+
+Applications tend to not handle rgb10 configs very well, so lets
+disable it for now.
+
+https://bugzilla.redhat.com/show_bug.cgi?id=1560481
+---
+ src/gallium/auxiliary/pipe-loader/driinfo_gallium.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/gallium/auxiliary/pipe-loader/driinfo_gallium.h b/src/gallium/auxiliary/pipe-loader/driinfo_gallium.h
+index 3b630f7..b542e0c 100644
+--- a/src/gallium/auxiliary/pipe-loader/driinfo_gallium.h
++++ b/src/gallium/auxiliary/pipe-loader/driinfo_gallium.h
+@@ -49,6 +49,6 @@ DRI_CONF_SECTION_MISCELLANEOUS
+ DRI_CONF_GLSL_ZERO_INIT(false)
+ DRI_CONF_VS_POSITION_ALWAYS_INVARIANT(false)
+ DRI_CONF_VS_POSITION_ALWAYS_PRECISE(false)
+- DRI_CONF_ALLOW_RGB10_CONFIGS(true)
++ DRI_CONF_ALLOW_RGB10_CONFIGS(false)
+ DRI_CONF_FORCE_INTEGER_TEX_NEAREST(false)
+ DRI_CONF_SECTION_END
diff --git a/extra/mesa/musl-fix-includes.patch b/extra/mesa/musl-fix-includes.patch
new file mode 100644
index 0000000..8553d44
--- /dev/null
+++ b/extra/mesa/musl-fix-includes.patch
@@ -0,0 +1,13 @@
+diff --git a/src/util/rand_xor.c b/src/util/rand_xor.c
+index 81b64f1ea71..14e6c9d27c3 100644
+--- a/src/util/rand_xor.c
++++ b/src/util/rand_xor.c
+@@ -27,6 +27,8 @@
+ #if !DETECT_OS_WINDOWS
+ #if defined(HAVE_GETRANDOM)
+ #include <sys/random.h>
++#include <sys/types.h>
++#include <sys/stat.h>
+ #endif
+ #include <unistd.h>
+ #include <fcntl.h>