diff options
author | seshendra Gadagottu <sgadagottu@nvidia.com> | 2018-03-26 18:18:34 -0400 |
---|---|---|
committer | mobile promotions <svcmobile_promotions@nvidia.com> | 2018-04-03 20:05:08 -0400 |
commit | 0ccb0bfc8790dffd583ec744fc4cb7d110812575 (patch) | |
tree | aadeda49914042d4d6faa75f5c2f7121160dbdd9 /drivers/gpu | |
parent | 4b8432a663e12c915acec9043ab8493b30471188 (diff) |
gpu: nvgpu: initialize ctxsw state for golden context creation
If golden context creation happens before any gpu railgate then
channel creation is always fine. If gpu railgate happens after gpu
finalize poweon, but before golden context creation, then golden
context creation is failing during first channel creation with
watchdog timeout from ctxsw because of invalid ctxsw state.
To Fix this issue, if the golden context is not created, then during
finalize power on always query ctxsw image sizes, which is making ctxsw
hw in correct state before golden context creation.
Bug 2051863
Change-Id: I81d221100a099b12bad3adc2d252de4621c335a5
Signed-off-by: seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1682265
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/gr_gk20a.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c index ceb606e4..c6a58fec 100644 --- a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c | |||
@@ -2467,7 +2467,8 @@ int gr_gk20a_init_ctx_state(struct gk20a *g) | |||
2467 | }; | 2467 | }; |
2468 | 2468 | ||
2469 | gk20a_dbg_fn(""); | 2469 | gk20a_dbg_fn(""); |
2470 | if (!g->gr.ctx_vars.golden_image_size) { | 2470 | /* query ctxsw image sizes, if golden context is not created */ |
2471 | if (!g->gr.ctx_vars.golden_image_initialized) { | ||
2471 | op.method.addr = | 2472 | op.method.addr = |
2472 | gr_fecs_method_push_adr_discover_image_size_v(); | 2473 | gr_fecs_method_push_adr_discover_image_size_v(); |
2473 | op.mailbox.ret = &g->gr.ctx_vars.golden_image_size; | 2474 | op.mailbox.ret = &g->gr.ctx_vars.golden_image_size; |