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
This was the only access to cli->abi16 without holding the mutex.

Signed-off-by: Kamil Dudka <kdudka@redhat.com>
  • Loading branch information
Kamil Dudka authored and Ben Skeggs committed Jul 27, 2015
1 parent cbfe8fa commit ac8c793
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 @@ -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);
Expand Down

0 comments on commit ac8c793

Please sign in to comment.