Module: Mesa Branch: main Commit: 1c20688dcc6d160458f83100fffe4395117e2fbe URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=1c20688dcc6d160458f83100fffe4395117e2fbe
Author: Mike Blumenkrantz <[email protected]> Date: Fri Apr 29 07:40:44 2022 -0400 zink: add a flag to indicate whether a resource is exportable Reviewed-by: Dave Airlie <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16252> --- src/gallium/drivers/zink/zink_resource.c | 1 + src/gallium/drivers/zink/zink_resource.h | 1 + 2 files changed, 2 insertions(+) diff --git a/src/gallium/drivers/zink/zink_resource.c b/src/gallium/drivers/zink/zink_resource.c index c4ec0cb5f6e..5440d92ae8f 100644 --- a/src/gallium/drivers/zink/zink_resource.c +++ b/src/gallium/drivers/zink/zink_resource.c @@ -783,6 +783,7 @@ resource_object_create(struct zink_screen *screen, const struct pipe_resource *t emai.pNext = mai.pNext; mai.pNext = &emai; + obj->exportable = true; } #ifdef ZINK_USE_DMABUF diff --git a/src/gallium/drivers/zink/zink_resource.h b/src/gallium/drivers/zink/zink_resource.h index 23f86850893..680bc7c3658 100644 --- a/src/gallium/drivers/zink/zink_resource.h +++ b/src/gallium/drivers/zink/zink_resource.h @@ -78,6 +78,7 @@ struct zink_resource_object { bool transfer_dst; bool render_target; bool is_buffer; + bool exportable; /* TODO: this should be a union */ struct zink_bo *bo;
