[PATCH 3/3] drm/amdgpu: trace need_flush in grab_vm as well

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jul 12, 2016 at 8:05 AM, Christian König
<deathsimple at vodafone.de> wrote:
> From: Christian König <christian.koenig at amd.com>
>
> Signed-off-by: Christian König <christian.koenig at amd.com>

For the series:
Reviewed-by: Alex Deucher <alexander.deucher at amd.com>

> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu_trace.h | 16 +++++++++-------
>  drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c    |  4 ++--
>  2 files changed, 11 insertions(+), 9 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_trace.h b/drivers/gpu/drm/amd/amdgpu/amdgpu_trace.h
> index 499803f..0d8d65e 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_trace.h
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_trace.h
> @@ -149,24 +149,26 @@ TRACE_EVENT(amdgpu_sched_run_job,
>
>
>  TRACE_EVENT(amdgpu_vm_grab_id,
> -           TP_PROTO(struct amdgpu_vm *vm, int ring, unsigned vmid,
> -                    uint64_t pd_addr),
> -           TP_ARGS(vm, ring, vmid, pd_addr),
> +           TP_PROTO(struct amdgpu_vm *vm, int ring, struct amdgpu_job *job),
> +           TP_ARGS(vm, ring, job),
>             TP_STRUCT__entry(
>                              __field(struct amdgpu_vm *, vm)
>                              __field(u32, ring)
>                              __field(u32, vmid)
>                              __field(u64, pd_addr)
> +                            __field(u32, needs_flush)
>                              ),
>
>             TP_fast_assign(
>                            __entry->vm = vm;
>                            __entry->ring = ring;
> -                          __entry->vmid = vmid;
> -                          __entry->pd_addr = pd_addr;
> +                          __entry->vmid = job->vm_id;
> +                          __entry->pd_addr = job->vm_pd_addr;
> +                          __entry->needs_flush = job->vm_needs_flush;
>                            ),
> -           TP_printk("vm=%p, ring=%u, id=%u, pd_addr=%010Lx", __entry->vm,
> -                     __entry->ring, __entry->vmid, __entry->pd_addr)
> +           TP_printk("vm=%p, ring=%u, id=%u, pd_addr=%010Lx needs_flush=%u",
> +                     __entry->vm, __entry->ring, __entry->vmid,
> +                     __entry->pd_addr, __entry->needs_flush)
>  );
>
>  TRACE_EVENT(amdgpu_vm_bo_map,
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
> index 57337d4..60be154 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
> @@ -286,7 +286,7 @@ int amdgpu_vm_grab_id(struct amdgpu_vm *vm, struct amdgpu_ring *ring,
>
>                 job->vm_id = id - adev->vm_manager.ids;
>                 job->vm_needs_flush = false;
> -               trace_amdgpu_vm_grab_id(vm, ring->idx, job->vm_id, job->vm_pd_addr);
> +               trace_amdgpu_vm_grab_id(vm, ring->idx, job);
>
>                 mutex_unlock(&adev->vm_manager.lock);
>                 return 0;
> @@ -317,7 +317,7 @@ int amdgpu_vm_grab_id(struct amdgpu_vm *vm, struct amdgpu_ring *ring,
>         vm->ids[ring->idx] = id;
>
>         job->vm_id = id - adev->vm_manager.ids;
> -       trace_amdgpu_vm_grab_id(vm, ring->idx, job->vm_id, job->vm_pd_addr);
> +       trace_amdgpu_vm_grab_id(vm, ring->idx, job);
>
>  error:
>         mutex_unlock(&adev->vm_manager.lock);
> --
> 2.5.0
>
> _______________________________________________
> amd-gfx mailing list
> amd-gfx at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/amd-gfx


[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux