summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/nouveau
diff options
context:
space:
mode:
authorKamil Dudka <kdudka@redhat.com>2015-07-15 17:18:15 +0200
committerBen Skeggs <bskeggs@redhat.com>2015-07-27 18:56:07 +1000
commitac8c79304280da6ef05c348a9da03ab04898b994 (patch)
tree2b682f542de7df64f0503095332d931b2b2365c2 /drivers/gpu/drm/nouveau
parentcbfe8fa6cd672011c755c3cd85c9ffd4e2d10a6f (diff)
drm/nouveau: hold mutex when calling nouveau_abi16_fini()
This was the only access to cli->abi16 without holding the mutex. Signed-off-by: Kamil Dudka <kdudka@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau')
-rw-r--r--drivers/gpu/drm/nouveau/nouveau_drm.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_drm.c b/drivers/gpu/drm/nouveau/nouveau_drm.c
index 649024d4daf1..01c78a4a3efa 100644
--- a/drivers/gpu/drm/nouveau/nouveau_drm.c
+++ b/drivers/gpu/drm/nouveau/nouveau_drm.c
@@ -865,8 +865,10 @@ nouveau_drm_preclose(struct drm_device *dev, struct drm_file *fpriv)
pm_runtime_get_sync(dev->dev);
+ mutex_lock(&cli->mutex);
if (cli->abi16)
nouveau_abi16_fini(cli->abi16);
+ mutex_unlock(&cli->mutex);
mutex_lock(&drm->client.mutex);
list_del(&cli->head);