summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/gpu/nvgpu/gk20a/gk20a.c11
-rw-r--r--drivers/gpu/nvgpu/gk20a/gk20a.h2
-rw-r--r--drivers/gpu/nvgpu/gm20b/hal_gm20b.c2
-rw-r--r--drivers/gpu/nvgpu/gp106/hal_gp106.c2
-rw-r--r--drivers/gpu/nvgpu/gp10b/hal_gp10b.c2
-rw-r--r--drivers/gpu/nvgpu/gv100/hal_gv100.c2
-rw-r--r--drivers/gpu/nvgpu/gv11b/hal_gv11b.c2
-rw-r--r--drivers/gpu/nvgpu/vgpu/gp10b/vgpu_hal_gp10b.c2
-rw-r--r--drivers/gpu/nvgpu/vgpu/gv11b/vgpu_hal_gv11b.c2
9 files changed, 23 insertions, 4 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gk20a.c b/drivers/gpu/nvgpu/gk20a/gk20a.c
index 0206c915..64ae4401 100644
--- a/drivers/gpu/nvgpu/gk20a/gk20a.c
+++ b/drivers/gpu/nvgpu/gk20a/gk20a.c
@@ -91,9 +91,11 @@ int gk20a_prepare_poweroff(struct gk20a *g)
91 91
92 gk20a_dbg_fn(""); 92 gk20a_dbg_fn("");
93 93
94 ret = gk20a_channel_suspend(g); 94 if (g->ops.fifo.channel_suspend) {
95 if (ret) 95 ret = g->ops.fifo.channel_suspend(g);
96 return ret; 96 if (ret)
97 return ret;
98 }
97 99
98 /* disable elpg before gr or fifo suspend */ 100 /* disable elpg before gr or fifo suspend */
99 if (g->ops.pmu.is_pmu_supported(g)) 101 if (g->ops.pmu.is_pmu_supported(g))
@@ -330,7 +332,8 @@ int gk20a_finalize_poweron(struct gk20a *g)
330 } 332 }
331#endif 333#endif
332 334
333 gk20a_channel_resume(g); 335 if (g->ops.fifo.channel_resume)
336 g->ops.fifo.channel_resume(g);
334 337
335 nvgpu_init_mm_ce_context(g); 338 nvgpu_init_mm_ce_context(g);
336 339
diff --git a/drivers/gpu/nvgpu/gk20a/gk20a.h b/drivers/gpu/nvgpu/gk20a/gk20a.h
index 76413600..c7653133 100644
--- a/drivers/gpu/nvgpu/gk20a/gk20a.h
+++ b/drivers/gpu/nvgpu/gk20a/gk20a.h
@@ -633,6 +633,8 @@ struct gpu_ops {
633 bool *verbose, u32 *ms); 633 bool *verbose, u32 *ms);
634 bool (*check_ch_ctxsw_timeout)(struct channel_gk20a *ch, 634 bool (*check_ch_ctxsw_timeout)(struct channel_gk20a *ch,
635 bool *verbose, u32 *ms); 635 bool *verbose, u32 *ms);
636 int (*channel_suspend)(struct gk20a *g);
637 int (*channel_resume)(struct gk20a *g);
636#ifdef CONFIG_TEGRA_GK20A_NVHOST 638#ifdef CONFIG_TEGRA_GK20A_NVHOST
637 int (*alloc_syncpt_buf)(struct channel_gk20a *c, 639 int (*alloc_syncpt_buf)(struct channel_gk20a *c,
638 u32 syncpt_id, struct nvgpu_mem *syncpt_buf); 640 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 fa493192..b41e07f9 100644
--- a/drivers/gpu/nvgpu/gm20b/hal_gm20b.c
+++ b/drivers/gpu/nvgpu/gm20b/hal_gm20b.c
@@ -441,6 +441,8 @@ static const struct gpu_ops gm20b_ops = {
441 .ch_abort_clean_up = gk20a_channel_abort_clean_up, 441 .ch_abort_clean_up = gk20a_channel_abort_clean_up,
442 .check_tsg_ctxsw_timeout = gk20a_fifo_check_tsg_ctxsw_timeout, 442 .check_tsg_ctxsw_timeout = gk20a_fifo_check_tsg_ctxsw_timeout,
443 .check_ch_ctxsw_timeout = gk20a_fifo_check_ch_ctxsw_timeout, 443 .check_ch_ctxsw_timeout = gk20a_fifo_check_ch_ctxsw_timeout,
444 .channel_suspend = gk20a_channel_suspend,
445 .channel_resume = gk20a_channel_resume,
444#ifdef CONFIG_TEGRA_GK20A_NVHOST 446#ifdef CONFIG_TEGRA_GK20A_NVHOST
445 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf, 447 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf,
446 .free_syncpt_buf = gk20a_fifo_free_syncpt_buf, 448 .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 892e71f7..2f3c1a5e 100644
--- a/drivers/gpu/nvgpu/gp106/hal_gp106.c
+++ b/drivers/gpu/nvgpu/gp106/hal_gp106.c
@@ -502,6 +502,8 @@ static const struct gpu_ops gp106_ops = {
502 .ch_abort_clean_up = gk20a_channel_abort_clean_up, 502 .ch_abort_clean_up = gk20a_channel_abort_clean_up,
503 .check_tsg_ctxsw_timeout = gk20a_fifo_check_tsg_ctxsw_timeout, 503 .check_tsg_ctxsw_timeout = gk20a_fifo_check_tsg_ctxsw_timeout,
504 .check_ch_ctxsw_timeout = gk20a_fifo_check_ch_ctxsw_timeout, 504 .check_ch_ctxsw_timeout = gk20a_fifo_check_ch_ctxsw_timeout,
505 .channel_suspend = gk20a_channel_suspend,
506 .channel_resume = gk20a_channel_resume,
505#ifdef CONFIG_TEGRA_GK20A_NVHOST 507#ifdef CONFIG_TEGRA_GK20A_NVHOST
506 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf, 508 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf,
507 .free_syncpt_buf = gk20a_fifo_free_syncpt_buf, 509 .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 4db7e557..9238c4d7 100644
--- a/drivers/gpu/nvgpu/gp10b/hal_gp10b.c
+++ b/drivers/gpu/nvgpu/gp10b/hal_gp10b.c
@@ -473,6 +473,8 @@ static const struct gpu_ops gp10b_ops = {
473 .ch_abort_clean_up = gk20a_channel_abort_clean_up, 473 .ch_abort_clean_up = gk20a_channel_abort_clean_up,
474 .check_tsg_ctxsw_timeout = gk20a_fifo_check_tsg_ctxsw_timeout, 474 .check_tsg_ctxsw_timeout = gk20a_fifo_check_tsg_ctxsw_timeout,
475 .check_ch_ctxsw_timeout = gk20a_fifo_check_ch_ctxsw_timeout, 475 .check_ch_ctxsw_timeout = gk20a_fifo_check_ch_ctxsw_timeout,
476 .channel_suspend = gk20a_channel_suspend,
477 .channel_resume = gk20a_channel_resume,
476#ifdef CONFIG_TEGRA_GK20A_NVHOST 478#ifdef CONFIG_TEGRA_GK20A_NVHOST
477 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf, 479 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf,
478 .free_syncpt_buf = gk20a_fifo_free_syncpt_buf, 480 .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 f3e25ddd..2f2d278e 100644
--- a/drivers/gpu/nvgpu/gv100/hal_gv100.c
+++ b/drivers/gpu/nvgpu/gv100/hal_gv100.c
@@ -514,6 +514,8 @@ static const struct gpu_ops gv100_ops = {
514 .ch_abort_clean_up = gk20a_channel_abort_clean_up, 514 .ch_abort_clean_up = gk20a_channel_abort_clean_up,
515 .check_tsg_ctxsw_timeout = gk20a_fifo_check_tsg_ctxsw_timeout, 515 .check_tsg_ctxsw_timeout = gk20a_fifo_check_tsg_ctxsw_timeout,
516 .check_ch_ctxsw_timeout = gk20a_fifo_check_ch_ctxsw_timeout, 516 .check_ch_ctxsw_timeout = gk20a_fifo_check_ch_ctxsw_timeout,
517 .channel_suspend = gk20a_channel_suspend,
518 .channel_resume = gk20a_channel_resume,
517#ifdef CONFIG_TEGRA_GK20A_NVHOST 519#ifdef CONFIG_TEGRA_GK20A_NVHOST
518 .alloc_syncpt_buf = gv11b_fifo_alloc_syncpt_buf, 520 .alloc_syncpt_buf = gv11b_fifo_alloc_syncpt_buf,
519 .free_syncpt_buf = gv11b_fifo_free_syncpt_buf, 521 .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 fbf8ad61..67b3adbf 100644
--- a/drivers/gpu/nvgpu/gv11b/hal_gv11b.c
+++ b/drivers/gpu/nvgpu/gv11b/hal_gv11b.c
@@ -531,6 +531,8 @@ static const struct gpu_ops gv11b_ops = {
531 .ch_abort_clean_up = gk20a_channel_abort_clean_up, 531 .ch_abort_clean_up = gk20a_channel_abort_clean_up,
532 .check_tsg_ctxsw_timeout = gk20a_fifo_check_tsg_ctxsw_timeout, 532 .check_tsg_ctxsw_timeout = gk20a_fifo_check_tsg_ctxsw_timeout,
533 .check_ch_ctxsw_timeout = gk20a_fifo_check_ch_ctxsw_timeout, 533 .check_ch_ctxsw_timeout = gk20a_fifo_check_ch_ctxsw_timeout,
534 .channel_suspend = gk20a_channel_suspend,
535 .channel_resume = gk20a_channel_resume,
534#ifdef CONFIG_TEGRA_GK20A_NVHOST 536#ifdef CONFIG_TEGRA_GK20A_NVHOST
535 .alloc_syncpt_buf = gv11b_fifo_alloc_syncpt_buf, 537 .alloc_syncpt_buf = gv11b_fifo_alloc_syncpt_buf,
536 .free_syncpt_buf = gv11b_fifo_free_syncpt_buf, 538 .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 8b8c630d..ab08e09d 100644
--- a/drivers/gpu/nvgpu/vgpu/gp10b/vgpu_hal_gp10b.c
+++ b/drivers/gpu/nvgpu/vgpu/gp10b/vgpu_hal_gp10b.c
@@ -347,6 +347,8 @@ static const struct gpu_ops vgpu_gp10b_ops = {
347 .ch_abort_clean_up = gk20a_channel_abort_clean_up, 347 .ch_abort_clean_up = gk20a_channel_abort_clean_up,
348 .check_tsg_ctxsw_timeout = gk20a_fifo_check_tsg_ctxsw_timeout, 348 .check_tsg_ctxsw_timeout = gk20a_fifo_check_tsg_ctxsw_timeout,
349 .check_ch_ctxsw_timeout = gk20a_fifo_check_ch_ctxsw_timeout, 349 .check_ch_ctxsw_timeout = gk20a_fifo_check_ch_ctxsw_timeout,
350 .channel_suspend = gk20a_channel_suspend,
351 .channel_resume = gk20a_channel_resume,
350#ifdef CONFIG_TEGRA_GK20A_NVHOST 352#ifdef CONFIG_TEGRA_GK20A_NVHOST
351 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf, 353 .alloc_syncpt_buf = gk20a_fifo_alloc_syncpt_buf,
352 .free_syncpt_buf = gk20a_fifo_free_syncpt_buf, 354 .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 5dbf6779..5e3af9d7 100644
--- a/drivers/gpu/nvgpu/vgpu/gv11b/vgpu_hal_gv11b.c
+++ b/drivers/gpu/nvgpu/vgpu/gv11b/vgpu_hal_gv11b.c
@@ -390,6 +390,8 @@ static const struct gpu_ops vgpu_gv11b_ops = {
390 .ch_abort_clean_up = gk20a_channel_abort_clean_up, 390 .ch_abort_clean_up = gk20a_channel_abort_clean_up,
391 .check_tsg_ctxsw_timeout = gk20a_fifo_check_tsg_ctxsw_timeout, 391 .check_tsg_ctxsw_timeout = gk20a_fifo_check_tsg_ctxsw_timeout,
392 .check_ch_ctxsw_timeout = gk20a_fifo_check_ch_ctxsw_timeout, 392 .check_ch_ctxsw_timeout = gk20a_fifo_check_ch_ctxsw_timeout,
393 .channel_suspend = gk20a_channel_suspend,
394 .channel_resume = gk20a_channel_resume,
393#ifdef CONFIG_TEGRA_GK20A_NVHOST 395#ifdef CONFIG_TEGRA_GK20A_NVHOST
394 .alloc_syncpt_buf = vgpu_gv11b_fifo_alloc_syncpt_buf, 396 .alloc_syncpt_buf = vgpu_gv11b_fifo_alloc_syncpt_buf,
395 .free_syncpt_buf = gv11b_fifo_free_syncpt_buf, 397 .free_syncpt_buf = gv11b_fifo_free_syncpt_buf,