[PATCH] drm/msm: add trace_dma_fence_emit to msm_gpu_submit
Dmitry Baryshkov
dmitry.baryshkov at linaro.org
Sat Apr 9 00:06:41 UTC 2022
On Sat, 9 Apr 2022 at 00:12, Chia-I Wu <olvaffe at gmail.com> wrote:
>
> In practice, trace_dma_fence_init is good enough and almost no driver
> calls trace_dma_fence_emit. But this is still more correct in theory.
Please mention in the commit message that the trace_dma_fence_init()
is called from dma_fence_init().
With that in place:
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov at linaro.org>
>
> Signed-off-by: Chia-I Wu <olvaffe at gmail.com>
> Cc: Rob Clark <robdclark at chromium.org>
> ---
> drivers/gpu/drm/msm/msm_gpu.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/gpu/drm/msm/msm_gpu.c b/drivers/gpu/drm/msm/msm_gpu.c
> index faf0c242874e..a82193f41ea2 100644
> --- a/drivers/gpu/drm/msm/msm_gpu.c
> +++ b/drivers/gpu/drm/msm/msm_gpu.c
> @@ -15,6 +15,7 @@
> #include <linux/string_helpers.h>
> #include <linux/devcoredump.h>
> #include <linux/sched/task.h>
> +#include <trace/events/dma_fence.h>
>
> /*
> * Power Management:
> @@ -769,6 +770,7 @@ void msm_gpu_submit(struct msm_gpu *gpu, struct msm_gem_submit *submit)
> gpu->active_submits++;
> mutex_unlock(&gpu->active_lock);
>
> + trace_dma_fence_emit(submit->hw_fence);
> gpu->funcs->submit(gpu, submit);
> gpu->cur_ctx_seqno = submit->queue->ctx->seqno;
>
> --
> 2.35.1.1178.g4f1659d476-goog
>
--
With best wishes
Dmitry
More information about the dri-devel
mailing list