drm/nouveau: fix reference count leak in nv50_disp_atomic_commit
authorAditya Pakki <pakki001@umn.edu>
Sun, 14 Jun 2020 01:29:18 +0000 (20:29 -0500)
committerBen Skeggs <bskeggs@redhat.com>
Fri, 24 Jul 2020 08:50:49 +0000 (18:50 +1000)
commita2cdf39536b0d21fb06113f5e16692513d7bcb9c
tree8d8ee7d895b297a4adc718850b72c9cca8af85d1
parent659fb5f154c3434c90a34586f3b7aa1c39cf6062
drm/nouveau: fix reference count leak in nv50_disp_atomic_commit

nv50_disp_atomic_commit() calls calls pm_runtime_get_sync and in turn
increments the reference count. In case of failure, decrement the
ref count before returning the error.

Signed-off-by: Aditya Pakki <pakki001@umn.edu>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
drivers/gpu/drm/nouveau/dispnv50/disp.c