diff options
Diffstat (limited to 'drivers/gpu/nvgpu')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/dbg_gpu_gk20a.c | 4 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/gk20a.c | 2 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/gk20a.h | 2 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/regops_gk20a.c | 2 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/gp10b/hal_gp10b.c | 2 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/vgpu/vgpu.c | 2 |
6 files changed, 9 insertions, 5 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/dbg_gpu_gk20a.c b/drivers/gpu/nvgpu/gk20a/dbg_gpu_gk20a.c index 2988fdec..e4bdd8e3 100644 --- a/drivers/gpu/nvgpu/gk20a/dbg_gpu_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/dbg_gpu_gk20a.c | |||
@@ -1185,7 +1185,7 @@ static int nvgpu_ioctl_channel_reg_ops(struct dbg_session_gk20a *dbg_s, | |||
1185 | } | 1185 | } |
1186 | 1186 | ||
1187 | /* be sure that ctx info is in place */ | 1187 | /* be sure that ctx info is in place */ |
1188 | if (!gk20a_gpu_is_virtual(dbg_s->dev) && | 1188 | if (!g->is_virtual && |
1189 | !gr_context_info_available(dbg_s, &g->gr)) { | 1189 | !gr_context_info_available(dbg_s, &g->gr)) { |
1190 | nvgpu_err(g, "gr context data not available\n"); | 1190 | nvgpu_err(g, "gr context data not available\n"); |
1191 | return -ENODEV; | 1191 | return -ENODEV; |
@@ -1196,7 +1196,7 @@ static int nvgpu_ioctl_channel_reg_ops(struct dbg_session_gk20a *dbg_s, | |||
1196 | * on other channels */ | 1196 | * on other channels */ |
1197 | nvgpu_mutex_acquire(&g->dbg_sessions_lock); | 1197 | nvgpu_mutex_acquire(&g->dbg_sessions_lock); |
1198 | 1198 | ||
1199 | if (!dbg_s->is_pg_disabled && !gk20a_gpu_is_virtual(dbg_s->dev)) { | 1199 | if (!dbg_s->is_pg_disabled && !g->is_virtual) { |
1200 | /* In the virtual case, the server will handle | 1200 | /* In the virtual case, the server will handle |
1201 | * disabling/enabling powergating when processing reg ops | 1201 | * disabling/enabling powergating when processing reg ops |
1202 | */ | 1202 | */ |
diff --git a/drivers/gpu/nvgpu/gk20a/gk20a.c b/drivers/gpu/nvgpu/gk20a/gk20a.c index 51b0ba11..8ea2929f 100644 --- a/drivers/gpu/nvgpu/gk20a/gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/gk20a.c | |||
@@ -379,7 +379,7 @@ void gk20a_driver_start_unload(struct gk20a *g) | |||
379 | g->driver_is_dying = 1; | 379 | g->driver_is_dying = 1; |
380 | up_write(&g->busy_lock); | 380 | up_write(&g->busy_lock); |
381 | 381 | ||
382 | if (gk20a_gpu_is_virtual(g->dev)) | 382 | if (g->is_virtual) |
383 | return; | 383 | return; |
384 | 384 | ||
385 | gk20a_wait_for_idle(g->dev); | 385 | gk20a_wait_for_idle(g->dev); |
diff --git a/drivers/gpu/nvgpu/gk20a/gk20a.h b/drivers/gpu/nvgpu/gk20a/gk20a.h index 7ac1d909..c8d06b4f 100644 --- a/drivers/gpu/nvgpu/gk20a/gk20a.h +++ b/drivers/gpu/nvgpu/gk20a/gk20a.h | |||
@@ -1017,6 +1017,8 @@ struct gk20a { | |||
1017 | 1017 | ||
1018 | bool support_pmu; | 1018 | bool support_pmu; |
1019 | 1019 | ||
1020 | bool is_virtual; | ||
1021 | |||
1020 | u32 emc3d_ratio; | 1022 | u32 emc3d_ratio; |
1021 | 1023 | ||
1022 | #ifdef CONFIG_DEBUG_FS | 1024 | #ifdef CONFIG_DEBUG_FS |
diff --git a/drivers/gpu/nvgpu/gk20a/regops_gk20a.c b/drivers/gpu/nvgpu/gk20a/regops_gk20a.c index bc64dbac..c4b357b1 100644 --- a/drivers/gpu/nvgpu/gk20a/regops_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/regops_gk20a.c | |||
@@ -401,7 +401,7 @@ int exec_regops_gk20a(struct dbg_session_gk20a *dbg_s, | |||
401 | * regops implementation, so we return -ENOSYS. This will allow | 401 | * regops implementation, so we return -ENOSYS. This will allow |
402 | * compute apps to run with vgpu. Tools will not work in this | 402 | * compute apps to run with vgpu. Tools will not work in this |
403 | * configuration and are not required to work at this time. */ | 403 | * configuration and are not required to work at this time. */ |
404 | if (gk20a_gpu_is_virtual(dbg_s->dev)) | 404 | if (g->is_virtual) |
405 | return -ENOSYS; | 405 | return -ENOSYS; |
406 | 406 | ||
407 | ok = validate_reg_ops(dbg_s, | 407 | ok = validate_reg_ops(dbg_s, |
diff --git a/drivers/gpu/nvgpu/gp10b/hal_gp10b.c b/drivers/gpu/nvgpu/gp10b/hal_gp10b.c index e8cd6a71..40e49e13 100644 --- a/drivers/gpu/nvgpu/gp10b/hal_gp10b.c +++ b/drivers/gpu/nvgpu/gp10b/hal_gp10b.c | |||
@@ -198,7 +198,7 @@ int gp10b_init_hal(struct gk20a *g) | |||
198 | if (g->is_fmodel) { | 198 | if (g->is_fmodel) { |
199 | gops->privsecurity = 0; | 199 | gops->privsecurity = 0; |
200 | gops->securegpccs = 0; | 200 | gops->securegpccs = 0; |
201 | } else if (gk20a_gpu_is_virtual(g->dev)) { | 201 | } else if (g->is_virtual) { |
202 | gops->privsecurity = 1; | 202 | gops->privsecurity = 1; |
203 | gops->securegpccs = 1; | 203 | gops->securegpccs = 1; |
204 | } else { | 204 | } else { |
diff --git a/drivers/gpu/nvgpu/vgpu/vgpu.c b/drivers/gpu/nvgpu/vgpu/vgpu.c index 0f1fa814..d8ec1cbb 100644 --- a/drivers/gpu/nvgpu/vgpu/vgpu.c +++ b/drivers/gpu/nvgpu/vgpu/vgpu.c | |||
@@ -583,6 +583,8 @@ int vgpu_probe(struct platform_device *pdev) | |||
583 | if (tegra_platform_is_linsim() || tegra_platform_is_vdk()) | 583 | if (tegra_platform_is_linsim() || tegra_platform_is_vdk()) |
584 | gk20a->is_fmodel = true; | 584 | gk20a->is_fmodel = true; |
585 | 585 | ||
586 | gk20a->is_virtual = true; | ||
587 | |||
586 | nvgpu_kmem_init(gk20a); | 588 | nvgpu_kmem_init(gk20a); |
587 | 589 | ||
588 | priv = nvgpu_kzalloc(gk20a, sizeof(*priv)); | 590 | priv = nvgpu_kzalloc(gk20a, sizeof(*priv)); |