SHA256
1
0
forked from pool/Mesa
Yuchen Lin 2018-04-10 07:50:55 +00:00 committed by Git OBS Bridge
commit 7c2957bef3
6 changed files with 30 additions and 127 deletions

View File

@ -1,3 +1,17 @@
-------------------------------------------------------------------
Thu Apr 5 08:37:03 UTC 2018 - msrb@suse.com
- Remove n_Disable-AMDGPU-GFX9-Vega-on-LLVM-lessthan-6.0.0.patch.
* Not needed since we build Mesa against LLVM 6. (bnc#1082298)
- Remove u_Fix-crash-in-swrast-when-setting-a-texture-for-a-pix.patch.
* It was disabled for long time and does not seem to be needed.
(bnc#1082306)
-------------------------------------------------------------------
Tue Apr 3 08:24:39 UTC 2018 - schwab@suse.de
- Enable nine on arm/aarch64
-------------------------------------------------------------------
Wed Mar 28 09:24:25 UTC 2018 - sndirsch@suse.com

View File

@ -64,7 +64,7 @@
%define vdpau_radeon 1
%endif
%ifarch %ix86 x86_64
%ifarch %ix86 x86_64 %arm aarch64
%define with_nine 1
%endif
@ -131,8 +131,6 @@ Source3: README.updates
Source4: manual-pages.tar.bz2
Source6: %{name}-rpmlintrc
Source7: Mesa.keyring
# to be upstreamed
Patch11: u_Fix-crash-in-swrast-when-setting-a-texture-for-a-pix.patch
# never to be upstreamed
Patch18: n_VDPAU-XVMC-libs-Replace-hardlinks-with-copies.patch
# currently needed for libglvnd support
@ -140,7 +138,6 @@ Patch31: archlinux_0001-Fix-linkage-against-shared-glapi.patch
Patch32: archlinux_glvnd-fix-gl-dot-pc.patch
# Upstream
Patch43: u_r600-egd_tables.py-make-the-script-python-2-3-compat.patch
Patch45: n_Disable-AMDGPU-GFX9-Vega-on-LLVM-lessthan-6.0.0.patch
Patch47: u_st-dri-don-t-set-queryDmaBufFormats-queryDmaBufModif.patch
BuildRequires: autoconf >= 2.60
@ -740,10 +737,6 @@ programs against the XA state tracker.
%setup -q -n %{_name_archive}-%{_version} -b4
# remove some docs
rm -rf docs/README.{VMS,WIN32,OS2}
### disabled, but not dropped yet; these still need investigation in
### order to figure out whether the issue is still reproducable and
### hence a fix is required
#%patch11 -p1
%patch18 -p1
%if 0%{?libglvnd}
@ -752,7 +745,6 @@ rm -rf docs/README.{VMS,WIN32,OS2}
%endif
%patch43 -p1
%patch45 -p1
%patch47 -p1
# Remove requires to libglvnd/libglvnd-devel from baselibs.conf when

View File

@ -1,3 +1,17 @@
-------------------------------------------------------------------
Thu Apr 5 08:37:03 UTC 2018 - msrb@suse.com
- Remove n_Disable-AMDGPU-GFX9-Vega-on-LLVM-lessthan-6.0.0.patch.
* Not needed since we build Mesa against LLVM 6. (bnc#1082298)
- Remove u_Fix-crash-in-swrast-when-setting-a-texture-for-a-pix.patch.
* It was disabled for long time and does not seem to be needed.
(bnc#1082306)
-------------------------------------------------------------------
Tue Apr 3 08:24:39 UTC 2018 - schwab@suse.de
- Enable nine on arm/aarch64
-------------------------------------------------------------------
Wed Mar 28 09:24:25 UTC 2018 - sndirsch@suse.com

View File

@ -63,7 +63,7 @@
%define vdpau_radeon 1
%endif
%ifarch %ix86 x86_64
%ifarch %ix86 x86_64 %arm aarch64
%define with_nine 1
%endif
@ -130,8 +130,6 @@ Source3: README.updates
Source4: manual-pages.tar.bz2
Source6: %{name}-rpmlintrc
Source7: Mesa.keyring
# to be upstreamed
Patch11: u_Fix-crash-in-swrast-when-setting-a-texture-for-a-pix.patch
# never to be upstreamed
Patch18: n_VDPAU-XVMC-libs-Replace-hardlinks-with-copies.patch
# currently needed for libglvnd support
@ -139,7 +137,6 @@ Patch31: archlinux_0001-Fix-linkage-against-shared-glapi.patch
Patch32: archlinux_glvnd-fix-gl-dot-pc.patch
# Upstream
Patch43: u_r600-egd_tables.py-make-the-script-python-2-3-compat.patch
Patch45: n_Disable-AMDGPU-GFX9-Vega-on-LLVM-lessthan-6.0.0.patch
Patch47: u_st-dri-don-t-set-queryDmaBufFormats-queryDmaBufModif.patch
BuildRequires: autoconf >= 2.60
@ -739,10 +736,6 @@ programs against the XA state tracker.
%setup -q -n %{_name_archive}-%{_version} -b4
# remove some docs
rm -rf docs/README.{VMS,WIN32,OS2}
### disabled, but not dropped yet; these still need investigation in
### order to figure out whether the issue is still reproducable and
### hence a fix is required
#%patch11 -p1
%patch18 -p1
%if 0%{?libglvnd}
@ -751,7 +744,6 @@ rm -rf docs/README.{VMS,WIN32,OS2}
%endif
%patch43 -p1
%patch45 -p1
%patch47 -p1
# Remove requires to libglvnd/libglvnd-devel from baselibs.conf when

View File

@ -1,60 +0,0 @@
From 63a73495438d621b8de24fa031a6af938bbf4ff4 Mon Sep 17 00:00:00 2001
From: Michal Srb <msrb@suse.com>
Date: Mon, 29 Jan 2018 11:38:28 +0100
Subject: [PATCH] Disable AMDGPU GFX9/Vega on LLVM < 6.0.0.
Upstream advertises support since LLVM 5.0.0, but it does not work properly:
https://bugzilla.opensuse.org/show_bug.cgi?id=1075901
---
src/amd/vulkan/winsys/amdgpu/radv_amdgpu_winsys.c | 13 ++++++++++---
src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c | 13 ++++++++++---
2 files changed, 20 insertions(+), 6 deletions(-)
Index: mesa-17.3.3/src/amd/vulkan/winsys/amdgpu/radv_amdgpu_winsys.c
===================================================================
--- mesa-17.3.3.orig/src/amd/vulkan/winsys/amdgpu/radv_amdgpu_winsys.c
+++ mesa-17.3.3/src/amd/vulkan/winsys/amdgpu/radv_amdgpu_winsys.c
@@ -46,9 +46,16 @@ do_winsys_init(struct radv_amdgpu_winsys
if (!ac_query_gpu_info(fd, ws->dev, &ws->info, &ws->amdinfo))
return false;
- /* LLVM 5.0 is required for GFX9. */
- if (ws->info.chip_class >= GFX9 && HAVE_LLVM < 0x0500) {
- fprintf(stderr, "amdgpu: LLVM 5.0 is required, got LLVM %i.%i\n",
+ /* LLVM 6.0 is required for GFX9. */
+ /*
+ Upstream version of Mesa allows GFX9 since LLVM 5.0, but it does not work correctly:
+ https://bugzilla.opensuse.org/show_bug.cgi?id=1075901
+ The issues are fixed in LLVM 6. We have decided to disable GFX9 support with LLVM 5
+ and wait for LLVM 6.
+ -- Michal Srb msrb@suse.com, 2018-01-29
+ */
+ if (ws->info.chip_class >= GFX9 && HAVE_LLVM < 0x0600) {
+ fprintf(stderr, "amdgpu: LLVM 6.0 is required, got LLVM %i.%i\n",
HAVE_LLVM >> 8, HAVE_LLVM & 255);
return false;
}
Index: mesa-17.3.3/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c
===================================================================
--- mesa-17.3.3.orig/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c
+++ mesa-17.3.3/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c
@@ -58,9 +58,16 @@ static bool do_winsys_init(struct amdgpu
if (!ac_query_gpu_info(fd, ws->dev, &ws->info, &ws->amdinfo))
goto fail;
- /* LLVM 5.0 is required for GFX9. */
- if (ws->info.chip_class >= GFX9 && HAVE_LLVM < 0x0500) {
- fprintf(stderr, "amdgpu: LLVM 5.0 is required, got LLVM %i.%i\n",
+ /* LLVM 6.0 is required for GFX9. */
+ /*
+ Upstream version of Mesa allows GFX9 since LLVM 5.0, but it does not work correctly:
+ https://bugzilla.opensuse.org/show_bug.cgi?id=1075901
+ The issues are fixed in LLVM 6. We have decided to disable GFX9 support with LLVM 5
+ and wait for LLVM 6.
+ -- Michal Srb msrb@suse.com, 2018-01-29
+ */
+ if (ws->info.chip_class >= GFX9 && HAVE_LLVM < 0x0600) {
+ fprintf(stderr, "amdgpu: LLVM 6.0 is required, got LLVM %i.%i\n",
HAVE_LLVM >> 8, HAVE_LLVM & 255);
goto fail;
}

View File

@ -1,49 +0,0 @@
From 26de08de6f27a5fe5fc6aaeee0ebedf40626ab04 Mon Sep 17 00:00:00 2001
From: Tobias Johannes Klausmann <tobias.johannes.klausmann@mni.thm.de>
Date: Fri, 20 Apr 2012 11:52:31 +0200
Subject: [PATCH] When glXBindTexImageEXT is called and SWrast is used there
will be a crash when sPriv->swrast_loader->getImage() is
called from swrastSetTexBuffer2(). Reason: no memory has
been allocated for the destination thus texImage->Data is
NULL. Call ctx->Driver.TexImage2D() to initialize this. If
memory has been allocated in a previous call free it first.
Signed-off-by: Egbert Eich <eich@freedesktop.org>
for 8.0.1
Ported to 8.0.2
Ported to 8.1
---
src/mesa/drivers/dri/swrast/swrast.c | 8 ++++++++
1 files changed, 8 insertions(+), 0 deletions(-)
diff --git a/src/mesa/drivers/dri/swrast/swrast.c b/src/mesa/drivers/dri/swrast/swrast.c
index d18dd09..dd7d0c0 100644
--- a/src/mesa/drivers/dri/swrast/swrast.c
+++ b/src/mesa/drivers/dri/swrast/swrast.c
@@ -66,6 +66,7 @@
static void swrastSetTexBuffer2(__DRIcontext *pDRICtx, GLint target,
GLint texture_format, __DRIdrawable *dPriv)
{
+ GET_CURRENT_CONTEXT(ctx);
struct dri_context *dri_ctx;
int x, y, w, h;
__DRIscreen *sPriv = dPriv->driScreenPriv;
@@ -96,6 +97,13 @@ static void swrastSetTexBuffer2(__DRIcontext *pDRICtx, GLint target,
_mesa_init_teximage_fields(&dri_ctx->Base, texImage,
w, h, 1, 0, internalFormat, texFormat);
+
+ if (texImage->Data)
+ ctx->Driver.FreeTexImageData(ctx, texImage);
+
+ ctx->Driver.TexImage2D(ctx, target, 0, internalFormat,
+ w, h, 0, texture_format, GL_UNSIGNED_INT_8_8_8_8,
+ NULL, &ctx->Unpack, texObj, texImage);
sPriv->swrast_loader->getImage(dPriv, x, y, w, h, (char *)swImage->Buffer,
dPriv->loaderPrivate);
--
1.7.7