[Mesa-dev] [PATCH 1/3] nvc0: set current bufctx to nvc0->bufctx at the end of nvc0_draw_vbo()

Rhys Perry pendingchaos02 at gmail.com
Wed Apr 11 13:31:32 UTC 2018


It seems nvc0_hw_get_query_result_resource() expects nvc0->bufctx or
nvc0->bufctx_* to be in effect. This is not guaranteed because
nvc0_draw_vbo() previously set the current bufctx to NULL.

Signed-off-by: Rhys Perry <pendingchaos02 at gmail.com>
---
 src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c b/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c
index 66de6d9e2f..f7c9a83bfd 100644
--- a/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c
+++ b/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c
@@ -1090,7 +1090,7 @@ cleanup:
 
    nvc0_release_user_vbufs(nvc0);
 
-   nouveau_pushbuf_bufctx(push, NULL);
+   nouveau_pushbuf_bufctx(push, nvc0->bufctx);
 
    nouveau_bufctx_reset(nvc0->bufctx_3d, NVC0_BIND_3D_IDX);
    nouveau_bufctx_reset(nvc0->bufctx_3d, NVC0_BIND_3D_BINDLESS);
-- 
2.14.3



More information about the mesa-dev mailing list