Skip to content

Commit

Permalink
drm/nouveau: hold mutex when calling nouveau_abi16_fini()
Browse files Browse the repository at this point in the history
commit ac8c793 upstream.

This was the only access to cli->abi16 without holding the mutex.

Signed-off-by: Kamil Dudka <kdudka@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Kamil Dudka authored and Greg Kroah-Hartman committed Aug 10, 2015
1 parent 140d4ba commit 53f092a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/gpu/drm/nouveau/nouveau_drm.c
Original file line number Diff line number Diff line change
Expand Up @@ -863,8 +863,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);
Expand Down

0 comments on commit 53f092a

Please sign in to comment.