[Mesa-dev] [PATCH libdrm 8/9] panfrost/midgard: Move requirement setting into panfrost_job

Rohan Garg rohan.garg at collabora.com
Wed Jun 12 11:24:38 UTC 2019


Move panfrost_job_set_requirements into panfrost_get_job_for_fbo,
requirements should be set when acquiring a job from a context.
---
 src/gallium/drivers/panfrost/pan_context.c | 2 --
 src/gallium/drivers/panfrost/pan_job.c     | 1 +
 2 files changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/gallium/drivers/panfrost/pan_context.c b/src/gallium/drivers/panfrost/pan_context.c
index ced25cf4b82..00acb464bc6 100644
--- a/src/gallium/drivers/panfrost/pan_context.c
+++ b/src/gallium/drivers/panfrost/pan_context.c
@@ -872,8 +872,6 @@ panfrost_emit_for_draw(struct panfrost_context *ctx, bool with_vertex_data)
                 SET_BIT(ctx->fragment_shader_core.unknown2_4, MALI_NO_MSAA, !msaa);
         }
 
-        panfrost_job_set_requirements(ctx, job);
-
         if (ctx->occlusion_query) {
                 ctx->payload_tiler.gl_enables |= MALI_OCCLUSION_QUERY | MALI_OCCLUSION_PRECISE;
                 ctx->payload_tiler.postfix.occlusion_counter = ctx->occlusion_query->transfer.gpu;
diff --git a/src/gallium/drivers/panfrost/pan_job.c b/src/gallium/drivers/panfrost/pan_job.c
index 3ae7450c189..86fb24a119b 100644
--- a/src/gallium/drivers/panfrost/pan_job.c
+++ b/src/gallium/drivers/panfrost/pan_job.c
@@ -109,6 +109,7 @@ panfrost_get_job_for_fbo(struct panfrost_context *ctx)
         struct pipe_surface **cbufs = ctx->pipe_framebuffer.cbufs;
         struct pipe_surface *zsbuf = ctx->pipe_framebuffer.zsbuf;
         struct panfrost_job *job = panfrost_get_job(ctx, cbufs, zsbuf);
+        panfrost_job_set_requirements(ctx, job);
 
         return job;
 }
-- 
2.17.1



More information about the mesa-dev mailing list