summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
authorThomas Hellstrom <thomas-at-tungstengraphics-dot-com>2007-01-23 09:04:58 +0100
committerThomas Hellstrom <thomas-at-tungstengraphics-dot-com>2007-01-23 09:06:21 +0100
commitd46093b8d56f6d89b341d7437c5185ca6be597af (patch)
treeafde66375ea1254d8aa1b1f6d4fc82a956c71a41 /src/mesa
parentfe9fef2cec2f9ed13370612a9a58df04b0075f15 (diff)
i915tex: Relocation fixes:
Increase the number of allowed relocations per batchbuffer. Fix an assert to avoid an array index overflow. (Reported by Steve Wilkins)
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/drivers/dri/i915tex/intel_batchbuffer.c2
-rw-r--r--src/mesa/drivers/dri/i915tex/intel_batchbuffer.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/i915tex/intel_batchbuffer.c b/src/mesa/drivers/dri/i915tex/intel_batchbuffer.c
index be2750d041f..c92b83bcb3a 100644
--- a/src/mesa/drivers/dri/i915tex/intel_batchbuffer.c
+++ b/src/mesa/drivers/dri/i915tex/intel_batchbuffer.c
@@ -311,7 +311,7 @@ intel_batchbuffer_emit_reloc(struct intel_batchbuffer *batch,
struct _DriBufferObject *buffer,
GLuint flags, GLuint mask, GLuint delta)
{
- assert(batch->nr_relocs <= MAX_RELOCS);
+ assert(batch->nr_relocs < MAX_RELOCS);
driBOAddListItem(&batch->list, buffer, flags, mask);
diff --git a/src/mesa/drivers/dri/i915tex/intel_batchbuffer.h b/src/mesa/drivers/dri/i915tex/intel_batchbuffer.h
index a83dbf423df..59261f72741 100644
--- a/src/mesa/drivers/dri/i915tex/intel_batchbuffer.h
+++ b/src/mesa/drivers/dri/i915tex/intel_batchbuffer.h
@@ -9,7 +9,7 @@ struct intel_context;
#define BATCH_SZ 16384
#define BATCH_RESERVED 16
-#define MAX_RELOCS 100
+#define MAX_RELOCS 400
#define INTEL_BATCH_NO_CLIPRECTS 0x1
#define INTEL_BATCH_CLIPRECTS 0x2