i965: Assert the execobject handles match for this device

Object handles are local to the device fd, so double check we are not
mixing together objects from multiple screens on execbuf submission.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
This commit is contained in:
Chris Wilson 2019-02-14 12:04:59 +00:00 committed by Kenneth Graunke
parent 99b90ecd35
commit e9882b879b

View file

@ -188,6 +188,8 @@ intel_batchbuffer_init(struct brw_context *brw)
static unsigned
add_exec_bo(struct intel_batchbuffer *batch, struct brw_bo *bo)
{
assert(bo->bufmgr == batch->batch.bo->bufmgr);
unsigned index = READ_ONCE(bo->index);
if (index < batch->exec_count && batch->exec_bos[index] == bo)