From: Ben Skeggs bskeggs@redhat.com
commit ea293f823a8805735d9e00124df81a8f448ed1ae upstream.
Fixes OOPS on boards with ANX9805 DP encoders.
Cc: stable@vger.kernel.org # 6.4+ Signed-off-by: Ben Skeggs bskeggs@redhat.com Reviewed-by: Karol Herbst kherbst@redhat.com Signed-off-by: Karol Herbst kherbst@redhat.com Link: https://patchwork.freedesktop.org/patch/msgid/20230719044051.6975-3-skeggsb@... Signed-off-by: Greg Kroah-Hartman gregkh@linuxfoundation.org --- drivers/gpu/drm/nouveau/dispnv50/disp.c | 4 ++++ 1 file changed, 4 insertions(+)
--- a/drivers/gpu/drm/nouveau/dispnv50/disp.c +++ b/drivers/gpu/drm/nouveau/dispnv50/disp.c @@ -1873,6 +1873,8 @@ nv50_pior_destroy(struct drm_encoder *en nvif_outp_dtor(&nv_encoder->outp);
drm_encoder_cleanup(encoder); + + mutex_destroy(&nv_encoder->dp.hpd_irq_lock); kfree(encoder); }
@@ -1917,6 +1919,8 @@ nv50_pior_create(struct drm_connector *c nv_encoder->i2c = ddc; nv_encoder->aux = aux;
+ mutex_init(&nv_encoder->dp.hpd_irq_lock); + encoder = to_drm_encoder(nv_encoder); encoder->possible_crtcs = dcbe->heads; encoder->possible_clones = 0;