summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gk20a/channel_gk20a.c
diff options
context:
space:
mode:
authorDeepak Nibade <dnibade@nvidia.com>2016-01-11 10:11:07 -0500
committerSachin Nikam <snikam@nvidia.com>2016-01-13 02:22:36 -0500
commitf7285577d7948115ff38c83982eb3b126302b195 (patch)
tree2c8758c57c8ab78acdec885fe1bd345bcc6fb6b5 /drivers/gpu/nvgpu/gk20a/channel_gk20a.c
parente8ebe36a2558d8a71e292986e2f286e94ed7da0a (diff)
gpu: nvgpu: enable wdt for each channel open
We currently enable per-channel wdt flag at channel initialization time only But if process disables channel's wdt via per-channel IOCTL, and closes the channel without re-enabling it, we leave the wdt disabled on that channel And if same channel is assigned to some other process, then that process might have wdt disabled already Fix this by setting ch->wdt_enabled = true during gk20a_open_new_channel() Bug 200165797 Change-Id: I3ab482ce7cfbcbbd2178041f01f97457ff24f7bb Signed-off-by: Deepak Nibade <dnibade@nvidia.com> Reviewed-on: http://git-master/r/931128 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Sachin Nikam <snikam@nvidia.com> Tested-by: Sachin Nikam <snikam@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/channel_gk20a.c')
-rw-r--r--drivers/gpu/nvgpu/gk20a/channel_gk20a.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/channel_gk20a.c b/drivers/gpu/nvgpu/gk20a/channel_gk20a.c
index 444fec13..2ec1ffe4 100644
--- a/drivers/gpu/nvgpu/gk20a/channel_gk20a.c
+++ b/drivers/gpu/nvgpu/gk20a/channel_gk20a.c
@@ -1141,6 +1141,7 @@ struct channel_gk20a *gk20a_open_new_channel(struct gk20a *g)
1141 ch->timeout_ms_max = gk20a_get_gr_idle_timeout(g); 1141 ch->timeout_ms_max = gk20a_get_gr_idle_timeout(g);
1142 ch->timeout_debug_dump = true; 1142 ch->timeout_debug_dump = true;
1143 ch->has_timedout = false; 1143 ch->has_timedout = false;
1144 ch->wdt_enabled = true;
1144 ch->obj_class = 0; 1145 ch->obj_class = 0;
1145 ch->interleave = false; 1146 ch->interleave = false;
1146 gk20a_fifo_set_channel_priority( 1147 gk20a_fifo_set_channel_priority(
@@ -2231,7 +2232,6 @@ int gk20a_init_channel_support(struct gk20a *g, u32 chid)
2231 c->g = NULL; 2232 c->g = NULL;
2232 c->hw_chid = chid; 2233 c->hw_chid = chid;
2233 c->bound = false; 2234 c->bound = false;
2234 c->wdt_enabled = true;
2235 spin_lock_init(&c->ref_obtain_lock); 2235 spin_lock_init(&c->ref_obtain_lock);
2236 atomic_set(&c->ref_count, 0); 2236 atomic_set(&c->ref_count, 0);
2237 c->referenceable = false; 2237 c->referenceable = false;