summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri/intel/intel_context.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/drivers/dri/intel/intel_context.c')
-rw-r--r--src/mesa/drivers/dri/intel/intel_context.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_context.c b/src/mesa/drivers/dri/intel/intel_context.c
index 13a28f0419..0adee6131e 100644
--- a/src/mesa/drivers/dri/intel/intel_context.c
+++ b/src/mesa/drivers/dri/intel/intel_context.c
@@ -28,7 +28,6 @@
#include "main/glheader.h"
#include "main/context.h"
-#include "main/arrayobj.h"
#include "main/extensions.h"
#include "main/framebuffer.h"
#include "main/imports.h"
@@ -52,13 +51,11 @@
#include "intel_regions.h"
#include "intel_buffer_objects.h"
#include "intel_fbo.h"
-#include "intel_decode.h"
#include "intel_bufmgr.h"
#include "intel_screen.h"
#include "drirenderbuffer.h"
#include "utils.h"
-#include "xmlpool.h" /* for symbolic values of enum-type options */
#ifndef INTEL_DEBUG
@@ -70,8 +67,6 @@ int INTEL_DEBUG = (0);
#define DRIVER_DATE_GEM "GEM " DRIVER_DATE
-static void intel_flush(GLcontext *ctx, GLboolean needs_mi_flush);
-
static const GLubyte *
intelGetString(GLcontext * ctx, GLenum name)
{
@@ -378,6 +373,7 @@ intel_update_renderbuffers(__DRIcontext *context, __DRIdrawable *drawable)
}
}
+ drawable->validBuffers = GL_TRUE;
driUpdateFramebufferSize(&intel->ctx, drawable);
}
@@ -461,7 +457,7 @@ intelInvalidateState(GLcontext * ctx, GLuint new_state)
intel->vtbl.invalidate_state( intel, new_state );
}
-static void
+void
intel_flush(GLcontext *ctx, GLboolean needs_mi_flush)
{
struct intel_context *intel = intel_context(ctx);
@@ -523,7 +519,8 @@ intel_glFlush(GLcontext *ctx)
* and getting our hands on that doesn't seem worth it, so we just us the
* first batch we emitted after the last swap.
*/
- if (intel->first_post_swapbuffers_batch != NULL) {
+ if (!intel->using_dri2_swapbuffers &&
+ intel->first_post_swapbuffers_batch != NULL) {
drm_intel_bo_wait_rendering(intel->first_post_swapbuffers_batch);
drm_intel_bo_unreference(intel->first_post_swapbuffers_batch);
intel->first_post_swapbuffers_batch = NULL;