u_blitter: add a msaa parameter to util_blitter_clear
[mesa.git] / src / gallium / drivers / v3d / v3d_query.c
index d3447793b0a4c30306b962b18d81a647c6189ce5..31b62461f90ca29cb4ed32846bcf4e04cea09633 100644 (file)
@@ -64,7 +64,7 @@ v3d_destroy_query(struct pipe_context *pctx, struct pipe_query *query)
         free(q);
 }
 
-static boolean
+static bool
 v3d_begin_query(struct pipe_context *pctx, struct pipe_query *query)
 {
         struct v3d_context *v3d = v3d_context(pctx);
@@ -112,16 +112,16 @@ v3d_end_query(struct pipe_context *pctx, struct pipe_query *query)
         return true;
 }
 
-static boolean
+static bool
 v3d_get_query_result(struct pipe_context *pctx, struct pipe_query *query,
-                     boolean wait, union pipe_query_result *vresult)
+                     bool wait, union pipe_query_result *vresult)
 {
+        struct v3d_context *v3d = v3d_context(pctx);
         struct v3d_query *q = (struct v3d_query *)query;
         uint32_t result = 0;
 
         if (q->bo) {
-                /* XXX: Only flush the jobs using this BO. */
-                v3d_flush(pctx);
+                v3d_flush_jobs_using_bo(v3d, q->bo);
 
                 if (wait) {
                         if (!v3d_bo_wait(q->bo, 0, "query"))
@@ -158,7 +158,7 @@ v3d_get_query_result(struct pipe_context *pctx, struct pipe_query *query,
 }
 
 static void
-v3d_set_active_query_state(struct pipe_context *pctx, boolean enable)
+v3d_set_active_query_state(struct pipe_context *pctx, bool enable)
 {
         struct v3d_context *v3d = v3d_context(pctx);