iris: Fix refcounting of grid surface
authorKenneth Graunke <kenneth@whitecape.org>
Sat, 27 Oct 2018 05:43:34 +0000 (22:43 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Thu, 21 Feb 2019 18:26:09 +0000 (10:26 -0800)
src/gallium/drivers/iris/iris_draw.c

index 233658a1204ae4a1e21f3a339e9e10221d504625..9139f894473d559cdecbcd645b6738e2606b936b 100644 (file)
@@ -107,7 +107,7 @@ iris_update_grid_size_resource(struct iris_context *ice,
    // don't bother uploading the surface?
 
    if (grid->indirect) {
-      grid_ref->res = grid->indirect;
+      pipe_resource_reference(&grid_ref->res, grid->indirect);
       grid_ref->offset = grid->indirect_offset;
 
       /* Zero out the grid size so that the next non-indirect grid launch will