From: Samuel Pitoiset Date: Mon, 21 Jul 2014 09:59:44 +0000 (+0200) Subject: drm/nouveau/perfmon: do not forget to destroy the engine context X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=cbb4cf8bdffd943fa7cff724232b57b0e6891095;p=openwrt%2Fstaging%2Fblogic.git drm/nouveau/perfmon: do not forget to destroy the engine context This fixes a crash when we reload Nouveau DRM. Signed-off-by: Samuel Pitoiset Signed-off-by: Ben Skeggs --- diff --git a/drivers/gpu/drm/nouveau/core/engine/perfmon/base.c b/drivers/gpu/drm/nouveau/core/engine/perfmon/base.c index e9c5e51943ef..748100307bb6 100644 --- a/drivers/gpu/drm/nouveau/core/engine/perfmon/base.c +++ b/drivers/gpu/drm/nouveau/core/engine/perfmon/base.c @@ -303,6 +303,7 @@ nouveau_perfctx_dtor(struct nouveau_object *object) { struct nouveau_perfmon *ppm = (void *)object->engine; mutex_lock(&nv_subdev(ppm)->mutex); + nouveau_engctx_destroy(&ppm->context->base); ppm->context = NULL; mutex_unlock(&nv_subdev(ppm)->mutex); }