summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-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
-rw-r--r--drivers/gpu/nvgpu/gm20b/hal_gm20b.c1
-rw-r--r--drivers/gpu/nvgpu/gp106/hal_gp106.c1
-rw-r--r--drivers/gpu/nvgpu/gp10b/hal_gp10b.c1
-rw-r--r--drivers/gpu/nvgpu/gv100/hal_gv100.c1
-rw-r--r--drivers/gpu/nvgpu/gv11b/hal_gv11b.c1
-rw-r--r--drivers/gpu/nvgpu/vgpu/gp10b/vgpu_hal_gp10b.c1
-rw-r--r--drivers/gpu/nvgpu/vgpu/gv11b/vgpu_hal_gv11b.c1
10 files changed, 14 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);
diff --git a/drivers/gpu/nvgpu/gm20b/hal_gm20b.c b/drivers/gpu/nvgpu/gm20b/hal_gm20b.c
index b91795fa..f2ae97cf 100644
--- a/drivers/gpu/nvgpu/gm20b/hal_gm20b.c
+++ b/drivers/gpu/nvgpu/gm20b/hal_gm20b.c
@@ -438,6 +438,7 @@ static const struct gpu_ops gm20b_ops = {
438 .tsg_bind_channel = gk20a_tsg_bind_channel, 438 .tsg_bind_channel = gk20a_tsg_bind_channel,
439 .tsg_unbind_channel = gk20a_fifo_tsg_unbind_channel, 439 .tsg_unbind_channel = gk20a_fifo_tsg_unbind_channel,
440 .post_event_id = gk20a_tsg_event_id_post_event, 440 .post_event_id = gk20a_tsg_event_id_post_event,
441 .ch_abort_clean_up = gk20a_channel_abort_clean_up,
441#ifdef CONFIG_TEGRA_GK20A_NVHOST 442#ifdef CONFIG_TEGRA_GK20A_NVHOST
442 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf, 443 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf,
443 .free_syncpt_buf = gk20a_fifo_free_syncpt_buf, 444 .free_syncpt_buf = gk20a_fifo_free_syncpt_buf,
diff --git a/drivers/gpu/nvgpu/gp106/hal_gp106.c b/drivers/gpu/nvgpu/gp106/hal_gp106.c
index bfd1e99a..d87af8d3 100644
--- a/drivers/gpu/nvgpu/gp106/hal_gp106.c
+++ b/drivers/gpu/nvgpu/gp106/hal_gp106.c
@@ -499,6 +499,7 @@ static const struct gpu_ops gp106_ops = {
499 .tsg_bind_channel = gk20a_tsg_bind_channel, 499 .tsg_bind_channel = gk20a_tsg_bind_channel,
500 .tsg_unbind_channel = gk20a_fifo_tsg_unbind_channel, 500 .tsg_unbind_channel = gk20a_fifo_tsg_unbind_channel,
501 .post_event_id = gk20a_tsg_event_id_post_event, 501 .post_event_id = gk20a_tsg_event_id_post_event,
502 .ch_abort_clean_up = gk20a_channel_abort_clean_up,
502#ifdef CONFIG_TEGRA_GK20A_NVHOST 503#ifdef CONFIG_TEGRA_GK20A_NVHOST
503 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf, 504 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf,
504 .free_syncpt_buf = gk20a_fifo_free_syncpt_buf, 505 .free_syncpt_buf = gk20a_fifo_free_syncpt_buf,
diff --git a/drivers/gpu/nvgpu/gp10b/hal_gp10b.c b/drivers/gpu/nvgpu/gp10b/hal_gp10b.c
index a6a66f93..3461e184 100644
--- a/drivers/gpu/nvgpu/gp10b/hal_gp10b.c
+++ b/drivers/gpu/nvgpu/gp10b/hal_gp10b.c
@@ -470,6 +470,7 @@ static const struct gpu_ops gp10b_ops = {
470 .tsg_bind_channel = gk20a_tsg_bind_channel, 470 .tsg_bind_channel = gk20a_tsg_bind_channel,
471 .tsg_unbind_channel = gk20a_fifo_tsg_unbind_channel, 471 .tsg_unbind_channel = gk20a_fifo_tsg_unbind_channel,
472 .post_event_id = gk20a_tsg_event_id_post_event, 472 .post_event_id = gk20a_tsg_event_id_post_event,
473 .ch_abort_clean_up = gk20a_channel_abort_clean_up,
473#ifdef CONFIG_TEGRA_GK20A_NVHOST 474#ifdef CONFIG_TEGRA_GK20A_NVHOST
474 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf, 475 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf,
475 .free_syncpt_buf = gk20a_fifo_free_syncpt_buf, 476 .free_syncpt_buf = gk20a_fifo_free_syncpt_buf,
diff --git a/drivers/gpu/nvgpu/gv100/hal_gv100.c b/drivers/gpu/nvgpu/gv100/hal_gv100.c
index be9afd8b..8ddc538a 100644
--- a/drivers/gpu/nvgpu/gv100/hal_gv100.c
+++ b/drivers/gpu/nvgpu/gv100/hal_gv100.c
@@ -511,6 +511,7 @@ static const struct gpu_ops gv100_ops = {
511 .tsg_bind_channel = gk20a_tsg_bind_channel, 511 .tsg_bind_channel = gk20a_tsg_bind_channel,
512 .tsg_unbind_channel = gk20a_fifo_tsg_unbind_channel, 512 .tsg_unbind_channel = gk20a_fifo_tsg_unbind_channel,
513 .post_event_id = gk20a_tsg_event_id_post_event, 513 .post_event_id = gk20a_tsg_event_id_post_event,
514 .ch_abort_clean_up = gk20a_channel_abort_clean_up,
514#ifdef CONFIG_TEGRA_GK20A_NVHOST 515#ifdef CONFIG_TEGRA_GK20A_NVHOST
515 .alloc_syncpt_buf = gv11b_fifo_alloc_syncpt_buf, 516 .alloc_syncpt_buf = gv11b_fifo_alloc_syncpt_buf,
516 .free_syncpt_buf = gv11b_fifo_free_syncpt_buf, 517 .free_syncpt_buf = gv11b_fifo_free_syncpt_buf,
diff --git a/drivers/gpu/nvgpu/gv11b/hal_gv11b.c b/drivers/gpu/nvgpu/gv11b/hal_gv11b.c
index 2d4f82d1..9af5e96b 100644
--- a/drivers/gpu/nvgpu/gv11b/hal_gv11b.c
+++ b/drivers/gpu/nvgpu/gv11b/hal_gv11b.c
@@ -528,6 +528,7 @@ static const struct gpu_ops gv11b_ops = {
528 .tsg_bind_channel = gk20a_tsg_bind_channel, 528 .tsg_bind_channel = gk20a_tsg_bind_channel,
529 .tsg_unbind_channel = gk20a_fifo_tsg_unbind_channel, 529 .tsg_unbind_channel = gk20a_fifo_tsg_unbind_channel,
530 .post_event_id = gk20a_tsg_event_id_post_event, 530 .post_event_id = gk20a_tsg_event_id_post_event,
531 .ch_abort_clean_up = gk20a_channel_abort_clean_up,
531#ifdef CONFIG_TEGRA_GK20A_NVHOST 532#ifdef CONFIG_TEGRA_GK20A_NVHOST
532 .alloc_syncpt_buf = gv11b_fifo_alloc_syncpt_buf, 533 .alloc_syncpt_buf = gv11b_fifo_alloc_syncpt_buf,
533 .free_syncpt_buf = gv11b_fifo_free_syncpt_buf, 534 .free_syncpt_buf = gv11b_fifo_free_syncpt_buf,
diff --git a/drivers/gpu/nvgpu/vgpu/gp10b/vgpu_hal_gp10b.c b/drivers/gpu/nvgpu/vgpu/gp10b/vgpu_hal_gp10b.c
index 7156a29d..819ca852 100644
--- a/drivers/gpu/nvgpu/vgpu/gp10b/vgpu_hal_gp10b.c
+++ b/drivers/gpu/nvgpu/vgpu/gp10b/vgpu_hal_gp10b.c
@@ -344,6 +344,7 @@ static const struct gpu_ops vgpu_gp10b_ops = {
344 .tsg_bind_channel = vgpu_tsg_bind_channel, 344 .tsg_bind_channel = vgpu_tsg_bind_channel,
345 .tsg_unbind_channel = vgpu_tsg_unbind_channel, 345 .tsg_unbind_channel = vgpu_tsg_unbind_channel,
346 .post_event_id = gk20a_tsg_event_id_post_event, 346 .post_event_id = gk20a_tsg_event_id_post_event,
347 .ch_abort_clean_up = gk20a_channel_abort_clean_up,
347#ifdef CONFIG_TEGRA_GK20A_NVHOST 348#ifdef CONFIG_TEGRA_GK20A_NVHOST
348 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf, 349 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf,
349 .free_syncpt_buf = gk20a_fifo_free_syncpt_buf, 350 .free_syncpt_buf = gk20a_fifo_free_syncpt_buf,
diff --git a/drivers/gpu/nvgpu/vgpu/gv11b/vgpu_hal_gv11b.c b/drivers/gpu/nvgpu/vgpu/gv11b/vgpu_hal_gv11b.c
index 2c81607d..92d401e9 100644
--- a/drivers/gpu/nvgpu/vgpu/gv11b/vgpu_hal_gv11b.c
+++ b/drivers/gpu/nvgpu/vgpu/gv11b/vgpu_hal_gv11b.c
@@ -387,6 +387,7 @@ static const struct gpu_ops vgpu_gv11b_ops = {
387 .tsg_bind_channel = vgpu_gv11b_tsg_bind_channel, 387 .tsg_bind_channel = vgpu_gv11b_tsg_bind_channel,
388 .tsg_unbind_channel = vgpu_tsg_unbind_channel, 388 .tsg_unbind_channel = vgpu_tsg_unbind_channel,
389 .post_event_id = gk20a_tsg_event_id_post_event, 389 .post_event_id = gk20a_tsg_event_id_post_event,
390 .ch_abort_clean_up = gk20a_channel_abort_clean_up,
390#ifdef CONFIG_TEGRA_GK20A_NVHOST 391#ifdef CONFIG_TEGRA_GK20A_NVHOST
391 .alloc_syncpt_buf = vgpu_gv11b_fifo_alloc_syncpt_buf, 392 .alloc_syncpt_buf = vgpu_gv11b_fifo_alloc_syncpt_buf,
392 .free_syncpt_buf = gv11b_fifo_free_syncpt_buf, 393 .free_syncpt_buf = gv11b_fifo_free_syncpt_buf,