summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gk20a/gr_gk20a.c
diff options
context:
space:
mode:
authorSeema Khowala <seemaj@nvidia.com>2017-07-09 17:05:57 -0400
committermobile promotions <svcmobile_promotions@nvidia.com>2017-07-10 02:34:19 -0400
commit3bc7e4aaddd2487ab65f66caa80cc0795b522fb6 (patch)
treeb049deb689209b34fc0192c1eecbf351386d9af6 /drivers/gpu/nvgpu/gk20a/gr_gk20a.c
parent961e98aa11d11e46c57318cd9c8a3b4b41ede7a2 (diff)
gpu: nvgpu: fix tpc exception enablement
Use read modify write to enable sm exception. This is to avoid disabling alredy enabled interrupts e.g. tex etc. JIRA GPUT19X-69 Change-Id: I94f75f9a37310a8271193b4996e9b4b2ba29e4ae Signed-off-by: Seema Khowala <seemaj@nvidia.com> Reviewed-on: https://git-master/r/1515914 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Vijayakumar Subbu <vsubbu@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/gr_gk20a.c')
-rw-r--r--drivers/gpu/nvgpu/gk20a/gr_gk20a.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c
index c935809e..80dca77a 100644
--- a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c
+++ b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c
@@ -8398,14 +8398,16 @@ int gr_gk20a_wait_for_pause(struct gk20a *g, struct warpstate *w_state)
8398int gr_gk20a_resume_from_pause(struct gk20a *g) 8398int gr_gk20a_resume_from_pause(struct gk20a *g)
8399{ 8399{
8400 int err = 0; 8400 int err = 0;
8401 u32 reg_val;
8401 8402
8402 /* Clear the pause mask to tell the GPU we want to resume everyone */ 8403 /* Clear the pause mask to tell the GPU we want to resume everyone */
8403 gk20a_writel(g, 8404 gk20a_writel(g,
8404 gr_gpcs_tpcs_sm_dbgr_bpt_pause_mask_r(), 0); 8405 gr_gpcs_tpcs_sm_dbgr_bpt_pause_mask_r(), 0);
8405 8406
8406 /* explicitly re-enable forwarding of SM interrupts upon any resume */ 8407 /* explicitly re-enable forwarding of SM interrupts upon any resume */
8407 gk20a_writel(g, gr_gpcs_tpcs_tpccs_tpc_exception_en_r(), 8408 reg_val = gk20a_readl(g, gr_gpc0_tpc0_tpccs_tpc_exception_en_r());
8408 gr_gpcs_tpcs_tpccs_tpc_exception_en_sm_enabled_f()); 8409 reg_val |= gr_gpc0_tpc0_tpccs_tpc_exception_en_sm_enabled_f();
8410 gk20a_writel(g, gr_gpcs_tpcs_tpccs_tpc_exception_en_r(), reg_val);
8409 8411
8410 /* Now resume all sms, write a 0 to the stop trigger 8412 /* Now resume all sms, write a 0 to the stop trigger
8411 * then a 1 to the run trigger */ 8413 * then a 1 to the run trigger */