diff --git a/src/mesa/drivers/dri/intel/intel_batchbuffer.h b/src/mesa/drivers/dri/intel/intel_batchbuffer.h index 51579df..d7f3094 100644 --- a/src/mesa/drivers/dri/intel/intel_batchbuffer.h +++ b/src/mesa/drivers/dri/intel/intel_batchbuffer.h @@ -8,7 +8,8 @@ #include "intel_reg.h" #define BATCH_SZ 16384 -#define BATCH_RESERVED 16 +#define BATCH_RESERVED16 16 +#define BATCH_RESERVED4k 4096 enum cliprect_mode { /** @@ -104,7 +105,10 @@ GLboolean intel_batchbuffer_emit_reloc(struct intel_batchbuffer *batch, static INLINE GLint intel_batchbuffer_space(struct intel_batchbuffer *batch) { - return (batch->size - BATCH_RESERVED) - (batch->ptr - batch->map); + if (batch->intel->intelScreen->deviceID == PCI_CHIP_I865_G) + return (batch->size - BATCH_RESERVED16) - (batch->ptr - batch->map); + else + return (batch->size - BATCH_RESERVED4k) - (batch->ptr - batch->map); }