From 6eeb7baa3a929b7ab6ef3a5bc1f4a00a538ed42b Mon Sep 17 00:00:00 2001 From: DistroBaker Date: Fri, 12 Mar 2021 00:51:11 +0000 Subject: [PATCH] Merged update from upstream sources This is an automated DistroBaker update from upstream sources. If you do not know what this is about or would like to opt out, contact the OSCI team. Source: https://src.fedoraproject.org/rpms/mesa.git#de16407125050cdc8ea73121a05d129676a2d5f9 --- ...ext-fix-regression-in-tegra_draw_vbo.patch | 38 +++++++++++++++++++ ...t-unwrap-indirect_draw_count-as-well.patch | 28 ++++++++++++++ mesa.spec | 11 +++++- 3 files changed, 76 insertions(+), 1 deletion(-) create mode 100644 0001-tegra-context-fix-regression-in-tegra_draw_vbo.patch create mode 100644 0002-tegra-context-unwrap-indirect_draw_count-as-well.patch diff --git a/0001-tegra-context-fix-regression-in-tegra_draw_vbo.patch b/0001-tegra-context-fix-regression-in-tegra_draw_vbo.patch new file mode 100644 index 0000000..e10737f --- /dev/null +++ b/0001-tegra-context-fix-regression-in-tegra_draw_vbo.patch @@ -0,0 +1,38 @@ +From a84c8ddb19beef7580d6a4b8c417bb188517412a Mon Sep 17 00:00:00 2001 +From: Karol Herbst +Date: Thu, 4 Mar 2021 20:32:10 +0100 +Subject: [PATCH 1/2] tegra/context: fix regression in tegra_draw_vbo + +We should only pass in a new indirect_info object if we actually set valid +values in it. + +Fixes: abe8ef862fe5 "gallium: make pipe_draw_indirect_info * a draw_vbo parameter" +Signed-off-by: Karol Herbst +Reviewed-by: Ilia Mirkin +Part-of: +--- + src/gallium/drivers/tegra/tegra_context.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/gallium/drivers/tegra/tegra_context.c b/src/gallium/drivers/tegra/tegra_context.c +index 1d976267aee..97b45ed1627 100644 +--- a/src/gallium/drivers/tegra/tegra_context.c ++++ b/src/gallium/drivers/tegra/tegra_context.c +@@ -75,13 +75,13 @@ tegra_draw_vbo(struct pipe_context *pcontext, + if (pindirect && pindirect->buffer) { + memcpy(&indirect, pindirect, sizeof(indirect)); + indirect.buffer = tegra_resource_unwrap(pindirect->buffer); ++ pindirect = &indirect; + } + + if (pinfo->index_size && !pinfo->has_user_indices) + info.index.resource = tegra_resource_unwrap(info.index.resource); + + pinfo = &info; +- pindirect = &indirect; + } + + context->gpu->draw_vbo(context->gpu, pinfo, pindirect, draws, num_draws); +-- +2.30.1 + diff --git a/0002-tegra-context-unwrap-indirect_draw_count-as-well.patch b/0002-tegra-context-unwrap-indirect_draw_count-as-well.patch new file mode 100644 index 0000000..c6330c1 --- /dev/null +++ b/0002-tegra-context-unwrap-indirect_draw_count-as-well.patch @@ -0,0 +1,28 @@ +From 12f1e42ed34e9807484bdfbec535bc56950e2338 Mon Sep 17 00:00:00 2001 +From: Karol Herbst +Date: Fri, 5 Mar 2021 10:46:48 +0100 +Subject: [PATCH 2/2] tegra/context: unwrap indirect_draw_count as well + +Fixes: 22f6624ed318 "gallium: separate indirect stuff from pipe_draw_info - 80 -> 56 bytes" +Signed-off-by: Karol Herbst +Reviewed-by: Ilia Mirkin +Part-of: +--- + src/gallium/drivers/tegra/tegra_context.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/src/gallium/drivers/tegra/tegra_context.c b/src/gallium/drivers/tegra/tegra_context.c +index 97b45ed1627..10b04f969ad 100644 +--- a/src/gallium/drivers/tegra/tegra_context.c ++++ b/src/gallium/drivers/tegra/tegra_context.c +@@ -75,6 +75,7 @@ tegra_draw_vbo(struct pipe_context *pcontext, + if (pindirect && pindirect->buffer) { + memcpy(&indirect, pindirect, sizeof(indirect)); + indirect.buffer = tegra_resource_unwrap(pindirect->buffer); ++ indirect.indirect_draw_count = tegra_resource_unwrap(pindirect->indirect_draw_count); + pindirect = &indirect; + } + +-- +2.30.1 + diff --git a/mesa.spec b/mesa.spec index 25d2143..2a798cb 100644 --- a/mesa.spec +++ b/mesa.spec @@ -52,7 +52,7 @@ Name: mesa Summary: Mesa graphics libraries %global ver 21.0.0-rc5 Version: %{lua:ver = string.gsub(rpm.expand("%{ver}"), "-", "~"); print(ver)} -Release: 2%{?dist} +Release: 3%{?dist} License: MIT URL: http://www.mesa3d.org @@ -65,6 +65,12 @@ Source1: Mesa-MLAA-License-Clarification-Email.txt # fix glx regression with sddm Patch1: 0001-glx-proposed-fix-for-setSwapInterval.patch +# fix GNOME crash on Jetson Nano: +# https://bugzilla.redhat.com/show_bug.cgi?id=1930977 +# https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9425 +Patch2: 0001-tegra-context-fix-regression-in-tegra_draw_vbo.patch +Patch3: 0002-tegra-context-unwrap-indirect_draw_count-as-well.patch + BuildRequires: meson >= 0.45 BuildRequires: gcc BuildRequires: gcc-c++ @@ -598,6 +604,9 @@ popd %endif %changelog +* Mon Mar 08 2021 Adam Williamson - 21.0.0~rc5-3 +- Backport MR #9425 to fix GNOME Shell crash on Jetson Nano (#1930977) + * Mon Feb 22 2021 Dave Airlie - 21.0.0~rc5-2 - fix sddm/vmware regression