aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/etnaviv/etnaviv_texture.h
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2019-08-03 03:13:55 -0700
committerKenneth Graunke <[email protected]>2019-08-05 08:53:41 -0700
commit64b73b770b71c15b5628545fed132f81a51bd555 (patch)
tree09976de394368d6556126606128a684319f5b6b6 /src/gallium/drivers/etnaviv/etnaviv_texture.h
parent48e5a99d86967783de1fb46a2e82293825089a7a (diff)
iris: Fix bad external BO hash table and zombie list interactions
A while ago, we started deferring GEM object closure and VMA release until buffers were idle. This had some unforeseen interactions with external buffers. We keep imported buffers in hash tables, so if we have repeated imports of the same GEM object, we map those to the same iris_bo structure. This is critical for several reasons. Unfortunately, we broke this assumption. When freeing a non-idle external buffer, we would drop it from the hash tables, then move it to the zombie list. If someone reimported the same GEM object, we would not find it in the hash tables, and go ahead and make a second iris_bo for that GEM object. But the old iris_bo would still be in the zombie list, and so we would eventually call GEM_CLOSE on it - closing a BO that should have still been live. To work around this, we defer removing a BO from the hash tables until it's actually fully closed. This has the strange effect that an external BO may be on the zombie list, and yet be resurrected before it can be properly cleaned up. In this case, we remove it from the list so it won't be freed. Fixes severe instability in Weston, which was hitting EINVALs and ENOENTs from execbuf2, due to batches referring to a GEM object that had been closed, or at least had its VMA torched. Fixes: 457a55716ea ("iris: Defer closing and freeing VMA until buffers are idle.")
Diffstat (limited to 'src/gallium/drivers/etnaviv/etnaviv_texture.h')
0 files changed, 0 insertions, 0 deletions