From 97a58123e89882d2584f34fba57b7cfde387b333 Mon Sep 17 00:00:00 2001 From: Terje Bergstrom Date: Thu, 26 May 2016 15:32:43 -0700 Subject: gpu: nvgpu: Free unbound channels If a channel cannot be allocated a GPFIFO, its status will remain unbound. We still need to free the channel when the fd gets closed. Bug 1769481 Change-Id: I8a9170f431cfa98dcf9e3cbc082393f02d2203db Signed-off-by: Terje Bergstrom Reviewed-on: http://git-master/r/1154725 --- drivers/gpu/nvgpu/gk20a/channel_gk20a.c | 4 ---- 1 file changed, 4 deletions(-) (limited to 'drivers/gpu/nvgpu') diff --git a/drivers/gpu/nvgpu/gk20a/channel_gk20a.c b/drivers/gpu/nvgpu/gk20a/channel_gk20a.c index 02de1391..64a14f8e 100644 --- a/drivers/gpu/nvgpu/gk20a/channel_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/channel_gk20a.c @@ -894,9 +894,6 @@ static void gk20a_free_channel(struct channel_gk20a *ch) } mutex_unlock(&f->deferred_reset_mutex); - if (!ch->bound) - goto release; - if (!gk20a_channel_as_bound(ch)) goto unbind; @@ -985,7 +982,6 @@ unbind: mutex_unlock(&g->dbg_sessions_lock); -release: /* make sure we catch accesses of unopened channels in case * there's non-refcounted channel pointers hanging around */ ch->g = NULL; -- cgit v1.2.2