diff options
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/gr_gk20a.c')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/gr_gk20a.c | 26 |
1 files changed, 25 insertions, 1 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c index 7e37a965..a10650be 100644 --- a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c | |||
@@ -56,6 +56,7 @@ | |||
56 | #include "debug_gk20a.h" | 56 | #include "debug_gk20a.h" |
57 | #include "semaphore_gk20a.h" | 57 | #include "semaphore_gk20a.h" |
58 | #include "platform_gk20a.h" | 58 | #include "platform_gk20a.h" |
59 | #include "ctxsw_trace_gk20a.h" | ||
59 | 60 | ||
60 | #define BLK_SIZE (256) | 61 | #define BLK_SIZE (256) |
61 | 62 | ||
@@ -2855,6 +2856,13 @@ int gk20a_alloc_obj_ctx(struct channel_gk20a *c, | |||
2855 | "fail to load golden ctx image"); | 2856 | "fail to load golden ctx image"); |
2856 | goto out; | 2857 | goto out; |
2857 | } | 2858 | } |
2859 | if (g->ops.fecs_trace.bind_channel) { | ||
2860 | err = g->ops.fecs_trace.bind_channel(g, c); | ||
2861 | if (err) { | ||
2862 | gk20a_warn(dev_from_gk20a(g), | ||
2863 | "fail to bind channel for ctxsw trace"); | ||
2864 | } | ||
2865 | } | ||
2858 | c->first_init = true; | 2866 | c->first_init = true; |
2859 | } | 2867 | } |
2860 | 2868 | ||
@@ -4217,7 +4225,15 @@ out: | |||
4217 | static void gr_gk20a_load_gating_prod(struct gk20a *g) | 4225 | static void gr_gk20a_load_gating_prod(struct gk20a *g) |
4218 | { | 4226 | { |
4219 | /* slcg prod values */ | 4227 | /* slcg prod values */ |
4220 | g->ops.clock_gating.slcg_gr_load_gating_prod(g, g->slcg_enabled); | 4228 | if (g->ops.clock_gating.slcg_bus_load_gating_prod) |
4229 | g->ops.clock_gating.slcg_bus_load_gating_prod(g, | ||
4230 | g->slcg_enabled); | ||
4231 | if (g->ops.clock_gating.slcg_chiplet_load_gating_prod) | ||
4232 | g->ops.clock_gating.slcg_chiplet_load_gating_prod(g, | ||
4233 | g->slcg_enabled); | ||
4234 | if (g->ops.clock_gating.slcg_gr_load_gating_prod) | ||
4235 | g->ops.clock_gating.slcg_gr_load_gating_prod(g, | ||
4236 | g->slcg_enabled); | ||
4221 | if (g->ops.clock_gating.slcg_ctxsw_firmware_load_gating_prod) | 4237 | if (g->ops.clock_gating.slcg_ctxsw_firmware_load_gating_prod) |
4222 | g->ops.clock_gating.slcg_ctxsw_firmware_load_gating_prod(g, | 4238 | g->ops.clock_gating.slcg_ctxsw_firmware_load_gating_prod(g, |
4223 | g->slcg_enabled); | 4239 | g->slcg_enabled); |
@@ -4227,6 +4243,12 @@ static void gr_gk20a_load_gating_prod(struct gk20a *g) | |||
4227 | g->slcg_enabled); | 4243 | g->slcg_enabled); |
4228 | 4244 | ||
4229 | /* blcg prod values */ | 4245 | /* blcg prod values */ |
4246 | if (g->ops.clock_gating.blcg_bus_load_gating_prod) | ||
4247 | g->ops.clock_gating.blcg_bus_load_gating_prod(g, | ||
4248 | g->blcg_enabled); | ||
4249 | if (g->ops.clock_gating.blcg_ce_load_gating_prod) | ||
4250 | g->ops.clock_gating.blcg_ce_load_gating_prod(g, | ||
4251 | g->blcg_enabled); | ||
4230 | g->ops.clock_gating.blcg_gr_load_gating_prod(g, g->blcg_enabled); | 4252 | g->ops.clock_gating.blcg_gr_load_gating_prod(g, g->blcg_enabled); |
4231 | if (g->ops.clock_gating.blcg_ctxsw_firmware_load_gating_prod) | 4253 | if (g->ops.clock_gating.blcg_ctxsw_firmware_load_gating_prod) |
4232 | g->ops.clock_gating.blcg_ctxsw_firmware_load_gating_prod(g, | 4254 | g->ops.clock_gating.blcg_ctxsw_firmware_load_gating_prod(g, |
@@ -7463,6 +7485,7 @@ static int gr_gk20a_dump_gr_status_regs(struct gk20a *g, | |||
7463 | return 0; | 7485 | return 0; |
7464 | } | 7486 | } |
7465 | 7487 | ||
7488 | #ifdef CONFIG_DEBUG_FS | ||
7466 | int gr_gk20a_debugfs_init(struct gk20a *g) | 7489 | int gr_gk20a_debugfs_init(struct gk20a *g) |
7467 | { | 7490 | { |
7468 | struct gk20a_platform *platform = platform_get_drvdata(g->dev); | 7491 | struct gk20a_platform *platform = platform_get_drvdata(g->dev); |
@@ -7474,6 +7497,7 @@ int gr_gk20a_debugfs_init(struct gk20a *g) | |||
7474 | 7497 | ||
7475 | return 0; | 7498 | return 0; |
7476 | } | 7499 | } |
7500 | #endif | ||
7477 | 7501 | ||
7478 | static void gr_gk20a_init_cyclestats(struct gk20a *g) | 7502 | static void gr_gk20a_init_cyclestats(struct gk20a *g) |
7479 | { | 7503 | { |