It's never true with slab and sparse buffers.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Reviewed-by: Zoltán Böszörményi <zboszor@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8849>
assert(bo->bo); /* slab buffers have a separate vtbl */
- if (bo->use_reusable_pool)
+ if (bo->u.real.use_reusable_pool)
pb_cache_add_buffer(bo->cache_entry);
else
amdgpu_bo_destroy(_buf);
}
if (init_pb_cache) {
- bo->use_reusable_pool = true;
+ bo->u.real.use_reusable_pool = true;
pb_cache_init_entry(&ws->bo_cache, bo->cache_entry, &bo->base,
heap);
}
if (!bo->bo)
return false;
- bo->use_reusable_pool = false;
+ bo->u.real.use_reusable_pool = false;
switch (whandle->type) {
case WINSYS_HANDLE_TYPE_SHARED:
int map_count;
bool is_user_ptr;
+ bool use_reusable_pool;
/* Whether buffer_get_handle or buffer_from_handle has been called,
* it can only transition from false to true. Protected by lock.
struct amdgpu_winsys *ws;
amdgpu_bo_handle bo; /* NULL for slab entries and sparse buffers */
- bool use_reusable_pool;
uint32_t unique_id;
uint64_t va;