From 076b086b9149949f063eb1416cd21bd3a17b7a74 Mon Sep 17 00:00:00 2001 From: Renbo Date: Mon, 19 Aug 2024 14:45:24 +0800 Subject: [PATCH 1/3] update to mesa-23.1.4-3.src.rpm Signed-off-by: Renbo --- ...one-for-newblock-allocation-in-dlist.patch | 28 +++++++++++++++++++ dist | 2 +- mesa.spec | 14 ++++++---- 3 files changed, 37 insertions(+), 7 deletions(-) create mode 100644 0001-mesa-fix-off-by-one-for-newblock-allocation-in-dlist.patch diff --git a/0001-mesa-fix-off-by-one-for-newblock-allocation-in-dlist.patch b/0001-mesa-fix-off-by-one-for-newblock-allocation-in-dlist.patch new file mode 100644 index 0000000..6862136 --- /dev/null +++ b/0001-mesa-fix-off-by-one-for-newblock-allocation-in-dlist.patch @@ -0,0 +1,28 @@ +From 460d2c46a903fed295a1528c8b6273dd6b0e0d19 Mon Sep 17 00:00:00 2001 +From: thfrwn <11335318+rfht@users.noreply.github.com> +Date: Fri, 9 Feb 2024 17:00:55 -0500 +Subject: [PATCH] mesa: fix off-by-one for newblock allocation in dlist_alloc + +Cc: mesa-stable +Reviewed-by: Pierre-Eric Pelloux-Prayer +Part-of: +--- + src/mesa/main/dlist.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/mesa/main/dlist.c b/src/mesa/main/dlist.c +index b0184a24e20..9213641699a 100644 +--- a/src/mesa/main/dlist.c ++++ b/src/mesa/main/dlist.c +@@ -1220,7 +1220,7 @@ dlist_alloc(struct gl_context *ctx, OpCode opcode, GLuint bytes, bool align8) + ctx->ListState.CurrentPos++; + } + +- if (ctx->ListState.CurrentPos + numNodes + contNodes > BLOCK_SIZE) { ++ if (ctx->ListState.CurrentPos + numNodes + contNodes >= BLOCK_SIZE) { + /* This block is full. Allocate a new block and chain to it */ + Node *newblock; + Node *n = ctx->ListState.CurrentBlock + ctx->ListState.CurrentPos; +-- +2.45.2 + diff --git a/dist b/dist index 9c0e36e..1fe92cf 100644 --- a/dist +++ b/dist @@ -1 +1 @@ -an8 +an8_10 diff --git a/mesa.spec b/mesa.spec index 1025ec5..eae5fe0 100644 --- a/mesa.spec +++ b/mesa.spec @@ -1,4 +1,3 @@ -%define anolis_release .0.1 %global llvm_toolset %{nil} %global llvm_pkg_prefix %{nil} @@ -22,7 +21,7 @@ %define with_vulkan_hw 0 %endif -%ifarch %{arm} aarch64 sw_64 +%ifarch %{arm} aarch64 %define with_xa 1 %endif @@ -39,7 +38,7 @@ Name: mesa Summary: Mesa graphics libraries Version: 23.1.4 -Release: 2%{?rctag:.%{rctag}}%{anolis_release}%{?dist} +Release: 3%{?rctag:.%{rctag}}%{?dist} License: MIT URL: http://www.mesa3d.org @@ -67,11 +66,13 @@ Patch12: radeonsi-turn-off-glthread.patch Patch13: 0001-llvmpipe-only-include-old-Transform-includes-when-ne.patch Patch14: 0001-clover-llvm-move-to-modern-pass-manager.patch +# https://issues.redhat.com/browse/RHEL-40566 +Patch15: 0001-mesa-fix-off-by-one-for-newblock-allocation-in-dlist.patch + BuildRequires: gcc BuildRequires: gcc-c++ BuildRequires: meson -BuildRequires: libzstd-devel %if %{with_hardware} BuildRequires: kernel-headers %endif @@ -589,8 +590,9 @@ done %endif %changelog -* Thu Jul 18 2024 wxiat - 23.1.4-2.0.1 -- cherry-pick `add sw arch #c1126ff1a67958f28b04b0e7e9aae6f07a4c15c4`. +* Thu Jun 20 2024 José Expósito - 23.1.4-3 +- Fix off-by-one error for newblock allocation in dlist_alloc + Resolves: https://issues.redhat.com/browse/RHEL-40566 * Thu Nov 23 2023 José Expósito - 23.1.4-2 - Rebuild against LLVM 17 -- Gitee From 1de16dc7a034b11af8d99948512ac1a3b6d44085 Mon Sep 17 00:00:00 2001 From: Renbo Date: Mon, 18 Dec 2023 15:13:48 +0800 Subject: [PATCH 2/3] add buildrequires libzstd-devel Signed-off-by: Renbo --- mesa.spec | 1 + 1 file changed, 1 insertion(+) diff --git a/mesa.spec b/mesa.spec index eae5fe0..a6d361b 100644 --- a/mesa.spec +++ b/mesa.spec @@ -73,6 +73,7 @@ BuildRequires: gcc BuildRequires: gcc-c++ BuildRequires: meson +BuildRequires: libzstd-devel %if %{with_hardware} BuildRequires: kernel-headers %endif -- Gitee From bb40c7bd2024ff904081a2f00504b9df1071c415 Mon Sep 17 00:00:00 2001 From: wxiat Date: Wed, 19 Jul 2023 17:28:56 +0800 Subject: [PATCH 3/3] cherry-pick `add sw arch #c1126ff1a67958f28b04b0e7e9aae6f07a4c15c4`. Signed-off-by: wxiat Signed-off-by: Weisson --- mesa.spec | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/mesa.spec b/mesa.spec index a6d361b..91299ab 100644 --- a/mesa.spec +++ b/mesa.spec @@ -1,3 +1,4 @@ +%define anolis_release .0.1 %global llvm_toolset %{nil} %global llvm_pkg_prefix %{nil} @@ -21,7 +22,7 @@ %define with_vulkan_hw 0 %endif -%ifarch %{arm} aarch64 +%ifarch %{arm} aarch64 sw_64 %define with_xa 1 %endif @@ -38,7 +39,7 @@ Name: mesa Summary: Mesa graphics libraries Version: 23.1.4 -Release: 3%{?rctag:.%{rctag}}%{?dist} +Release: 3%{?rctag:.%{rctag}}%{anolis_release}%{?dist} License: MIT URL: http://www.mesa3d.org @@ -591,6 +592,9 @@ done %endif %changelog +* Thu Jul 18 2024 wxiat - 23.1.4-3.0.1 +- cherry-pick `add sw arch #c1126ff1a67958f28b04b0e7e9aae6f07a4c15c4`. + * Thu Jun 20 2024 José Expósito - 23.1.4-3 - Fix off-by-one error for newblock allocation in dlist_alloc Resolves: https://issues.redhat.com/browse/RHEL-40566 -- Gitee