summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gk20a
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a')
-rw-r--r--drivers/gpu/nvgpu/gk20a/channel_gk20a.c3
-rw-r--r--drivers/gpu/nvgpu/gk20a/fifo_gk20a.c6
-rw-r--r--drivers/gpu/nvgpu/gk20a/gk20a.h1
3 files changed, 7 insertions, 3 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/channel_gk20a.c b/drivers/gpu/nvgpu/gk20a/channel_gk20a.c
index bd4e2ff8..e3d9b53a 100644
--- a/drivers/gpu/nvgpu/gk20a/channel_gk20a.c
+++ b/drivers/gpu/nvgpu/gk20a/channel_gk20a.c
@@ -220,7 +220,8 @@ void gk20a_channel_abort(struct channel_gk20a *ch, bool channel_preempt)
220 if (channel_preempt && gk20a_is_channel_marked_as_tsg(ch)) 220 if (channel_preempt && gk20a_is_channel_marked_as_tsg(ch))
221 ch->g->ops.fifo.preempt_channel(ch->g, ch->chid); 221 ch->g->ops.fifo.preempt_channel(ch->g, ch->chid);
222 222
223 gk20a_channel_abort_clean_up(ch); 223 if (ch->g->ops.fifo.ch_abort_clean_up)
224 ch->g->ops.fifo.ch_abort_clean_up(ch);
224} 225}
225 226
226int gk20a_wait_channel_idle(struct channel_gk20a *ch) 227int gk20a_wait_channel_idle(struct channel_gk20a *ch)
diff --git a/drivers/gpu/nvgpu/gk20a/fifo_gk20a.c b/drivers/gpu/nvgpu/gk20a/fifo_gk20a.c
index 6a7afad7..f069b193 100644
--- a/drivers/gpu/nvgpu/gk20a/fifo_gk20a.c
+++ b/drivers/gpu/nvgpu/gk20a/fifo_gk20a.c
@@ -1432,7 +1432,8 @@ void gk20a_fifo_abort_tsg(struct gk20a *g, u32 tsgid, bool preempt)
1432 nvgpu_list_for_each_entry(ch, &tsg->ch_list, channel_gk20a, ch_entry) { 1432 nvgpu_list_for_each_entry(ch, &tsg->ch_list, channel_gk20a, ch_entry) {
1433 if (gk20a_channel_get(ch)) { 1433 if (gk20a_channel_get(ch)) {
1434 ch->has_timedout = true; 1434 ch->has_timedout = true;
1435 gk20a_channel_abort_clean_up(ch); 1435 if (ch->g->ops.fifo.ch_abort_clean_up)
1436 ch->g->ops.fifo.ch_abort_clean_up(ch);
1436 gk20a_channel_put(ch); 1437 gk20a_channel_put(ch);
1437 } 1438 }
1438 } 1439 }
@@ -2016,7 +2017,8 @@ int gk20a_fifo_tsg_unbind_channel(struct channel_gk20a *ch)
2016 if (!tsg_timedout) 2017 if (!tsg_timedout)
2017 g->ops.fifo.enable_tsg(tsg); 2018 g->ops.fifo.enable_tsg(tsg);
2018 2019
2019 gk20a_channel_abort_clean_up(ch); 2020 if (ch->g->ops.fifo.ch_abort_clean_up)
2021 ch->g->ops.fifo.ch_abort_clean_up(ch);
2020 2022
2021 return 0; 2023 return 0;
2022 2024
diff --git a/drivers/gpu/nvgpu/gk20a/gk20a.h b/drivers/gpu/nvgpu/gk20a/gk20a.h
index 7162dc73..43284ba5 100644
--- a/drivers/gpu/nvgpu/gk20a/gk20a.h
+++ b/drivers/gpu/nvgpu/gk20a/gk20a.h
@@ -628,6 +628,7 @@ struct gpu_ops {
628 struct tsg_gk20a *tsg); 628 struct tsg_gk20a *tsg);
629 u32 (*get_preempt_timeout)(struct gk20a *g); 629 u32 (*get_preempt_timeout)(struct gk20a *g);
630 void (*post_event_id)(struct tsg_gk20a *tsg, int event_id); 630 void (*post_event_id)(struct tsg_gk20a *tsg, int event_id);
631 void (*ch_abort_clean_up)(struct channel_gk20a *ch);
631#ifdef CONFIG_TEGRA_GK20A_NVHOST 632#ifdef CONFIG_TEGRA_GK20A_NVHOST
632 int (*alloc_syncpt_buf)(struct channel_gk20a *c, 633 int (*alloc_syncpt_buf)(struct channel_gk20a *c,
633 u32 syncpt_id, struct nvgpu_mem *syncpt_buf); 634 u32 syncpt_id, struct nvgpu_mem *syncpt_buf);