[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

mesa: Changes to 'debian-unstable'



 Makefile.am                                         |    2 
 bin/.cherry-ignore                                  |   25 +++
 bin/get-pick-list.sh                                |    2 
 configure.ac                                        |    6 
 debian/changelog                                    |   10 -
 docs/relnotes-9.1.5.html                            |    4 
 docs/relnotes-9.1.6.html                            |  166 ++++++++++++++++++++
 src/egl/drivers/dri2/platform_x11.c                 |   14 +
 src/gallium/auxiliary/vl/vl_winsys_dri.c            |   20 ++
 src/gallium/drivers/nv50/nv50_stateobj.h            |    2 
 src/gallium/drivers/nvc0/nvc0_stateobj.h            |    2 
 src/gallium/drivers/nvc0/nvc0_video.c               |    2 
 src/gallium/drivers/r300/r300_context.c             |    6 
 src/gallium/drivers/r300/r300_render.c              |   70 +++-----
 src/gallium/drivers/r300/r300_screen_buffer.c       |    7 
 src/gallium/drivers/r300/r300_texture_desc.c        |    1 
 src/gallium/drivers/r600/r600_shader.c              |    2 
 src/gallium/drivers/r600/r600_shader.h              |    4 
 src/gallium/state_trackers/egl/wayland/native_shm.c |    2 
 src/glsl/glsl_lexer.ll                              |    2 
 src/glsl/loop_analysis.cpp                          |    3 
 src/glx/apple/apple_glx.c                           |    2 
 src/mesa/drivers/common/meta.c                      |   23 ++
 src/mesa/drivers/dri/i965/brw_fs.cpp                |   10 -
 src/mesa/drivers/dri/i965/brw_fs_visitor.cpp        |    4 
 src/mesa/drivers/dri/i965/brw_vec4.cpp              |   12 +
 src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp      |    4 
 src/mesa/drivers/dri/i965/brw_vs.c                  |    8 
 src/mesa/drivers/dri/i965/brw_vs_state.c            |   27 ++-
 src/mesa/main/mipmap.c                              |   68 +++++---
 src/mesa/main/texgetimage.c                         |   52 ++----
 src/mesa/main/version.h                             |    4 
 32 files changed, 430 insertions(+), 136 deletions(-)

New commits:
commit d483ad18f36de0d9088943ccd0eee2d5e8308f33
Author: Andreas Boll <andreas.boll.dev@gmail.com>
Date:   Fri Aug 2 12:14:09 2013 +0200

    debian/changelog: Add changelog entry

diff --git a/debian/changelog b/debian/changelog
index 87709bf..2ef33bb 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,6 +1,8 @@
 mesa (9.1.6-1) UNRELEASED; urgency=low
 
   * New upstream release. (Closes: #717410)
+  * Cherry-pick commit 0dbbfa0 (mesa: Fix MESA_PATCH version) from
+    upstream.
 
  -- Andreas Boll <andreas.boll.dev@gmail.com>  Fri, 02 Aug 2013 12:04:47 +0200
 

commit a4921e7ba7916addf224e188ca73a897ff19c7a6
Author: Andreas Boll <andreas.boll.dev@gmail.com>
Date:   Fri Aug 2 09:51:24 2013 +0200

    mesa: Fix MESA_PATCH version
    
    (cherry picked from commit 0dbbfa054c91980a093c0146bd281624cc74695d)

diff --git a/src/mesa/main/version.h b/src/mesa/main/version.h
index 6eab691..27eb76d 100644
--- a/src/mesa/main/version.h
+++ b/src/mesa/main/version.h
@@ -34,7 +34,7 @@ struct gl_context;
 /* Mesa version */
 #define MESA_MAJOR 9
 #define MESA_MINOR 1
-#define MESA_PATCH 4
+#define MESA_PATCH 6
 #define MESA_VERSION_STRING "9.1.6"
 
 /* To make version comparison easy */

commit 86a52b857f578a14d81ffc094a9c1dcffb129431
Author: Andreas Boll <andreas.boll.dev@gmail.com>
Date:   Fri Aug 2 12:08:46 2013 +0200

    New upstream release

diff --git a/debian/changelog b/debian/changelog
index 66d4421..87709bf 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,10 +1,8 @@
-mesa (9.1.5-1) UNRELEASED; urgency=low
+mesa (9.1.6-1) UNRELEASED; urgency=low
 
-  * New upstream release.
-  * Cherry-pick commit b20b2b6 (osmesa: link against static libglapi
-    library too to get the gl exports) from upstream (Closes: #717410).
+  * New upstream release. (Closes: #717410)
 
- -- Andreas Boll <andreas.boll.dev@gmail.com>  Thu, 18 Jul 2013 18:32:24 +0200
+ -- Andreas Boll <andreas.boll.dev@gmail.com>  Fri, 02 Aug 2013 12:04:47 +0200
 
 mesa (9.1.4-1) unstable; urgency=low
 

commit 1ed76d697fccba03e72b1a48f3ce866984fa3899
Author: Carl Worth <cworth@cworth.org>
Date:   Thu Aug 1 14:21:21 2013 -0700

    docs: Add release notes for 9.1.6 release

diff --git a/docs/relnotes-9.1.6.html b/docs/relnotes-9.1.6.html
new file mode 100644
index 0000000..1e55b8e
--- /dev/null
+++ b/docs/relnotes-9.1.6.html
@@ -0,0 +1,166 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd";>
+<html lang="en">
+<head>
+  <meta http-equiv="content-type" content="text/html; charset=utf-8">
+  <title>Mesa Release Notes</title>
+  <link rel="stylesheet" type="text/css" href="mesa.css">
+</head>
+<body>
+
+<div class="header">
+  <h1>The Mesa 3D Graphics Library</h1>
+</div>
+
+<iframe src="contents.html"></iframe>
+<div class="content">
+
+<h1>Mesa 9.1.6 Release Notes / August 1, 2013</h1>
+
+<p>
+Mesa 9.1.6 is a bug fix release which fixes bugs found since the 9.1.5 release.
+</p>
+<p>
+Mesa 9.1 implements the OpenGL 3.1 API, but the version reported by
+glGetString(GL_VERSION) or glGetIntegerv(GL_MAJOR_VERSION) /
+glGetIntegerv(GL_MINOR_VERSION) depends on the particular driver being used.
+Some drivers don't support all the features required in OpenGL 3.1.  OpenGL
+3.1 is <strong>only</strong> available if requested at context creation
+because GL_ARB_compatibility is not supported.
+</p>
+
+<h2>MD5 checksums</h2>
+<pre>
+TBD
+</pre>
+
+<h2>New features</h2>
+<p>None.</p>
+
+<h2>Bug fixes</h2>
+
+<p>This list is likely incomplete.</p>
+
+<ul>
+
+<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=47824";>Bug 47824</a> - osmesa using --enable-shared-glapi depends on libgl</li>
+
+<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=62362";>Bug 62362</a> - Crash when using Wayland EGL platform</li>
+
+<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=63435";>Bug 63435</a> - [Regression since 9.0] Flickering in EGL OpenGL full-screen window with swap interval 1</li>
+
+<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=64087";>Bug 64087</a> - Webgl conformance shader-with-non-reserved-words crash when mesa is compiled without --enable-debug</li>
+
+<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=64330";>Bug 64330</a> - WebGL snake demo crash in loop_analysis.cpp:506: bool is_loop_terminator(ir_if*): assertion „inst != __null“ failed.</li>
+
+<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=65236";>Bug 65236</a> - [i965] Rendering artifacts in VDrift/GL2</li>
+
+<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=66558";>Bug 66558</a> - RS690: 3D artifacts when playing SuperTuxKart</li>
+
+<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=66847";>Bug 66847</a> - compilation broken with llvm 3.3</li>
+
+<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=66850";>Bug 66850</a> - glGenerateMipmap crashes when using GL_TEXTURE_2D_ARRAY with compressed internal format</li>
+
+<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=66921";>Bug 66921</a> - [r300g] Heroes of Newerth: HiZ related corruption</li>
+
+<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=67283";>Bug 67283</a> - VDPAU doesn't work on hybrid laptop through DRI_PRIME</li>
+
+</ul>
+
+<h2>Changes</h2>
+<p>The full set of changes can be viewed by using the following GIT command:</p>
+
+<pre>
+  git log mesa-9.1.4..mesa-9.1.5
+</pre>
+
+<p>Andreas Boll (1):</p>
+<ul>
+  <li>configure.ac: Require llvm-3.2 for r600g/radeonsi llvm backends</li>
+</ul>
+
+<p>Brian Paul (4):</p>
+<ul>
+  <li>mesa: handle 2D texture arrays in get_tex_rgba_compressed()</li>
+  <li>meta: handle 2D texture arrays in decompress_texture_image()</li>
+  <li>mesa: implement mipmap generation for compressed 2D array textures</li>
+  <li>mesa: improve free() cleanup in generate_mipmap_compressed()</li>
+</ul>
+
+<p>Carl Worth (7):</p>
+<ul>
+  <li>docs: Add 9.1.5 release md5sums</li>
+  <li>Merge 'origin/9.1' into stable</li>
+  <li>cherry-ignore: Drop 13 patches from the pick list</li>
+  <li>get-pick-list.sh: Include commits mentionining "CC: mesa-stable..." in pick list</li>
+  <li>get-pick-list: Allow for non-whitespace between "CC:" and "mesa-stable"</li>
+  <li>get-pick-list: Ignore commits which CC mesa-stable unless they say "9.1"</li>
+  <li>Bump version to 9.1.6</li>
+</ul>
+
+<p>Chris Forbes (5):</p>
+<ul>
+  <li>i965/Gen4: Zero extra coordinates for ir_tex</li>
+  <li>i965/vs: Fix flaky texture swizzling</li>
+  <li>i965/vs: set up sampler state pointer for Gen4/5.</li>
+  <li>i965/vs: Put lod parameter in the correct place for Gen4</li>
+  <li>i965/vs: Gen4/5: enable front colors if back colors are written</li>
+</ul>
+
+<p>Christoph Bumiller (1):</p>
+<ul>
+  <li>nv50,nvc0: s/uint16/uint32 for constant buffer offset</li>
+</ul>
+
+<p>Dave Airlie (1):</p>
+<ul>
+  <li>gallium/vl: add prime support</li>
+</ul>
+
+<p>Eric Anholt (1):</p>
+<ul>
+  <li>egl: Restore "bogus" DRI2 invalidate event code.</li>
+</ul>
+
+<p>Jeremy Huddleston Sequoia (1):</p>
+<ul>
+  <li>Apple: glFlush() is not needed with CGLFlushDrawable()</li>
+</ul>
+
+<p>Kenneth Graunke (1):</p>
+<ul>
+  <li>glsl: Classify "layout" like other identifiers.</li>
+</ul>
+
+<p>Kristian Høgsberg (1):</p>
+<ul>
+  <li>egl-wayland: Fix left-over wl_display_roundtrip() usage</li>
+</ul>
+
+<p>Maarten Lankhorst (2):</p>
+<ul>
+  <li>osmesa: link against static libglapi library too to get the gl exports</li>
+  <li>nvc0: force use of correct firmware file</li>
+</ul>
+
+<p>Marek Olšák (4):</p>
+<ul>
+  <li>r300g/swtcl: fix geometry corruption by uploading indices to a buffer</li>
+  <li>r300g/swtcl: fix a lockup in MSAA resolve</li>
+  <li>Revert "r300g: allow HiZ with a 16-bit zbuffer"</li>
+  <li>r600g: increase array size for shader inputs and outputs</li>
+</ul>
+
+<p>Matt Turner (2):</p>
+<ul>
+  <li>i965: NULL check prog on shader compilation failure.</li>
+  <li>i965/vs: Print error if vertex shader fails to compile.</li>
+</ul>
+
+<p>Paul Berry (1):</p>
+<ul>
+  <li>glsl: Handle empty if statement encountered during loop analysis.</li>
+</ul>
+
+</div>
+</body>
+</html>

commit 985e25402f4fb86ebd03741a0bc554e399a7b974
Author: Carl Worth <cworth@cworth.org>
Date:   Thu Aug 1 14:15:38 2013 -0700

    Bump version to 9.1.6

diff --git a/Makefile.am b/Makefile.am
index 9c03dd8..fba8556 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -36,7 +36,7 @@ check-local:
 
 # Rules for making release tarballs
 
-PACKAGE_VERSION=9.1.5
+PACKAGE_VERSION=9.1.6
 PACKAGE_DIR = Mesa-$(PACKAGE_VERSION)
 PACKAGE_NAME = MesaLib-$(PACKAGE_VERSION)
 
diff --git a/configure.ac b/configure.ac
index 452b24f..550ee05 100644
--- a/configure.ac
+++ b/configure.ac
@@ -6,7 +6,7 @@ dnl Tell the user about autoconf.html in the --help output
 m4_divert_once([HELP_END], [
 See docs/autoconf.html for more details on the options for Mesa.])
 
-AC_INIT([Mesa], [9.1.5],
+AC_INIT([Mesa], [9.1.6],
     [https://bugs.freedesktop.org/enter_bug.cgi?product=Mesa])
 AC_CONFIG_AUX_DIR([bin])
 AC_CONFIG_MACRO_DIR([m4])
diff --git a/src/mesa/main/version.h b/src/mesa/main/version.h
index a069798..6eab691 100644
--- a/src/mesa/main/version.h
+++ b/src/mesa/main/version.h
@@ -35,7 +35,7 @@ struct gl_context;
 #define MESA_MAJOR 9
 #define MESA_MINOR 1
 #define MESA_PATCH 4
-#define MESA_VERSION_STRING "9.1.5"
+#define MESA_VERSION_STRING "9.1.6"
 
 /* To make version comparison easy */
 #define MESA_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c))

commit a33ecd80749902ca72f4a42feadb509eae551e1b
Author: Carl Worth <cworth@cworth.org>
Date:   Thu Aug 1 13:34:30 2013 -0700

    get-pick-list: Ignore commits which CC mesa-stable unless they say "9.1"
    
    With the recent creation of the 9.2 branch, we're now seeing a steady flow of
    new patches to mesa-stable@ intended for that branch. To avoid wasting effort
    trying to apply these to 9.1, we now require developers to specifically
    mention "9.1" to target the 9.1 branch.

diff --git a/bin/get-pick-list.sh b/bin/get-pick-list.sh
index 0902fd0..0409341 100755
--- a/bin/get-pick-list.sh
+++ b/bin/get-pick-list.sh
@@ -14,7 +14,7 @@ git log --reverse --grep="cherry picked from commit" origin/master..HEAD |\
 	sed -e 's/^[[:space:]]*(cherry picked from commit[[:space:]]*//' -e 's/)//' > already_picked
 
 # Grep for commits that were marked as a candidate for the stable tree.
-git log --reverse --pretty=%H -i --grep='^\([[:space:]]*NOTE: .*[Cc]andidate\|CC:.*mesa-stable\)' HEAD..origin/master |\
+git log --reverse --pretty=%H -i --grep='^\([[:space:]]*NOTE: .*[Cc]andidate\|CC:.*9\.1.*mesa-stable\)' HEAD..origin/master |\
 while read sha
 do
 	# Check to see whether the patch is on the ignore list.

commit 4f26ea56120cffaa1a0c2337423cf08b835dffb8
Author: Chris Forbes <chrisf@ijw.co.nz>
Date:   Sun Jul 7 23:13:07 2013 +1200

    i965/vs: Gen4/5: enable front colors if back colors are written
    
    Fixes undefined results if a back color is written, but the
    corresponding front color is not, and only backfacing primitives are
    drawn. Results are still undefined if a frontfacing primitive is drawn,
    but that's OK.
    
    The other reasonable way to fix this would have been to just pick
    the one color slot that was populated, but that dilutes the value of
    the tests.
    
    On Gen6+, the fixed function clipper and triangle setup already take
    care of this.
    
    Fixes 11 piglits:
    spec/glsl-1.10/execution/interpolation/interpolation-none-gl_Back*Color-*
    
    NOTE: This is a candidate for stable branches.
    
    Signed-off-by: Chris Forbes <chrisf@ijw.co.nz>
    Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
    (cherry picked from commit 1ec66f2fb2fea0497efebc1db83c75ec95a816a4)

diff --git a/src/mesa/drivers/dri/i965/brw_vs.c b/src/mesa/drivers/dri/i965/brw_vs.c
index 0234ebb..950fca4 100644
--- a/src/mesa/drivers/dri/i965/brw_vs.c
+++ b/src/mesa/drivers/dri/i965/brw_vs.c
@@ -271,6 +271,14 @@ do_vs_prog(struct brw_context *brw,
 	 c.prog_data.outputs_written |= BITFIELD64_BIT(VERT_RESULT_TEX0 + i);
    }
 
+   if (intel->gen < 6) {
+      /* if back colors are written, allocate slots for front colors too */
+      if (c.prog_data.outputs_written & BITFIELD64_BIT(VERT_RESULT_BFC0))
+         c.prog_data.outputs_written |= BITFIELD64_BIT(VERT_RESULT_COL0);
+      if (c.prog_data.outputs_written & BITFIELD64_BIT(VERT_RESULT_BFC1))
+         c.prog_data.outputs_written |= BITFIELD64_BIT(VERT_RESULT_COL1);
+   }
+
    brw_compute_vue_map(brw, &c);
 
    if (0) {

commit 4cedc45a1facc86b62e1dfd1a8693042f7200e21
Author: Carl Worth <cworth@cworth.org>
Date:   Wed Jul 31 15:49:48 2013 -0700

    get-pick-list: Allow for non-whitespace between "CC:" and "mesa-stable"
    
    We recently proposed a new syntax for stable-patch nominations such as:
    
    	CC: "9.2 and 9.1" <mesa-stable@lists.freedesktop.org>
    
    and this has already appeared in the wild.
    
    So we extend the regular expression to pick this up as well.

diff --git a/bin/get-pick-list.sh b/bin/get-pick-list.sh
index b9def6b..0902fd0 100755
--- a/bin/get-pick-list.sh
+++ b/bin/get-pick-list.sh
@@ -14,7 +14,7 @@ git log --reverse --grep="cherry picked from commit" origin/master..HEAD |\
 	sed -e 's/^[[:space:]]*(cherry picked from commit[[:space:]]*//' -e 's/)//' > already_picked
 
 # Grep for commits that were marked as a candidate for the stable tree.
-git log --reverse --pretty=%H -i --grep='^\([[:space:]]*NOTE: .*[Cc]andidate\|CC:[[:space:]]*mesa-stable\)' HEAD..origin/master |\
+git log --reverse --pretty=%H -i --grep='^\([[:space:]]*NOTE: .*[Cc]andidate\|CC:.*mesa-stable\)' HEAD..origin/master |\
 while read sha
 do
 	# Check to see whether the patch is on the ignore list.

commit e6cf672b1af19fe9ef2d8462f9d5a92aa211ed65
Author: Chris Forbes <chrisf@ijw.co.nz>
Date:   Tue Jul 30 16:03:58 2013 +1200

    i965/vs: Put lod parameter in the correct place for Gen4
    
    This was never visible before due to the bogus sampler state pointer.
    Fixes remaining vertex texturing breakage on Gen4.
    
    Signed-off-by: Chris Forbes <chrisf@ijw.co.nz>
    Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
    Cc: mesa-stable@lists.freedesktop.org
    (cherry picked from commit cace82b0cdd9b93a21adbb5857f1f69ee0a2f925)

diff --git a/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp b/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
index 86f9a33..c270a67 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
@@ -2215,7 +2215,7 @@ vec4_visitor::visit(ir_texture *ir)
 	    }
 	 } else /* intel->gen == 4 */ {
 	    mrf = param_base;
-	    writemask = WRITEMASK_Z;
+	    writemask = WRITEMASK_W;
 	 }
 	 emit(MOV(dst_reg(MRF, mrf, lod_type, writemask), lod));
       } else if (ir->op == ir_txf) {

commit 185c1aa1d80dfb09361d483de0907b004564864f
Author: Chris Forbes <chrisf@ijw.co.nz>
Date:   Tue Jul 30 06:12:24 2013 +1200

    i965/vs: set up sampler state pointer for Gen4/5.
    
    Fixes broken filter and lod selection for vertex texturing.
    (txs/txf only worked properly because they ignore the sampler state
    completely)
    
    Signed-off-by: Chris Forbes <chrisf@ijw.co.nz>
    Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
    Cc: mesa-stable@lists.freedesktop.org
    (cherry picked from commit 97676032c28e20b4c4150c3632794f5bdaa9efad)
    
    Backported-by: Carl Worth <cworth@cworth.org> to compile on 9.1 branch.

diff --git a/src/mesa/drivers/dri/i965/brw_vs_state.c b/src/mesa/drivers/dri/i965/brw_vs_state.c
index a72a283..16bd56e 100644
--- a/src/mesa/drivers/dri/i965/brw_vs_state.c
+++ b/src/mesa/drivers/dri/i965/brw_vs_state.c
@@ -130,11 +130,13 @@ brw_upload_vs_unit(struct brw_context *brw)
    vs->thread4.max_threads = CLAMP(brw->urb.nr_vs_entries / 2,
 				   1, brw->max_vs_threads) - 1;
 
-   /* No samplers for ARB_vp programs:
-    */
-   /* It has to be set to 0 for Ironlake
-    */
-   vs->vs5.sampler_count = 0;
+   if (intel->gen == 5)
+      vs->vs5.sampler_count = 0; /* hardware requirement */
+   else {
+      /* CACHE_NEW_SAMPLER */
+      vs->vs5.sampler_count = (brw->sampler.count + 3) / 4;
+   }
+
 
    if (unlikely(INTEL_DEBUG & DEBUG_STATS))
       vs->thread4.stats_enable = 1;
@@ -143,6 +145,19 @@ brw_upload_vs_unit(struct brw_context *brw)
     */
    vs->vs6.vs_enable = 1;
 
+   /* Set the sampler state pointer, and its reloc
+    */
+   if (brw->sampler.count) {
+      vs->vs5.sampler_state_pointer =
+         (intel->batch.bo->offset + brw->sampler.offset) >> 5;
+      drm_intel_bo_emit_reloc(intel->batch.bo,
+                              brw->vs.state_offset +
+                              offsetof(struct brw_vs_unit_state, vs5),
+                              intel->batch.bo,
+                              brw->sampler.offset | vs->vs5.sampler_count,
+                              I915_GEM_DOMAIN_INSTRUCTION, 0);
+   }
+
    /* Emit scratch space relocation */
    if (brw->vs.prog_data->total_scratch != 0) {
       drm_intel_bo_emit_reloc(intel->batch.bo,
@@ -164,7 +179,7 @@ const struct brw_tracked_state brw_vs_unit = {
 		BRW_NEW_CURBE_OFFSETS |
 		BRW_NEW_URB_FENCE |
                 BRW_NEW_VERTEX_PROGRAM),
-      .cache = CACHE_NEW_VS_PROG
+      .cache = CACHE_NEW_VS_PROG | CACHE_NEW_SAMPLER
    },
    .emit = brw_upload_vs_unit,
 };

commit d37c09c18fa565e1898f6bde2277ecb394c44aa3
Author: Eric Anholt <eric@anholt.net>
Date:   Fri Jun 21 15:34:52 2013 -0700

    egl: Restore "bogus" DRI2 invalidate event code.
    
    I had removed it in commit 1e7776ca2bc59a6978d9b933d23852d47078dfa8
    because it was obviously wrong -- why do we care whether the server is a
    version that emits events, if we're not watching for the server's events,
    anyway?  And why would you only invalidate on a server that emits
    invalidate events, when the comment said to emit invalidates if the server
    *doesn't*?  Only, I missed that we otherwise don't flag that our buffers
    might have changed at swap time at all, so the driver was only checking
    for new buffers when triggered by the Viewport hack.  Of course you don't
    expect Viewport to be called after a swap.
    
    So, this is effectively a revert of the previous commit, except that I
    dropped the check for only emitting invalidates on a new server -- we
    *always* need to invalidate if we're doing a SwapBuffers.
    
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=63435
    Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
    Cc: "9.1 and 9.2" <mesa-stable@lists.freedesktop.org>
    (cherry picked from commit eed0a80137dfac641adfd39ce316938dbcf2be10)

diff --git a/src/egl/drivers/dri2/platform_x11.c b/src/egl/drivers/dri2/platform_x11.c
index ccb097f..ec76aec 100644
--- a/src/egl/drivers/dri2/platform_x11.c
+++ b/src/egl/drivers/dri2/platform_x11.c
@@ -743,6 +743,20 @@ dri2_swap_buffers_msc(_EGLDriver *drv, _EGLDisplay *disp, _EGLSurface *draw,
       free(reply);
    }
 
+   /* Since we aren't watching for the server's invalidate events like we're
+    * supposed to (due to XCB providing no mechanism for filtering the events
+    * the way xlib does), and SwapBuffers is a common cause of invalidate
+    * events, just shove one down to the driver, even though we haven't told
+    * the driver that we're the kind of loader that provides reliable
+    * invalidate events.  This causes the driver to request buffers again at
+    * its next draw, so that we get the correct buffers if a pageflip
+    * happened.  The driver should still be using the viewport hack to catch
+    * window resizes.
+    */
+   if (dri2_dpy->flush &&
+       dri2_dpy->flush->base.version >= 3 && dri2_dpy->flush->invalidate)
+      (*dri2_dpy->flush->invalidate)(dri2_surf->dri_drawable);
+
    return swap_count;
 }
 

commit 868087f137fac48a5e19038e8752cb24ffe1749e
Author: Brian Paul <brianp@vmware.com>
Date:   Fri Jul 26 09:50:36 2013 -0600

    mesa: improve free() cleanup in generate_mipmap_compressed()
    
    Free all our temporary buffers in one place at the end of the
    function.  Fixes memory leak detected by Coverity.
    
    Note: This is a candidate for the 9.x branches
    Cc: mesa-stable@lists.freedesktop.org
    
    Reviewed-by: José Fonseca <jfonseca@vmware.com>
    (cherry picked from commit e5f32a0b3a9f8541f0c8ffc5f303612ac9963bb1)

diff --git a/src/mesa/main/mipmap.c b/src/mesa/main/mipmap.c
index 887830c..88f5b72 100644
--- a/src/mesa/main/mipmap.c
+++ b/src/mesa/main/mipmap.c
@@ -2024,7 +2024,7 @@ generate_mipmap_compressed(struct gl_context *ctx, GLenum target,
    GLubyte *temp_src = NULL, *temp_dst = NULL;
    GLenum temp_datatype;
    GLenum temp_base_format;
-   GLubyte **temp_src_slices, **temp_dst_slices;
+   GLubyte **temp_src_slices = NULL, **temp_dst_slices = NULL;
 
    /* only two types of compressed textures at this time */
    assert(texObj->Target == GL_TEXTURE_2D ||
@@ -2063,11 +2063,8 @@ generate_mipmap_compressed(struct gl_context *ctx, GLenum target,
    temp_dst_slices = malloc(srcImage->Depth * sizeof(GLubyte *));
 
    if (!temp_src || !temp_src_slices || !temp_dst_slices) {
-      free(temp_src);
-      free(temp_src_slices);
-      free(temp_dst_slices);
       _mesa_error(ctx, GL_OUT_OF_MEMORY, "generate mipmaps");
-      return;
+      goto end;
    }
 
    /* decompress base image to the temporary src buffer */
@@ -2119,7 +2116,7 @@ generate_mipmap_compressed(struct gl_context *ctx, GLenum target,
 	 temp_dst = malloc(temp_dst_img_stride * dstDepth);
 	 if (!temp_dst) {
 	    _mesa_error(ctx, GL_OUT_OF_MEMORY, "generate mipmaps");
-	    break;
+            goto end;
 	 }
       }
 
@@ -2127,8 +2124,7 @@ generate_mipmap_compressed(struct gl_context *ctx, GLenum target,
       dstImage = _mesa_get_tex_image(ctx, texObj, target, level + 1);
       if (!dstImage) {
          _mesa_error(ctx, GL_OUT_OF_MEMORY, "generating mipmaps");
-         free(temp_dst);
-         return;
+         goto end;
       }
 
       /* for 2D arrays, setup array[depth] of slice pointers */
@@ -2153,8 +2149,8 @@ generate_mipmap_compressed(struct gl_context *ctx, GLenum target,
                                       dstWidth, dstHeight, dstDepth,
                                       border, srcImage->InternalFormat,
                                       srcImage->TexFormat)) {
-         free(temp_dst);
-         return;
+         /* all done */
+         goto end;
       }
 
       /* The image space was allocated above so use glTexSubImage now */
@@ -2173,6 +2169,7 @@ generate_mipmap_compressed(struct gl_context *ctx, GLenum target,
       }
    } /* loop over mipmap levels */
 
+end:
    free(temp_src);
    free(temp_dst);
    free(temp_src_slices);

commit d2700c1a05cebdd3aa47b3350b33860a3c10d215
Author: Carl Worth <cworth@cworth.org>
Date:   Tue Jul 30 12:36:37 2013 -0700

    get-pick-list.sh: Include commits mentionining "CC: mesa-stable..." in pick list
    
    We recently adopted a new convention that patches can be nominated for the
    stable branch by including a line in the commit message as follows:
    
    	CC: mesa-stable@lists.freedesktop.org
    
    This is a convenient syntax as "git send-email" will notice this line and
    automatically copy the resulting patch email to the mesa-stable mailing list.
    
    Here we extend the regular expression in the get-pick-list.sh script to also
    notice this pattern, (as well as the traditional "NOTE: This patch is a
    candidate..." form.

diff --git a/bin/get-pick-list.sh b/bin/get-pick-list.sh
index d2b76e7..b9def6b 100755
--- a/bin/get-pick-list.sh
+++ b/bin/get-pick-list.sh
@@ -14,7 +14,7 @@ git log --reverse --grep="cherry picked from commit" origin/master..HEAD |\
 	sed -e 's/^[[:space:]]*(cherry picked from commit[[:space:]]*//' -e 's/)//' > already_picked
 
 # Grep for commits that were marked as a candidate for the stable tree.
-git log --reverse --pretty=%H -i --grep='^[[:space:]]*NOTE: .*[Cc]andidate' HEAD..origin/master |\
+git log --reverse --pretty=%H -i --grep='^\([[:space:]]*NOTE: .*[Cc]andidate\|CC:[[:space:]]*mesa-stable\)' HEAD..origin/master |\
 while read sha
 do
 	# Check to see whether the patch is on the ignore list.

commit 30fc154945c0e6f78b3bc91a697577a985b84b1c
Author: Carl Worth <cworth@cworth.org>
Date:   Tue Jul 30 12:35:00 2013 -0700

    cherry-ignore: Drop 13 patches from the pick list
    
    Each of these have recently been discussed with the original patch authors
    (see posts to the mesa-stable@lists.freedesktop.org mailing list).

diff --git a/bin/.cherry-ignore b/bin/.cherry-ignore
index 15a8e95..be95f17 100644
--- a/bin/.cherry-ignore
+++ b/bin/.cherry-ignore
@@ -39,3 +39,28 @@ fcaa48d9cc8937e0ceb59dfd22ef5b6e6fd1a273 glsl: Disallow return with a void argum
 
 # Rejected at author's request (attempted backport did not fix piglit test)
 4c3ed795662974a1c2ad2326fc74bef608a34f31 r600g: Workaround for a harware bug with nested loops on Cayman
+
+# These do not apply and the author has confirmed they should be dropped.
+49c1fc7044eaaa5c2dca05ff4a709be8e3636871 r600g: don't emit SQ_DYN_GPR_RESOURCE_LIMIT_1 on cayman
+4539f8e20af286d1f521eb016c89c6d9af0b801c r600g: don't emit surface_sync after FLUSH_AND_INV_EVENT
+
+# Backported as commit ca2df146429fba22ea8df3e8f9b76d84d391cf5f
+da33f9b919039442e9ab51f9b1d1c83a73607133 r600g: increase array size for shader inputs and outputs
+
+# Has potential to break previously-working (though technically incorrect) programs
+17856726c94000bf16156f7f9acea77a271a6005 glsl: Disallow auxiliary storage qualifiers on FS outputs.
+
+# Doesn't cherry-pick cleanly, and doesn't change the implementation (just cleans up compiler warning spam)
+803f755edeabd1b0af3d8f4ebf2005333e152ad4 glsl: Less const for glsl_type convenience accessors
+
+# Not needed for 9.1 (restores code never deleted from this branch)
+0e9549e2bd57168086421468cbf1db0821c36730 Revert "i965: Delete pre-DRI2.3 viewport hacks."
+
+# These are all intended for 9.2, not 9.1
+4e90bc9a12bea93c6b5522abe8151a8cfe1d6d1d gallium: Add PIPE_CAP_ENDIANNESS
+8c9d3c62f60a2819948bdfb005600cdc10aa2547 clover: Return correct value for CL_DEVICE_ENDIAN_LITTLE
+a3dcab43c6b6fed2f35aa0e802be6398985f100c clover: Pass corresponding module::argument to kernel::argument::bind().
+2265b40e377cc2c9d1091498df2aede5df2ff684 clover: Add kernel argument fields to allow differing host/target data types.
+829caf410e2c2c6f79902199da5a7900abc16129 clover: Byte-swap kernel arguments when host and device endianness differ.
+f64c0ca692d3e8c78dd9ae1f015f58f1dfc1c760 clover: Extend kernel arguments for differing host and device data types.
+df530829f757a8968389427eb26f45a0d46623fa clover: Respect kernel argument alignment restrictions.

commit 9688066bcaee041ea148e7dd60fba36012e00539
Author: Kenneth Graunke <kenneth@whitecape.org>
Date:   Fri Jul 26 12:31:06 2013 -0700

    glsl: Classify "layout" like other identifiers.
    
    When "layout" isn't being lexed as LAYOUT_TOK, we should treat it like
    an ordinary identifier.  This means we need to classify it to determine
    whether we should return IDENTIFIER, TYPE_IDENTIFIER, or NEW_IDENTIFIER.
    
    Fixes the WebGL conformance test "shader-with-non-reserved-words."
    
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=64087
    Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
    Reviewed-by: Matt Turner <mattst88@gmail.com>
    Cc: mesa-stable@lists.freedesktop.org
    (cherry picked from commit c178ec0d7e8cc7007cb34e4f56f14261a057c200)

diff --git a/src/glsl/glsl_lexer.ll b/src/glsl/glsl_lexer.ll
index ddc9f80..f6aee4a 100644
--- a/src/glsl/glsl_lexer.ll
+++ b/src/glsl/glsl_lexer.ll
@@ -361,7 +361,7 @@ layout		{
 		      return LAYOUT_TOK;
 		   } else {
 		      yylval->identifier = strdup(yytext);
-		      return IDENTIFIER;
+		      return classify_identifier(yyextra, yytext);
 		   }
 		}
 

commit f437513bed58749b812f1f773631eca3c70ec673
Author: Chris Forbes <chrisf@ijw.co.nz>
Date:   Wed Jul 24 07:21:22 2013 +1200

    i965/vs: Fix flaky texture swizzling
    
    If any component used the ZERO or ONE swizzle, its corresponding member
    in the `swizzle` array would never be initialized. We *mostly* got away
    with this, except when that memory happened to contain a value that
    clobbered another channel when combined using BRW_SWIZZLE4().
    
    NOTE: This is a candidate for stable branches.
    
    Signed-off-by: Chris Forbes <chrisf@ijw.co.nz>
    Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
    Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
    (cherry picked from commit 124f567f1d575eaea98a6ae1d0a4687b8fb5bba2)

diff --git a/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp b/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
index a0b5c8c..86f9a33 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
@@ -2285,7 +2285,7 @@ vec4_visitor::swizzle_result(ir_texture *ir, src_reg orig_val, int sampler)
    }
 
    int zero_mask = 0, one_mask = 0, copy_mask = 0;
-   int swizzle[4];
+   int swizzle[4] = {0};
 
    for (int i = 0; i < 4; i++) {
       switch (GET_SWZ(s, i)) {

commit 6b6f29eb202c1e2f1a1b4fc3c4ac2456314842f1
Author: Dave Airlie <airlied@redhat.com>
Date:   Thu Jul 25 13:31:26 2013 +1000

    gallium/vl: add prime support
    
    This fixes the dri2 opening to check if DRI_PRIME is set,
    and picks the correct drm device path to open, this along
    with a change to libvdpau allows vdpauinfo to work at least,
    
    Martin Peres tested with nouveau, and there seems to be a
    further issue with final displaying, it only works sometimes,
    but this patch is at least necessary to help debug further.
    
    Signed-off-by: Dave Airlie <airlied@redhat.com>
    Cc: mesa-stable@lists.freedesktop.org
    Reviewed-by: Christian König <christian.koenig@amd.com>
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=67283
    Tested-by: Armin K. <krejzi@email.com>
    (cherry picked from commit 19338157c97becac1e61cc51dc0904ddfab8e9da)

diff --git a/src/gallium/auxiliary/vl/vl_winsys_dri.c b/src/gallium/auxiliary/vl/vl_winsys_dri.c
index 560c914..91d52e4 100644
--- a/src/gallium/auxiliary/vl/vl_winsys_dri.c
+++ b/src/gallium/auxiliary/vl/vl_winsys_dri.c
@@ -32,8 +32,10 @@
 #include <fcntl.h>
 
 #include <X11/Xlib-xcb.h>
+#include <X11/extensions/dri2tokens.h>
 #include <xcb/dri2.h>
 #include <xf86drm.h>
+#include <errno.h>
 
 #include "pipe/p_screen.h"
 #include "pipe/p_context.h"
@@ -305,6 +307,7 @@ vl_screen_create(Display *display, int screen)
    xcb_generic_error_t *error = NULL;
    char *device_name;
    int fd, device_name_length;
+   unsigned int driverType;
 
    drm_magic_t magic;
 
@@ -332,7 +335,22 @@ vl_screen_create(Display *display, int screen)
    s = xcb_setup_roots_iterator(xcb_get_setup(scrn->conn));
    while (screen--)
 	xcb_screen_next(&s);
-   connect_cookie = xcb_dri2_connect_unchecked(scrn->conn, s.data->root, XCB_DRI2_DRIVER_TYPE_DRI);
+   driverType = XCB_DRI2_DRIVER_TYPE_DRI;
+#ifdef DRI2DriverPrimeShift
+   {
+      char *prime = getenv("DRI_PRIME");
+      if (prime) {
+         unsigned int primeid;
+         errno = 0;
+         primeid = strtoul(prime, NULL, 0);
+         if (errno == 0)
+            driverType |=
+               ((primeid & DRI2DriverPrimeMask) << DRI2DriverPrimeShift);
+      }
+   }
+#endif
+
+   connect_cookie = xcb_dri2_connect_unchecked(scrn->conn, s.data->root, driverType);
    connect = xcb_dri2_connect_reply(scrn->conn, connect_cookie, NULL);
    if (connect == NULL || connect->driver_name_length + connect->device_name_length == 0)
       goto free_screen;

commit 0f05066feab2863ff5b4570c8be129a8955996ee
Author: Paul Berry <stereotype441@gmail.com>
Date:   Wed Jul 24 08:04:44 2013 -0700

    glsl: Handle empty if statement encountered during loop analysis.
    
    The is_loop_terminator() function was asserting that the following
    kind of if statement could never occur:
    
        if (...) { } else { }
    
    (presumably based on the assumption that such an if statement would be
    eliminated by previous optimization stages).  But that isn't the
    case--it's possible that previous optimization stages might simplify
    more complex code down to this empty if statement, in which case it
    won't be eliminated until the next time through the optimization loop.
    
    So is_loop_terminator() needs to handle it.  Fortunately it's easy to
    handle--it's not a loop terminator because it does nothing.
    
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=64330
    CC: mesa-stable@lists.freedesktop.org
    
    Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
    (cherry picked from commit a5eecb246d66fd8f27eca3c4f6f83bf2641b9403)

diff --git a/src/glsl/loop_analysis.cpp b/src/glsl/loop_analysis.cpp
index 6a0e4da..fae5768 100644
--- a/src/glsl/loop_analysis.cpp
+++ b/src/glsl/loop_analysis.cpp
@@ -505,7 +505,8 @@ is_loop_terminator(ir_if *ir)
 
    ir_instruction *const inst =
       (ir_instruction *) ir->then_instructions.get_head();
-   assert(inst != NULL);
+   if (inst == NULL)
+      return false;
 
    if (inst->ir_type != ir_type_loop_jump)
       return false;

commit aa4938f0467761732e6b775137178a3a0976db54
Author: Brian Paul <brianp@vmware.com>
Date:   Tue Jul 16 06:04:32 2013 -0600

    mesa: implement mipmap generation for compressed 2D array textures
    
    We weren't looping over all the slices in the array.  The updated
    code should also correctly handle 3D compressed textures too, whenever
    we have that feature.
    
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=66850
    
    NOTE: This is a candidate for the 9.x branches
    Cc: mesa-stable@lists.freedesktop.org
    Reviewed-by: José Fonseca <jfonseca@vmware.com>
    (cherry picked from commit 8a9df7a370b66ec50b6255e4d66ac1ed331319fb)

diff --git a/src/mesa/main/mipmap.c b/src/mesa/main/mipmap.c
index a2f3767..887830c 100644
--- a/src/mesa/main/mipmap.c
+++ b/src/mesa/main/mipmap.c
@@ -2020,13 +2020,15 @@ generate_mipmap_compressed(struct gl_context *ctx, GLenum target,
    GLint level;
    gl_format temp_format;
    GLint components;
-   GLuint temp_src_stride; /* in bytes */
+   GLuint temp_src_row_stride, temp_src_img_stride; /* in bytes */
    GLubyte *temp_src = NULL, *temp_dst = NULL;
    GLenum temp_datatype;
    GLenum temp_base_format;
+   GLubyte **temp_src_slices, **temp_dst_slices;
 
    /* only two types of compressed textures at this time */
    assert(texObj->Target == GL_TEXTURE_2D ||
+	  texObj->Target == GL_TEXTURE_2D_ARRAY ||
 	  texObj->Target == GL_TEXTURE_CUBE_MAP_ARB);
 
    /*
@@ -2051,15 +2053,24 @@ generate_mipmap_compressed(struct gl_context *ctx, GLenum target,
 
 
    /* allocate storage for the temporary, uncompressed image */
-   /* 20 extra bytes, just be safe when calling last FetchTexel */
-   temp_src_stride = _mesa_format_row_stride(temp_format, srcImage->Width);
-   temp_src = malloc(temp_src_stride * srcImage->Height + 20);
-   if (!temp_src) {
+   temp_src_row_stride = _mesa_format_row_stride(temp_format, srcImage->Width);
+   temp_src_img_stride = _mesa_format_image_size(temp_format, srcImage->Width,
+                                                 srcImage->Height, 1);
+   temp_src = malloc(temp_src_img_stride * srcImage->Depth);
+
+   /* Allocate storage for arrays of slice pointers */
+   temp_src_slices = malloc(srcImage->Depth * sizeof(GLubyte *));
+   temp_dst_slices = malloc(srcImage->Depth * sizeof(GLubyte *));
+
+   if (!temp_src || !temp_src_slices || !temp_dst_slices) {
+      free(temp_src);
+      free(temp_src_slices);
+      free(temp_dst_slices);
       _mesa_error(ctx, GL_OUT_OF_MEMORY, "generate mipmaps");
       return;
    }
 
-   /* decompress base image to the temporary */
+   /* decompress base image to the temporary src buffer */
    {
       /* save pixel packing mode */
       struct gl_pixelstore_attrib save = ctx->Pack;
@@ -2075,7 +2086,6 @@ generate_mipmap_compressed(struct gl_context *ctx, GLenum target,
       ctx->Pack = save;
    }
 
-
    for (level = texObj->BaseLevel; level < maxLevel; level++) {
       /* generate image[level+1] from image[level] */
       const struct gl_texture_image *srcImage;
@@ -2084,7 +2094,8 @@ generate_mipmap_compressed(struct gl_context *ctx, GLenum target,
       GLint dstWidth, dstHeight, dstDepth;
       GLint border;
       GLboolean nextLevel;
-      GLuint temp_dst_stride; /* in bytes */
+      GLuint temp_dst_row_stride, temp_dst_img_stride; /* in bytes */
+      GLuint i;
 
       /* get src image parameters */
       srcImage = _mesa_select_tex_image(ctx, texObj, target, level);
@@ -2100,9 +2111,12 @@ generate_mipmap_compressed(struct gl_context *ctx, GLenum target,
       if (!nextLevel)
 	 break;
 
-      temp_dst_stride = _mesa_format_row_stride(temp_format, dstWidth);
+      /* Compute dst image strides and alloc memory on first iteration */
+      temp_dst_row_stride = _mesa_format_row_stride(temp_format, dstWidth);
+      temp_dst_img_stride = _mesa_format_image_size(temp_format, dstWidth,
+                                                    dstHeight, 1);


Reply to: