asahi: Add PIPE_BIND_SHARED to imported resources

Signed-off-by: Asahi Lina <lina@asahilina.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32081>
This commit is contained in:
Asahi Lina 2024-10-31 03:04:04 +09:00 committed by Marge Bot
parent 59501af723
commit f28a1b3fcf

View file

@ -197,6 +197,8 @@ agx_resource_from_handle(struct pipe_screen *pscreen,
pipe_reference_init(&prsc->reference, 1);
prsc->screen = pscreen;
prsc->bind |= PIPE_BIND_SHARED;
rsc->bo = agx_bo_import(dev, whandle->handle);
/* Sometimes an import can fail e.g. on an invalid buffer fd, out of
* memory space to mmap it etc.