summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c')
-rw-r--r--drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c b/drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c
index 3682d904..aadbf7af 100644
--- a/drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c
+++ b/drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c
@@ -656,7 +656,6 @@ void gk20a_ctxsw_trace_channel_reset(struct gk20a *g, struct channel_gk20a *ch)
656 struct nvgpu_ctxsw_trace_entry entry = { 656 struct nvgpu_ctxsw_trace_entry entry = {
657 .vmid = 0, 657 .vmid = 0,
658 .tag = NVGPU_CTXSW_TAG_ENGINE_RESET, 658 .tag = NVGPU_CTXSW_TAG_ENGINE_RESET,
659 .timestamp = gk20a_read_ptimer(g),
660 .context_id = 0, 659 .context_id = 0,
661 .pid = ch->pid, 660 .pid = ch->pid,
662 }; 661 };
@@ -664,6 +663,7 @@ void gk20a_ctxsw_trace_channel_reset(struct gk20a *g, struct channel_gk20a *ch)
664 if (!g->ctxsw_trace) 663 if (!g->ctxsw_trace)
665 return; 664 return;
666 665
666 g->ops.read_ptimer(g, &entry.timestamp);
667 gk20a_ctxsw_trace_write(g, &entry); 667 gk20a_ctxsw_trace_write(g, &entry);
668 gk20a_ctxsw_trace_wake_up(g, 0); 668 gk20a_ctxsw_trace_wake_up(g, 0);
669#endif 669#endif
@@ -676,7 +676,6 @@ void gk20a_ctxsw_trace_tsg_reset(struct gk20a *g, struct tsg_gk20a *tsg)
676 struct nvgpu_ctxsw_trace_entry entry = { 676 struct nvgpu_ctxsw_trace_entry entry = {
677 .vmid = 0, 677 .vmid = 0,
678 .tag = NVGPU_CTXSW_TAG_ENGINE_RESET, 678 .tag = NVGPU_CTXSW_TAG_ENGINE_RESET,
679 .timestamp = gk20a_read_ptimer(g),
680 .context_id = 0, 679 .context_id = 0,
681 .pid = 0, 680 .pid = 0,
682 }; 681 };
@@ -685,6 +684,7 @@ void gk20a_ctxsw_trace_tsg_reset(struct gk20a *g, struct tsg_gk20a *tsg)
685 if (!g->ctxsw_trace) 684 if (!g->ctxsw_trace)
686 return; 685 return;
687 686
687 g->ops.read_ptimer(g, &entry.timestamp);
688 mutex_lock(&tsg->ch_list_lock); 688 mutex_lock(&tsg->ch_list_lock);
689 if (!list_empty(&tsg->ch_list)) { 689 if (!list_empty(&tsg->ch_list)) {
690 ch = list_entry(tsg->ch_list.next, 690 ch = list_entry(tsg->ch_list.next,