[PATCH] drm/nouveau/abi16: add missing mutex_unlock()

Saurabh Sengar saurabh.truth at gmail.com
Mon Nov 9 01:16:26 PST 2015


adding missing mutex_unlock()

Signed-off-by: Saurabh Sengar <saurabh.truth at gmail.com>
---
 drivers/gpu/drm/nouveau/nouveau_abi16.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/nouveau/nouveau_abi16.c b/drivers/gpu/drm/nouveau/nouveau_abi16.c
index d336c22..280bd8e 100644
--- a/drivers/gpu/drm/nouveau/nouveau_abi16.c
+++ b/drivers/gpu/drm/nouveau/nouveau_abi16.c
@@ -54,11 +54,11 @@ nouveau_abi16_get(struct drm_file *file_priv, struct drm_device *dev)
 			if (nvif_device_init(&cli->base.object,
 					     NOUVEAU_ABI16_DEVICE, NV_DEVICE,
 					     &args, sizeof(args),
-					     &abi16->device) == 0)
-				return cli->abi16;
+					     &abi16->device)) {
 
-			kfree(cli->abi16);
-			cli->abi16 = NULL;
+				kfree(cli->abi16);
+				cli->abi16 = NULL;
+			}
 		}
 
 		mutex_unlock(&cli->mutex);
-- 
1.9.1



More information about the dri-devel mailing list