anv: Initialize anv_bo::offset to -1
Since -1 is an invalid GPU address, this lets us know whether or not we have a valid address for a buffer. We don't get a valid address until the first time that buffer is used in an execbuf2 ioctl. Signed-off-by: Jason Ekstrand <jason@jlekstrand.net> Reviewed-by: Kristian H. Kristensen <hoegsberg@google.com> Cc: "13.0" <mesa-stable@lists.freedesktop.org>
This commit is contained in:
parent
bd0f8d5070
commit
d46bfb6297
|
@ -275,7 +275,7 @@ anv_bo_init(struct anv_bo *bo, uint32_t gem_handle, uint64_t size)
|
||||||
{
|
{
|
||||||
bo->gem_handle = gem_handle;
|
bo->gem_handle = gem_handle;
|
||||||
bo->index = 0;
|
bo->index = 0;
|
||||||
bo->offset = 0;
|
bo->offset = -1;
|
||||||
bo->size = size;
|
bo->size = size;
|
||||||
bo->map = NULL;
|
bo->map = NULL;
|
||||||
bo->is_winsys_bo = false;
|
bo->is_winsys_bo = false;
|
||||||
|
|
Loading…
Reference in New Issue