drm/vc4: add tracepoints for CL submissions
[linux-2.6-microblaze.git] / drivers / gpu / drm / vc4 / vc4_gem.c
index 445d3ba..4abf10b 100644 (file)
@@ -485,6 +485,8 @@ again:
         * immediately move it to the to-be-rendered queue.
         */
        if (exec->ct0ca != exec->ct0ea) {
+               trace_vc4_submit_cl(dev, false, exec->seqno, exec->ct0ca,
+                                   exec->ct0ea);
                submit_cl(dev, 0, exec->ct0ca, exec->ct0ea);
        } else {
                struct vc4_exec_info *next;
@@ -519,6 +521,7 @@ vc4_submit_next_render_job(struct drm_device *dev)
         */
        vc4_flush_texture_caches(dev);
 
+       trace_vc4_submit_cl(dev, true, exec->seqno, exec->ct1ca, exec->ct1ea);
        submit_cl(dev, 1, exec->ct1ca, exec->ct1ea);
 }
 
@@ -1135,6 +1138,10 @@ vc4_submit_cl_ioctl(struct drm_device *dev, void *data,
        struct dma_fence *in_fence;
        int ret = 0;
 
+       trace_vc4_submit_cl_ioctl(dev, args->bin_cl_size,
+                                 args->shader_rec_size,
+                                 args->bo_handle_count);
+
        if (!vc4->v3d) {
                DRM_DEBUG("VC4_SUBMIT_CL with no VC4 V3D probed\n");
                return -ENODEV;