summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/virgl/virgl_resource.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/drivers/virgl/virgl_resource.c')
-rw-r--r--src/gallium/drivers/virgl/virgl_resource.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/gallium/drivers/virgl/virgl_resource.c b/src/gallium/drivers/virgl/virgl_resource.c
index e9ccf66f8d0..9b42bd14c42 100644
--- a/src/gallium/drivers/virgl/virgl_resource.c
+++ b/src/gallium/drivers/virgl/virgl_resource.c
@@ -28,12 +28,13 @@
#include "virgl_screen.h"
bool virgl_res_needs_flush_wait(struct virgl_context *vctx,
- struct virgl_resource *res,
- unsigned usage)
+ struct virgl_transfer *trans)
{
struct virgl_screen *vs = virgl_screen(vctx->base.screen);
+ struct virgl_resource *res = virgl_resource(trans->base.resource);
- if ((!(usage & PIPE_TRANSFER_UNSYNCHRONIZED)) && vs->vws->res_is_referenced(vs->vws, vctx->cbuf, res->hw_res)) {
+ if ((!(trans->base.usage & PIPE_TRANSFER_UNSYNCHRONIZED)) &&
+ vs->vws->res_is_referenced(vs->vws, vctx->cbuf, res->hw_res)) {
return true;
}
return false;