Skip to contentSkip to conversation

perfmon: do not forget to destroy the engine context

PATCH In review Samuel Pitoiset 2 participants 2 messages Jul 21, 2014 – Aug 4, 2014 1 message not in the archive

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 perfmon: do not forget to destroy the engine context

This fixes a crash when we reload Nouveau DRM.

---
 nvkm/engine/perfmon/base.c | 1 +
 1 file changed, 1 insertion(+)
nvkm/engine/perfmon/base.c +1 -0
index e9c5e51..7481003 100644
@@ -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);
 }
Signature · 1 line
2.0.0

A message that is not in the archive (sent off-list or not yet received): 1405936784-1696-1-git-send-email-samuel.pitoiset-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org

#2 lore raw
Quoted 1 line · Samuel Pitoiset

This fixes a crash when we reload Nouveau DRM.

Thanks Samuel :)

Quoted 25 lines
---
 nvkm/engine/perfmon/base.c | 1 +
 1 file changed, 1 insertion(+)
nvkm/engine/perfmon/base.c +1 -1
index e9c5e51..7481003 100644
@@ -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);
 }
--

2.0.0

_______________________________________________
Nouveau mailing list [email protected]
http://lists.freedesktop.org/mailman/listinfo/nouveau