Here is a diff that updates Mesa to 9.2.3 a bug fix release. Release notes can be found at http://www.mesa3d.org/relnotes/9.2.3.html
Index: dist/Mesa/Android.common.mk =================================================================== RCS file: /cvs/xenocara/dist/Mesa/Android.common.mk,v retrieving revision 1.1.1.3 diff -u -p -r1.1.1.3 Android.common.mk --- dist/Mesa/Android.common.mk 9 Nov 2013 02:25:51 -0000 1.1.1.3 +++ dist/Mesa/Android.common.mk 18 Nov 2013 00:49:24 -0000 @@ -35,7 +35,7 @@ LOCAL_C_INCLUDES += \ # define ANDROID_VERSION (e.g., 4.0.x => 0x0400) LOCAL_CFLAGS += \ - -DPACKAGE_VERSION=\"9.2.2\" \ + -DPACKAGE_VERSION=\"9.2.3\" \ -DPACKAGE_BUGREPORT=\"https://bugs.freedesktop.org/enter_bug.cgi?product=Mesa\" \ -DANDROID_VERSION=0x0$(MESA_ANDROID_MAJOR_VERSION)0$(MESA_ANDROID_MINOR_VERSION) Index: dist/Mesa/SConstruct =================================================================== RCS file: /cvs/xenocara/dist/Mesa/SConstruct,v retrieving revision 1.6 diff -u -p -r1.6 SConstruct --- dist/Mesa/SConstruct 9 Nov 2013 02:46:54 -0000 1.6 +++ dist/Mesa/SConstruct 18 Nov 2013 00:49:24 -0000 @@ -70,7 +70,7 @@ if env['gles']: # Environment setup env.Append(CPPDEFINES = [ - ('PACKAGE_VERSION', '\\"9.2.2\\"'), + ('PACKAGE_VERSION', '\\"9.2.3\\"'), ('PACKAGE_BUGREPORT', '\\"https://bugs.freedesktop.org/enter_bug.cgi?product=Mesa\\"'), ]) Index: dist/Mesa/configure.ac =================================================================== RCS file: /cvs/xenocara/dist/Mesa/configure.ac,v retrieving revision 1.9 diff -u -p -r1.9 configure.ac --- dist/Mesa/configure.ac 9 Nov 2013 02:46:54 -0000 1.9 +++ dist/Mesa/configure.ac 18 Nov 2013 00:49:28 -0000 @@ -6,7 +6,7 @@ dnl Tell the user about autoconf.html in m4_divert_once([HELP_END], [ See docs/autoconf.html for more details on the options for Mesa.]) -AC_INIT([Mesa], [9.2.2], +AC_INIT([Mesa], [9.2.3], [https://bugs.freedesktop.org/enter_bug.cgi?product=Mesa]) AC_CONFIG_AUX_DIR([bin]) AC_CONFIG_MACRO_DIR([m4]) Index: dist/Mesa/bin/get-pick-list.sh =================================================================== RCS file: /cvs/xenocara/dist/Mesa/bin/get-pick-list.sh,v retrieving revision 1.1.1.1 diff -u -p -r1.1.1.1 get-pick-list.sh --- dist/Mesa/bin/get-pick-list.sh 5 Sep 2013 13:09:11 -0000 1.1.1.1 +++ dist/Mesa/bin/get-pick-list.sh 18 Nov 2013 00:49:28 -0000 @@ -14,7 +14,7 @@ git log --reverse --grep="cherry picked 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.*9\.2\|CC:.*9\.2.*mesa-stable\)' HEAD..origin/master |\ while read sha do # Check to see whether the patch is on the ignore list. Index: dist/Mesa/docs/relnotes/9.2.2.html =================================================================== RCS file: /cvs/xenocara/dist/Mesa/docs/relnotes/9.2.2.html,v retrieving revision 1.1.1.1 diff -u -p -r1.1.1.1 9.2.2.html --- dist/Mesa/docs/relnotes/9.2.2.html 9 Nov 2013 02:37:06 -0000 1.1.1.1 +++ dist/Mesa/docs/relnotes/9.2.2.html 18 Nov 2013 00:49:28 -0000 @@ -31,6 +31,9 @@ because GL_ARB_compatibility is not supp <h2>MD5 checksums</h2> <pre> +df801a975045150790e10e2ccf32193f MesaLib-9.2.2.tar.gz +20887f8020db7d1736a01ae9cd5d8c38 MesaLib-9.2.2.tar.bz2 +1676f4f1b157c838d077dadd31ba6c84 MesaLib-9.2.2.zip </pre> Index: dist/Mesa/include/c99/stdbool.h =================================================================== RCS file: /cvs/xenocara/dist/Mesa/include/c99/stdbool.h,v retrieving revision 1.1 diff -u -p -r1.1 stdbool.h --- dist/Mesa/include/c99/stdbool.h 22 May 2010 20:05:54 -0000 1.1 +++ dist/Mesa/include/c99/stdbool.h 18 Nov 2013 00:49:28 -0000 @@ -35,7 +35,8 @@ #define bool _Bool /* For compilers that don't have the builtin _Bool type. */ -#if defined(_MSC_VER) || (__STDC_VERSION__ < 199901L && __GNUC__ < 3) +#if (defined(_MSC_VER) && _MSC_VER < 1800) || \ + (defined __GNUC__&& __STDC_VERSION__ < 199901L && __GNUC__ < 3) typedef unsigned char _Bool; #endif Index: dist/Mesa/src/egl/drivers/dri2/egl_dri2.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/egl/drivers/dri2/egl_dri2.c,v retrieving revision 1.4 diff -u -p -r1.4 egl_dri2.c --- dist/Mesa/src/egl/drivers/dri2/egl_dri2.c 5 Sep 2013 13:59:22 -0000 1.4 +++ dist/Mesa/src/egl/drivers/dri2/egl_dri2.c 18 Nov 2013 00:49:28 -0000 @@ -1203,7 +1203,7 @@ dri2_create_image_wayland_wl_buffer(_EGL EGLint err; int32_t plane; - if (!wayland_buffer_is_drm(&buffer->buffer)) + if (!wayland_buffer_is_drm(dri2_dpy->wl_server_drm, &buffer->buffer)) return NULL; err = _eglParseImageAttribList(&attrs, disp, attr_list); @@ -1585,6 +1585,11 @@ dri2_bind_wayland_display_wl(_EGLDriver if (!dri2_dpy->wl_server_drm) return EGL_FALSE; +#ifdef HAVE_DRM_PLATFORM + if (dri2_dpy->gbm_dri) + dri2_dpy->gbm_dri->wl_drm = dri2_dpy->wl_server_drm; +#endif + return EGL_TRUE; } @@ -1611,9 +1616,10 @@ dri2_query_wayland_buffer_wl(_EGLDriver EGLint attribute, EGLint *value) { struct wl_drm_buffer *buffer = (struct wl_drm_buffer *) _buffer; + struct dri2_egl_display *dri2_dpy = dri2_egl_display(disp); const struct wl_drm_components_descriptor *format; - if (!wayland_buffer_is_drm(&buffer->buffer)) + if (!wayland_buffer_is_drm(dri2_dpy->wl_server_drm, &buffer->buffer)) return EGL_FALSE; format = buffer->driver_format; Index: dist/Mesa/src/egl/wayland/wayland-drm/wayland-drm.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/egl/wayland/wayland-drm/wayland-drm.c,v retrieving revision 1.2 diff -u -p -r1.2 wayland-drm.c --- dist/Mesa/src/egl/wayland/wayland-drm/wayland-drm.c 5 Sep 2013 13:59:26 -0000 1.2 +++ dist/Mesa/src/egl/wayland/wayland-drm/wayland-drm.c 18 Nov 2013 00:49:28 -0000 @@ -45,6 +45,7 @@ struct wl_drm { uint32_t flags; struct wayland_drm_callbacks *callbacks; + struct wl_buffer_interface buffer_interface; }; static void @@ -63,10 +64,6 @@ buffer_destroy(struct wl_client *client, wl_resource_destroy(resource); } -const static struct wl_buffer_interface drm_buffer_interface = { - buffer_destroy -}; - static void create_buffer(struct wl_client *client, struct wl_resource *resource, uint32_t id, uint32_t name, int fd, @@ -107,7 +104,7 @@ create_buffer(struct wl_client *client, buffer->buffer.resource.object.id = id; buffer->buffer.resource.object.interface = &wl_buffer_interface; buffer->buffer.resource.object.implementation = - (void (**)(void)) &drm_buffer_interface; + (void (**)(void)) &drm->buffer_interface; buffer->buffer.resource.data = buffer; buffer->buffer.resource.destroy = destroy_buffer; @@ -246,6 +243,7 @@ wayland_drm_init(struct wl_display *disp drm->callbacks = callbacks; drm->user_data = user_data; drm->flags = flags; + drm->buffer_interface.destroy = buffer_destroy; wl_display_add_global(display, &wl_drm_interface, drm, bind_drm); @@ -263,10 +261,10 @@ wayland_drm_uninit(struct wl_drm *drm) } int -wayland_buffer_is_drm(struct wl_buffer *buffer) +wayland_buffer_is_drm(struct wl_drm *drm, struct wl_buffer *buffer) { return buffer->resource.object.implementation == - (void (**)(void)) &drm_buffer_interface; + (void (**)(void)) &drm->buffer_interface; } uint32_t Index: dist/Mesa/src/egl/wayland/wayland-drm/wayland-drm.h =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/egl/wayland/wayland-drm/wayland-drm.h,v retrieving revision 1.2 diff -u -p -r1.2 wayland-drm.h --- dist/Mesa/src/egl/wayland/wayland-drm/wayland-drm.h 5 Sep 2013 13:59:26 -0000 1.2 +++ dist/Mesa/src/egl/wayland/wayland-drm/wayland-drm.h 18 Nov 2013 00:49:28 -0000 @@ -99,7 +99,7 @@ void wayland_drm_uninit(struct wl_drm *drm); int -wayland_buffer_is_drm(struct wl_buffer *buffer); +wayland_buffer_is_drm(struct wl_drm *drm, struct wl_buffer *buffer); uint32_t wayland_drm_buffer_get_format(struct wl_buffer *buffer_base); Index: dist/Mesa/src/gallium/drivers/radeonsi/r600_blit.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/gallium/drivers/radeonsi/r600_blit.c,v retrieving revision 1.1.1.1 diff -u -p -r1.1.1.1 r600_blit.c --- dist/Mesa/src/gallium/drivers/radeonsi/r600_blit.c 5 Sep 2013 13:12:37 -0000 1.1.1.1 +++ dist/Mesa/src/gallium/drivers/radeonsi/r600_blit.c 18 Nov 2013 00:49:28 -0000 @@ -322,6 +322,21 @@ static void r600_compressed_to_blittable rtex->surface.level[0].npix_y = util_format_get_nblocksy(orig->format, orig->npix0_y); rtex->surface.level[level].npix_x = util_format_get_nblocksx(orig->format, orig->npix_x); rtex->surface.level[level].npix_y = util_format_get_nblocksy(orig->format, orig->npix_y); + + /* By dividing the dimensions by 4, we effectively decrement + * last_level by 2, therefore the last 2 mipmap levels disappear and + * aren't blittable. Note that the last 3 mipmap levels (4x4, 2x2, + * 1x1) have equal slice sizes, which is an important assumption + * for this to work. + * + * In order to make the last 2 mipmap levels blittable, we have to + * add the slice size of the last mipmap level to the texture + * address, so that even though the hw thinks it reads last_level-2, + * it will actually read last_level-1, and if we add the slice size*2, + * it will read last_level. That's how this workaround works. + */ + if (level > rtex->resource.b.b.last_level-2) + rtex->mipmap_shift = level - (rtex->resource.b.b.last_level-2); } static void r600_change_format(struct pipe_resource *tex, @@ -355,6 +370,7 @@ static void r600_reset_blittable_to_orig rtex->surface.level[0].npix_y = orig->npix0_y; rtex->surface.level[level].npix_x = orig->npix_x; rtex->surface.level[level].npix_y = orig->npix_y; + rtex->mipmap_shift = 0; } static void r600_resource_copy_region(struct pipe_context *ctx, Index: dist/Mesa/src/gallium/drivers/radeonsi/r600_resource.h =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/gallium/drivers/radeonsi/r600_resource.h,v retrieving revision 1.1.1.1 diff -u -p -r1.1.1.1 r600_resource.h --- dist/Mesa/src/gallium/drivers/radeonsi/r600_resource.h 5 Sep 2013 13:12:38 -0000 1.1.1.1 +++ dist/Mesa/src/gallium/drivers/radeonsi/r600_resource.h 18 Nov 2013 00:49:28 -0000 @@ -53,6 +53,8 @@ struct r600_resource_texture { struct r600_resource_texture *flushed_depth_texture; boolean is_flushing_texture; struct radeon_surface surface; + + unsigned mipmap_shift; }; struct r600_surface { Index: dist/Mesa/src/gallium/drivers/radeonsi/si_state.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/gallium/drivers/radeonsi/si_state.c,v retrieving revision 1.1.1.1 diff -u -p -r1.1.1.1 si_state.c --- dist/Mesa/src/gallium/drivers/radeonsi/si_state.c 5 Sep 2013 13:12:41 -0000 1.1.1.1 +++ dist/Mesa/src/gallium/drivers/radeonsi/si_state.c 18 Nov 2013 00:49:28 -0000 @@ -2394,6 +2394,7 @@ static struct pipe_sampler_view *si_crea va = r600_resource_va(ctx->screen, texture); va += surflevel[0].offset; + va += tmp->mipmap_shift * surflevel[texture->last_level].slice_size; view->state[0] = va >> 8; view->state[1] = (S_008F14_BASE_ADDRESS_HI(va >> 40) | S_008F14_DATA_FORMAT(format) | @@ -2404,8 +2405,8 @@ static struct pipe_sampler_view *si_crea S_008F1C_DST_SEL_Y(si_map_swizzle(swizzle[1])) | S_008F1C_DST_SEL_Z(si_map_swizzle(swizzle[2])) | S_008F1C_DST_SEL_W(si_map_swizzle(swizzle[3])) | - S_008F1C_BASE_LEVEL(state->u.tex.first_level) | - S_008F1C_LAST_LEVEL(state->u.tex.last_level) | + S_008F1C_BASE_LEVEL(state->u.tex.first_level - tmp->mipmap_shift) | + S_008F1C_LAST_LEVEL(state->u.tex.last_level - tmp->mipmap_shift) | S_008F1C_TILING_INDEX(si_tile_mode_index(tmp, 0, false)) | S_008F1C_POW2_PAD(texture->last_level > 0) | S_008F1C_TYPE(si_tex_dim(texture->target))); Index: dist/Mesa/src/gallium/state_trackers/egl/common/native.h =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/gallium/state_trackers/egl/common/native.h,v retrieving revision 1.4 diff -u -p -r1.4 native.h --- dist/Mesa/src/gallium/state_trackers/egl/common/native.h 5 Sep 2013 14:01:45 -0000 1.4 +++ dist/Mesa/src/gallium/state_trackers/egl/common/native.h 18 Nov 2013 00:49:28 -0000 @@ -246,6 +246,10 @@ struct native_display { const struct native_display_buffer *buffer; const struct native_display_modeset *modeset; const struct native_display_wayland_bufmgr *wayland_bufmgr; + +#ifdef HAVE_WAYLAND_BACKEND + struct wl_drm *wl_server_drm; /* for EGL_WL_bind_wayland_display */ +#endif }; /** Index: dist/Mesa/src/gallium/state_trackers/egl/common/native_wayland_drm_bufmgr_helper.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/gallium/state_trackers/egl/common/native_wayland_drm_bufmgr_helper.c,v retrieving revision 1.2 diff -u -p -r1.2 native_wayland_drm_bufmgr_helper.c --- dist/Mesa/src/gallium/state_trackers/egl/common/native_wayland_drm_bufmgr_helper.c 5 Sep 2013 14:01:46 -0000 1.2 +++ dist/Mesa/src/gallium/state_trackers/egl/common/native_wayland_drm_bufmgr_helper.c 18 Nov 2013 00:49:28 -0000 @@ -77,7 +77,7 @@ egl_g3d_wl_drm_common_query_buffer(struc struct wl_drm_buffer *buffer = (struct wl_drm_buffer *) _buffer; struct pipe_resource *resource = buffer->driver_buffer; - if (!wayland_buffer_is_drm(&buffer->buffer)) + if (!wayland_buffer_is_drm(ndpy->wl_server_drm, &buffer->buffer)) return EGL_FALSE; switch (attribute) { Index: dist/Mesa/src/gallium/state_trackers/egl/drm/native_drm.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/gallium/state_trackers/egl/drm/native_drm.c,v retrieving revision 1.3 diff -u -p -r1.3 native_drm.c --- dist/Mesa/src/gallium/state_trackers/egl/drm/native_drm.c 5 Sep 2013 14:01:46 -0000 1.3 +++ dist/Mesa/src/gallium/state_trackers/egl/drm/native_drm.c 18 Nov 2013 00:49:28 -0000 @@ -39,6 +39,10 @@ #include <libudev.h> #endif +#ifdef HAVE_WAYLAND_BACKEND +#include "common/native_wayland_drm_bufmgr_helper.h" +#endif + static boolean drm_display_is_format_supported(struct native_display *ndpy, enum pipe_format fmt, boolean is_color) @@ -207,14 +211,14 @@ drm_display_bind_wayland_display(struct { struct drm_display *drmdpy = drm_display(ndpy); - if (drmdpy->wl_server_drm) + if (ndpy->wl_server_drm) return FALSE; - drmdpy->wl_server_drm = wayland_drm_init(wl_dpy, + ndpy->wl_server_drm = wayland_drm_init(wl_dpy, drmdpy->device_name, &wl_drm_callbacks, ndpy, 0); - if (!drmdpy->wl_server_drm) + if (!ndpy->wl_server_drm) return FALSE; return TRUE; @@ -224,13 +228,11 @@ static boolean drm_display_unbind_wayland_display(struct native_display *ndpy, struct wl_display *wl_dpy) { - struct drm_display *drmdpy = drm_display(ndpy); - - if (!drmdpy->wl_server_drm) + if (!ndpy->wl_server_drm) return FALSE; - wayland_drm_uninit(drmdpy->wl_server_drm); - drmdpy->wl_server_drm = NULL; + wayland_drm_uninit(ndpy->wl_server_drm); + ndpy->wl_server_drm = NULL; return TRUE; } Index: dist/Mesa/src/gallium/state_trackers/egl/drm/native_drm.h =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/gallium/state_trackers/egl/drm/native_drm.h,v retrieving revision 1.3 diff -u -p -r1.3 native_drm.h --- dist/Mesa/src/gallium/state_trackers/egl/drm/native_drm.h 5 Sep 2013 14:01:46 -0000 1.3 +++ dist/Mesa/src/gallium/state_trackers/egl/drm/native_drm.h 18 Nov 2013 00:49:28 -0000 @@ -36,10 +36,6 @@ #include "common/native.h" #include "common/native_helper.h" -#ifdef HAVE_WAYLAND_BACKEND -#include "common/native_wayland_drm_bufmgr_helper.h" -#endif - #include "gbm_gallium_drmint.h" struct drm_config; @@ -67,10 +63,6 @@ struct drm_display { struct drm_surface **shown_surfaces; /* save the original settings of the CRTCs */ struct drm_crtc *saved_crtcs; - -#ifdef HAVE_WAYLAND_BACKEND - struct wl_drm *wl_server_drm; /* for EGL_WL_bind_wayland_display */ -#endif }; struct drm_config { Index: dist/Mesa/src/gallium/state_trackers/egl/wayland/native_drm.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/gallium/state_trackers/egl/wayland/native_drm.c,v retrieving revision 1.2 diff -u -p -r1.2 native_drm.c --- dist/Mesa/src/gallium/state_trackers/egl/wayland/native_drm.c 5 Sep 2013 14:01:47 -0000 1.2 +++ dist/Mesa/src/gallium/state_trackers/egl/wayland/native_drm.c 18 Nov 2013 00:49:28 -0000 @@ -268,7 +268,7 @@ wayland_drm_display_bind_wayland_display if (drmdpy->wl_server_drm) return FALSE; - drmdpy->wl_server_drm = + ndpy->wl_server_drm = wayland_drm_init(wl_dpy, drmdpy->device_name, &wl_drm_callbacks, ndpy, 0); Index: dist/Mesa/src/gallium/state_trackers/egl/x11/native_dri2.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/gallium/state_trackers/egl/x11/native_dri2.c,v retrieving revision 1.4 diff -u -p -r1.4 native_dri2.c --- dist/Mesa/src/gallium/state_trackers/egl/x11/native_dri2.c 5 Sep 2013 14:01:47 -0000 1.4 +++ dist/Mesa/src/gallium/state_trackers/egl/x11/native_dri2.c 18 Nov 2013 00:49:28 -0000 @@ -858,7 +858,7 @@ dri2_display_bind_wayland_display(struct if (dri2dpy->wl_server_drm) return FALSE; - dri2dpy->wl_server_drm = wayland_drm_init(wl_dpy, + ndpy->wl_server_drm = wayland_drm_init(wl_dpy, x11_screen_get_device_name(dri2dpy->xscr), &wl_drm_callbacks, ndpy, 0); Index: dist/Mesa/src/gbm/backends/dri/gbm_dri.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/gbm/backends/dri/gbm_dri.c,v retrieving revision 1.2 diff -u -p -r1.2 gbm_dri.c --- dist/Mesa/src/gbm/backends/dri/gbm_dri.c 5 Sep 2013 14:02:21 -0000 1.2 +++ dist/Mesa/src/gbm/backends/dri/gbm_dri.c 18 Nov 2013 00:49:28 -0000 @@ -376,7 +376,10 @@ gbm_dri_bo_import(struct gbm_device *gbm { struct wl_drm_buffer *wb = (struct wl_drm_buffer *) buffer; - if (!wayland_buffer_is_drm(buffer)) + if (dri->wl_drm == NULL) + return NULL; + + if (!wayland_buffer_is_drm(dri->wl_drm, buffer)) return NULL; image = wb->driver_buffer; Index: dist/Mesa/src/gbm/backends/dri/gbm_driint.h =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/gbm/backends/dri/gbm_driint.h,v retrieving revision 1.2 diff -u -p -r1.2 gbm_driint.h --- dist/Mesa/src/gbm/backends/dri/gbm_driint.h 5 Sep 2013 14:02:21 -0000 1.2 +++ dist/Mesa/src/gbm/backends/dri/gbm_driint.h 18 Nov 2013 00:49:28 -0000 @@ -66,6 +66,8 @@ struct gbm_dri_device { int *width, int *height, unsigned int *attachments, int count, int *out_count, void *data); + + struct wl_drm *wl_drm; }; struct gbm_dri_bo { Index: dist/Mesa/src/mesa/drivers/common/meta.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/mesa/drivers/common/meta.c,v retrieving revision 1.6 diff -u -p -r1.6 meta.c --- dist/Mesa/src/mesa/drivers/common/meta.c 5 Oct 2013 09:53:58 -0000 1.6 +++ dist/Mesa/src/mesa/drivers/common/meta.c 18 Nov 2013 00:49:28 -0000 @@ -1515,6 +1515,9 @@ setup_glsl_blit_framebuffer(struct gl_co sizeof(struct vertex), OFFSET(x)); _mesa_VertexAttribPointer(1, 2, GL_FLOAT, GL_FALSE, sizeof(struct vertex), OFFSET(s)); + + _mesa_EnableVertexAttribArray(0); + _mesa_EnableVertexAttribArray(1); } /* Generate a relevant fragment shader program for the texture target */ @@ -1591,8 +1594,6 @@ setup_glsl_blit_framebuffer(struct gl_co _mesa_DeleteObjectARB(vs); _mesa_BindAttribLocation(ShaderProg, 0, "position"); _mesa_BindAttribLocation(ShaderProg, 1, "texcoords"); - _mesa_EnableVertexAttribArray(0); - _mesa_EnableVertexAttribArray(1); link_program_with_debug(ctx, ShaderProg); ralloc_free(mem_ctx); if (texture_2d) Index: dist/Mesa/src/mesa/drivers/dri/i965/brw_misc_state.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/mesa/drivers/dri/i965/brw_misc_state.c,v retrieving revision 1.8 diff -u -p -r1.8 brw_misc_state.c --- dist/Mesa/src/mesa/drivers/dri/i965/brw_misc_state.c 5 Sep 2013 14:04:19 -0000 1.8 +++ dist/Mesa/src/mesa/drivers/dri/i965/brw_misc_state.c 18 Nov 2013 00:49:28 -0000 @@ -48,6 +48,10 @@ static void upload_drawing_rect(struct b { struct gl_context *ctx = &brw->ctx; + /* 3DSTATE_DRAWING_RECTANGLE is non-pipelined. */ + if (brw->gen == 6) + intel_emit_post_sync_nonzero_flush(brw); + BEGIN_BATCH(4); OUT_BATCH(_3DSTATE_DRAWING_RECTANGLE << 16 | (4 - 2)); OUT_BATCH(0); /* xmin, ymin */ Index: dist/Mesa/src/mesa/drivers/dri/i965/brw_wm_surface_state.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/mesa/drivers/dri/i965/brw_wm_surface_state.c,v retrieving revision 1.7 diff -u -p -r1.7 brw_wm_surface_state.c --- dist/Mesa/src/mesa/drivers/dri/i965/brw_wm_surface_state.c 5 Sep 2013 14:04:23 -0000 1.7 +++ dist/Mesa/src/mesa/drivers/dri/i965/brw_wm_surface_state.c 18 Nov 2013 00:49:28 -0000 @@ -259,6 +259,7 @@ brw_update_texture_surface(struct gl_con uint32_t *surf; uint32_t tile_x, tile_y; + /* BRW_NEW_UNIFORM_BUFFER */ if (tObj->Target == GL_TEXTURE_BUFFER) { brw_update_buffer_texture_surface(ctx, unit, binding_table, surf_index); return; @@ -797,6 +798,7 @@ const struct brw_tracked_state brw_textu .dirty = { .mesa = _NEW_TEXTURE, .brw = BRW_NEW_BATCH | + BRW_NEW_UNIFORM_BUFFER | BRW_NEW_VERTEX_PROGRAM | BRW_NEW_FRAGMENT_PROGRAM, .cache = 0 Index: dist/Mesa/src/mesa/drivers/dri/i965/gen6_blorp.cpp =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/mesa/drivers/dri/i965/gen6_blorp.cpp,v retrieving revision 1.1.1.1 diff -u -p -r1.1.1.1 gen6_blorp.cpp --- dist/Mesa/src/mesa/drivers/dri/i965/gen6_blorp.cpp 5 Sep 2013 13:15:42 -0000 1.1.1.1 +++ dist/Mesa/src/mesa/drivers/dri/i965/gen6_blorp.cpp 18 Nov 2013 00:49:28 -0000 @@ -924,6 +924,18 @@ gen6_blorp_emit_depth_disable(struct brw OUT_BATCH(0); OUT_BATCH(0); ADVANCE_BATCH(); + + BEGIN_BATCH(3); + OUT_BATCH(_3DSTATE_HIER_DEPTH_BUFFER << 16 | (3 - 2)); + OUT_BATCH(0); + OUT_BATCH(0); + ADVANCE_BATCH(); + + BEGIN_BATCH(3); + OUT_BATCH(_3DSTATE_STENCIL_BUFFER << 16 | (3 - 2)); + OUT_BATCH(0); + OUT_BATCH(0); + ADVANCE_BATCH(); } @@ -951,6 +963,9 @@ void gen6_blorp_emit_drawing_rectangle(struct brw_context *brw, const brw_blorp_params *params) { + if (brw->gen == 6) + intel_emit_post_sync_nonzero_flush(brw); + BEGIN_BATCH(4); OUT_BATCH(_3DSTATE_DRAWING_RECTANGLE << 16 | (4 - 2)); OUT_BATCH(0); Index: dist/Mesa/src/mesa/drivers/dri/i965/gen6_multisample_state.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/mesa/drivers/dri/i965/gen6_multisample_state.c,v retrieving revision 1.1.1.1 diff -u -p -r1.1.1.1 gen6_multisample_state.c --- dist/Mesa/src/mesa/drivers/dri/i965/gen6_multisample_state.c 5 Sep 2013 13:15:43 -0000 1.1.1.1 +++ dist/Mesa/src/mesa/drivers/dri/i965/gen6_multisample_state.c 18 Nov 2013 00:49:28 -0000 @@ -128,6 +128,9 @@ gen6_emit_3dstate_multisample(struct brw break; } + /* 3DSTATE_MULTISAMPLE is nonpipelined. */ + intel_emit_post_sync_nonzero_flush(brw); + int len = brw->gen >= 7 ? 4 : 3; BEGIN_BATCH(len); OUT_BATCH(_3DSTATE_MULTISAMPLE << 16 | (len - 2)); @@ -182,9 +185,6 @@ static void upload_multisample_state(str sample_mask = ctx->Multisample.SampleMaskValue; } } - - /* 3DSTATE_MULTISAMPLE is nonpipelined. */ - intel_emit_post_sync_nonzero_flush(brw); gen6_emit_3dstate_multisample(brw, num_samples); gen6_emit_3dstate_sample_mask(brw, num_samples, coverage, Index: dist/Mesa/src/mesa/drivers/dri/i965/gen6_queryobj.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/mesa/drivers/dri/i965/gen6_queryobj.c,v retrieving revision 1.1.1.1 diff -u -p -r1.1.1.1 gen6_queryobj.c --- dist/Mesa/src/mesa/drivers/dri/i965/gen6_queryobj.c 5 Sep 2013 13:15:43 -0000 1.1.1.1 +++ dist/Mesa/src/mesa/drivers/dri/i965/gen6_queryobj.c 18 Nov 2013 00:49:28 -0000 @@ -115,14 +115,14 @@ write_reg(struct brw_context *brw, BEGIN_BATCH(3); OUT_BATCH(MI_STORE_REGISTER_MEM | (3 - 2)); OUT_BATCH(reg); - OUT_RELOC(query_bo, I915_GEM_DOMAIN_RENDER, I915_GEM_DOMAIN_RENDER, + OUT_RELOC(query_bo, I915_GEM_DOMAIN_INSTRUCTION, I915_GEM_DOMAIN_INSTRUCTION, idx * sizeof(uint64_t)); ADVANCE_BATCH(); BEGIN_BATCH(3); OUT_BATCH(MI_STORE_REGISTER_MEM | (3 - 2)); OUT_BATCH(reg + sizeof(uint32_t)); - OUT_RELOC(query_bo, I915_GEM_DOMAIN_RENDER, I915_GEM_DOMAIN_RENDER, + OUT_RELOC(query_bo, I915_GEM_DOMAIN_INSTRUCTION, I915_GEM_DOMAIN_INSTRUCTION, sizeof(uint32_t) + idx * sizeof(uint64_t)); ADVANCE_BATCH(); } Index: dist/Mesa/src/mesa/drivers/dri/i965/gen6_sol.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/mesa/drivers/dri/i965/gen6_sol.c,v retrieving revision 1.1.1.1 diff -u -p -r1.1.1.1 gen6_sol.c --- dist/Mesa/src/mesa/drivers/dri/i965/gen6_sol.c 5 Sep 2013 13:15:43 -0000 1.1.1.1 +++ dist/Mesa/src/mesa/drivers/dri/i965/gen6_sol.c 18 Nov 2013 00:49:28 -0000 @@ -153,6 +153,9 @@ brw_begin_transform_feedback(struct gl_c = _mesa_compute_max_transform_feedback_vertices(xfb_obj, linked_xfb_info); + /* 3DSTATE_GS_SVB_INDEX is non-pipelined. */ + intel_emit_post_sync_nonzero_flush(brw); + /* Initialize the SVBI 0 register to zero and set the maximum index. */ BEGIN_BATCH(4); OUT_BATCH(_3DSTATE_GS_SVB_INDEX << 16 | (4 - 2)); Index: dist/Mesa/src/mesa/drivers/dri/i965/gen7_blorp.cpp =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/mesa/drivers/dri/i965/gen7_blorp.cpp,v retrieving revision 1.1.1.1 diff -u -p -r1.1.1.1 gen7_blorp.cpp --- dist/Mesa/src/mesa/drivers/dri/i965/gen7_blorp.cpp 5 Sep 2013 13:15:44 -0000 1.1.1.1 +++ dist/Mesa/src/mesa/drivers/dri/i965/gen7_blorp.cpp 18 Nov 2013 00:49:28 -0000 @@ -763,6 +763,18 @@ gen7_blorp_emit_depth_disable(struct brw OUT_BATCH(0); OUT_BATCH(0); ADVANCE_BATCH(); + + BEGIN_BATCH(3); + OUT_BATCH(GEN7_3DSTATE_HIER_DEPTH_BUFFER << 16 | (3 - 2)); + OUT_BATCH(0); + OUT_BATCH(0); + ADVANCE_BATCH(); + + BEGIN_BATCH(3); + OUT_BATCH(GEN7_3DSTATE_STENCIL_BUFFER << 16 | (3 - 2)); + OUT_BATCH(0); + OUT_BATCH(0); + ADVANCE_BATCH(); } Index: dist/Mesa/src/mesa/drivers/osmesa/osmesa.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/mesa/drivers/osmesa/osmesa.c,v retrieving revision 1.6 diff -u -p -r1.6 osmesa.c --- dist/Mesa/src/mesa/drivers/osmesa/osmesa.c 5 Sep 2013 14:05:58 -0000 1.6 +++ dist/Mesa/src/mesa/drivers/osmesa/osmesa.c 18 Nov 2013 00:49:28 -0000 @@ -197,6 +197,14 @@ osmesa_choose_line_function( struct gl_c const OSMesaContext osmesa = OSMESA_CONTEXT(ctx); const SWcontext *swrast = SWRAST_CONTEXT(ctx); + if (ctx->DrawBuffer && + ctx->DrawBuffer->Visual.redBits == 32) { + /* the special-case line functions in this file don't work + * for float color channels. + */ + return NULL; + } + if (ctx->RenderMode != GL_RENDER) return NULL; if (ctx->Line.SmoothFlag) return NULL; if (ctx->Texture._EnabledUnits) return NULL; @@ -297,6 +305,14 @@ osmesa_choose_triangle_function( struct { const OSMesaContext osmesa = OSMESA_CONTEXT(ctx); const SWcontext *swrast = SWRAST_CONTEXT(ctx); + + if (ctx->DrawBuffer && + ctx->DrawBuffer->Visual.redBits == 32) { + /* the special-case triangle functions in this file don't work + * for float color channels. + */ + return (swrast_tri_func) NULL; + } if (ctx->RenderMode != GL_RENDER) return (swrast_tri_func) NULL; if (ctx->Polygon.SmoothFlag) return (swrast_tri_func) NULL; Index: dist/Mesa/src/mesa/main/querymatrix.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/mesa/main/querymatrix.c,v retrieving revision 1.1.1.2 diff -u -p -r1.1.1.2 querymatrix.c --- dist/Mesa/src/mesa/main/querymatrix.c 5 Sep 2013 13:16:47 -0000 1.1.1.2 +++ dist/Mesa/src/mesa/main/querymatrix.c 18 Nov 2013 00:49:28 -0000 @@ -38,6 +38,7 @@ #define FLOAT_TO_FIXED(x) ((GLfixed) ((x) * 65536.0)) #if defined(_MSC_VER) +#if _MSC_VER < 1800 /* Not required on VS2013 and above. */ /* Oddly, the fpclassify() function doesn't exist in such a form * on MSVC. This is an implementation using slightly different * lower-level Windows functions. @@ -70,6 +71,7 @@ fpclassify(double x) return FP_NAN; } } +#endif /* _MSC_VER < 1800 */ #elif defined(__APPLE__) || defined(__CYGWIN__) || defined(__FreeBSD__) || \ defined(__OpenBSD__) || defined(__NetBSD__) || defined(__DragonFly__) || \ Index: dist/Mesa/src/mesa/main/queryobj.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/mesa/main/queryobj.c,v retrieving revision 1.6 diff -u -p -r1.6 queryobj.c --- dist/Mesa/src/mesa/main/queryobj.c 5 Sep 2013 14:06:26 -0000 1.6 +++ dist/Mesa/src/mesa/main/queryobj.c 18 Nov 2013 00:49:28 -0000 @@ -201,13 +201,6 @@ _mesa_GenQueries(GLsizei n, GLuint *ids) return; } - /* No query objects can be active at this time! */ - if (ctx->Query.CurrentOcclusionObject || - ctx->Query.CurrentTimerObject) { - _mesa_error(ctx, GL_INVALID_OPERATION, "glGenQueriesARB"); - return; - } - first = _mesa_HashFindFreeKeyBlock(ctx->Query.QueryObjects, n); if (first) { GLsizei i; @@ -240,18 +233,20 @@ _mesa_DeleteQueries(GLsizei n, const GLu return; } - /* No query objects can be active at this time! */ - if (ctx->Query.CurrentOcclusionObject || - ctx->Query.CurrentTimerObject) { - _mesa_error(ctx, GL_INVALID_OPERATION, "glDeleteQueriesARB"); - return; - } - for (i = 0; i < n; i++) { if (ids[i] > 0) { struct gl_query_object *q = _mesa_lookup_query_object(ctx, ids[i]); if (q) { - ASSERT(!q->Active); /* should be caught earlier */ + if (q->Active) { + struct gl_query_object **bindpt; + bindpt = get_query_binding_point(ctx, q->Target); + assert(bindpt); /* Should be non-null for active q. */ + if (bindpt) { + *bindpt = NULL; + } + q->Active = GL_FALSE; + ctx->Driver.EndQuery(ctx, q); + } _mesa_HashRemove(ctx->Query.QueryObjects, ids[i]); ctx->Driver.DeleteQuery(ctx, q); } Index: dist/Mesa/src/mesa/state_tracker/st_draw.c =================================================================== RCS file: /cvs/xenocara/dist/Mesa/src/mesa/state_tracker/st_draw.c,v retrieving revision 1.4 diff -u -p -r1.4 st_draw.c --- dist/Mesa/src/mesa/state_tracker/st_draw.c 5 Sep 2013 14:06:45 -0000 1.4 +++ dist/Mesa/src/mesa/state_tracker/st_draw.c 18 Nov 2013 00:49:28 -0000 @@ -209,9 +209,6 @@ st_draw_vbo(struct gl_context *ctx, if (st->dirty.st || ctx->NewDriverState) { st_validate_state(st); - if (st->vertex_array_out_of_memory) - return; - #if 0 if (MESA_VERBOSE & VERBOSE_GLSL) { check_uniforms(ctx); @@ -219,6 +216,10 @@ st_draw_vbo(struct gl_context *ctx, #else (void) check_uniforms; #endif + } + + if (st->vertex_array_out_of_memory) { + return; } util_draw_init_info(&info); Index: lib/libEGL/Makefile =================================================================== RCS file: /cvs/xenocara/lib/libEGL/Makefile,v retrieving revision 1.4 diff -u -p -r1.4 Makefile --- lib/libEGL/Makefile 9 Nov 2013 02:54:53 -0000 1.4 +++ lib/libEGL/Makefile 18 Nov 2013 00:52:32 -0000 @@ -9,7 +9,7 @@ MESA_INCLUDE= ${.CURDIR}/../../dist/Mesa MESA_MAJOR= 9 MESA_MINOR= 2 -MESA_TINY= 2 +MESA_TINY= 3 DRI_DRIVER_INSTALL_DIR= ${X11BASE}/lib/modules/dri EGL_DRIVER_SEARCH_DIR= ${X11BASE}/lib/modules/egl Index: lib/libGL/Makefile =================================================================== RCS file: /cvs/xenocara/lib/libGL/Makefile,v retrieving revision 1.39 diff -u -p -r1.39 Makefile --- lib/libGL/Makefile 9 Nov 2013 02:54:53 -0000 1.39 +++ lib/libGL/Makefile 18 Nov 2013 00:52:43 -0000 @@ -22,7 +22,7 @@ MESA_DRI= ${.CURDIR}/../../dist/Mesa/src # this needs to be updated in mesa/Makefile.inc as well MESA_MAJOR= 9 MESA_MINOR= 2 -MESA_TINY= 2 +MESA_TINY= 3 DRI_DRIVER_INSTALL_DIR= ${X11BASE}/lib/modules/dri Index: lib/libGL/mesa/Makefile.inc =================================================================== RCS file: /cvs/xenocara/lib/libGL/mesa/Makefile.inc,v retrieving revision 1.5 diff -u -p -r1.5 Makefile.inc --- lib/libGL/mesa/Makefile.inc 9 Nov 2013 02:54:53 -0000 1.5 +++ lib/libGL/mesa/Makefile.inc 18 Nov 2013 02:22:25 -0000 @@ -9,7 +9,7 @@ MESA_INCLUDE= ${.CURDIR}/../../../../dis MESA_MAJOR= 9 MESA_MINOR= 2 -MESA_TINY= 2 +MESA_TINY= 3 CPP= cpp -notraditional Index: lib/libGLESv1_CM/Makefile =================================================================== RCS file: /cvs/xenocara/lib/libGLESv1_CM/Makefile,v retrieving revision 1.3 diff -u -p -r1.3 Makefile --- lib/libGLESv1_CM/Makefile 9 Nov 2013 02:54:53 -0000 1.3 +++ lib/libGLESv1_CM/Makefile 18 Nov 2013 00:52:52 -0000 @@ -10,7 +10,7 @@ MESA_INCLUDE= ${.CURDIR}/../../dist/Mesa MESA_MAJOR= 9 MESA_MINOR= 2 -MESA_TINY= 2 +MESA_TINY= 3 INCSDIR= ${X11BASE}/include/GLES Index: lib/libGLESv2/Makefile =================================================================== RCS file: /cvs/xenocara/lib/libGLESv2/Makefile,v retrieving revision 1.3 diff -u -p -r1.3 Makefile --- lib/libGLESv2/Makefile 9 Nov 2013 02:54:53 -0000 1.3 +++ lib/libGLESv2/Makefile 18 Nov 2013 00:53:01 -0000 @@ -10,7 +10,7 @@ MESA_INCLUDE= ${.CURDIR}/../../dist/Mesa MESA_MAJOR= 9 MESA_MINOR= 2 -MESA_TINY= 2 +MESA_TINY= 3 INCSDIR= ${X11BASE}/include/GLES2 INCSDIR3= ${X11BASE}/include/GLES3