drm/nouveau/gr/gf100-: unlock mutex failing to create golden context
Subsystems (4)
PATCH 1/1 drm/nouveau/gr/gf100-: unlock mutex failing to create golden context
Do not return from gf100_gr_chan_new() with fecs mutex held when failing to create the golden context image.
Cc <[email protected]> # v6.2+
Fixes ca081fff6ecc ("drm/nouveau/gr/gf100-: generate golden context during first object alloc")
Signed-off-by Danilo Krummrich <[email protected]>
--- drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c | 1 + 1 file changed, 1 insertion(+)
drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c +1 -0
@@ -442,6 +442,7 @@ gf100_gr_chan_new(struct nvkm_gr *base, struct nvkm_chan *fifoch,if (gr->data ==NULL ) { ret =gf100_grctx_generate (gr, chan, fifoch->inst);if (ret) { +mutex_unlock (&gr->fecs.mutex);nvkm_error (&base->engine.subdev,"failed to construct context\n" );return ret; }
Signature · 1 line
2.41.0
Quoted 3 lines · Danilo Krummrich
Do not return from
gf100_gr_chan_new()with fecs mutex held when failing to create the golden context image.
Reviewed-by Dave Airlie <[email protected]>
Quoted 23 lines
Cc <[email protected]> # v6.2+Fixes ca081fff6ecc ("drm/nouveau/gr/gf100-: generate golden context during first object alloc")Signed-off-by Danilo Krummrich <[email protected]>--- drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c | 1 + 1 file changed, 1 insertion(+)drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c +1
-1@@ -442,6 +442,7 @@ gf100_gr_chan_new(struct nvkm_gr *base, struct nvkm_chan *fifoch,if (gr->data ==NULL ) { ret =gf100_grctx_generate (gr, chan, fifoch->inst);if (ret) { +mutex_unlock (&gr->fecs.mutex);nvkm_error (&base->engine.subdev,"failed to construct context\n" );return ret; } --2.41.0