diff options
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/cde_gk20a.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/cde_gk20a.c b/drivers/gpu/nvgpu/gk20a/cde_gk20a.c index d2384257..f3185dd9 100644 --- a/drivers/gpu/nvgpu/gk20a/cde_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/cde_gk20a.c | |||
@@ -759,7 +759,8 @@ __releases(&cde_app->mutex) | |||
759 | 759 | ||
760 | mutex_lock(&cde_app->mutex); | 760 | mutex_lock(&cde_app->mutex); |
761 | 761 | ||
762 | WARN(!cde_ctx->in_use, "double release cde context %p", cde_ctx); | 762 | if (!cde_ctx->in_use) |
763 | gk20a_dbg_info("double release cde context %p", cde_ctx); | ||
763 | 764 | ||
764 | cde_ctx->in_use = false; | 765 | cde_ctx->in_use = false; |
765 | list_move(&cde_ctx->list, &cde_app->free_contexts); | 766 | list_move(&cde_ctx->list, &cde_app->free_contexts); |
@@ -1073,8 +1074,9 @@ __releases(&cde_app->mutex) | |||
1073 | 1074 | ||
1074 | trace_gk20a_cde_finished_ctx_cb(cde_ctx); | 1075 | trace_gk20a_cde_finished_ctx_cb(cde_ctx); |
1075 | gk20a_dbg(gpu_dbg_fn | gpu_dbg_cde_ctx, "cde: finished %p", cde_ctx); | 1076 | gk20a_dbg(gpu_dbg_fn | gpu_dbg_cde_ctx, "cde: finished %p", cde_ctx); |
1076 | WARN(!cde_ctx->in_use, "double finish cde context %p on channel %p", | 1077 | if (!cde_ctx->in_use) |
1077 | cde_ctx, ch); | 1078 | gk20a_dbg_info("double finish cde context %p on channel %p", |
1079 | cde_ctx, ch); | ||
1078 | 1080 | ||
1079 | if (ch->has_timedout) { | 1081 | if (ch->has_timedout) { |
1080 | if (cde_ctx->is_temporary) { | 1082 | if (cde_ctx->is_temporary) { |
@@ -1097,8 +1099,8 @@ __releases(&cde_app->mutex) | |||
1097 | } | 1099 | } |
1098 | } | 1100 | } |
1099 | 1101 | ||
1100 | /* delete temporary contexts later */ | 1102 | /* delete temporary contexts later (watch for doubles) */ |
1101 | if (cde_ctx->is_temporary) { | 1103 | if (cde_ctx->is_temporary && cde_ctx->in_use) { |
1102 | WARN_ON(delayed_work_pending(&cde_ctx->ctx_deleter_work)); | 1104 | WARN_ON(delayed_work_pending(&cde_ctx->ctx_deleter_work)); |
1103 | schedule_delayed_work(&cde_ctx->ctx_deleter_work, | 1105 | schedule_delayed_work(&cde_ctx->ctx_deleter_work, |
1104 | msecs_to_jiffies(CTX_DELETE_TIME)); | 1106 | msecs_to_jiffies(CTX_DELETE_TIME)); |