i965: Use old_bo->align when growing batch/state buffer instead of 4096.
authorKenneth Graunke <kenneth@whitecape.org>
Tue, 28 Nov 2017 16:30:50 +0000 (08:30 -0800)
committerKenneth Graunke <kenneth@whitecape.org>
Thu, 30 Nov 2017 01:30:35 +0000 (17:30 -0800)
commit2af70854609509adf5dc92af2fcf1c30938e2a5d
tree5a54fda48a5e44801e3d2da9b5df7655df6a55ea
parent2c4861e45319adae190fe59caa5950c064ca0d3c
i965: Use old_bo->align when growing batch/state buffer instead of 4096.

The intention here is make the new BO use the same alignment as the old
BO.  This isn't strictly necessary, but we would have to update the
'alignment' field in the validation list when swapping it out, and we
don't bother today.

The batch and state buffers use an alignment of 4096, so this should be
equivalent - it's just clearer than cut and pasting a magic constant.

Fixes: 2dfc119f22f257082ab0 "i965: Grow the batch/state buffers if we need space and can't flush."
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
src/mesa/drivers/dri/i965/intel_batchbuffer.c