Skip to content

Commit

Permalink
drm/nouveau: fix another lock unbalance in nouveau_crtc_page_flip
Browse files Browse the repository at this point in the history
Fixes a regression introduced by 060810d "drm/nouveau: fix locking
issues in page flipping paths".  chan->cli->mutex is unlocked a second time
in the fail_unreserve path, fix this by moving mutex_unlock down.

Cc: stable@vger.kernel.org # v3.11+
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
  • Loading branch information
Maarten Lankhorst authored and Ben Skeggs committed May 2, 2014
1 parent ce23b23 commit 806cbc5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/gpu/drm/nouveau/nouveau_display.c
Original file line number Diff line number Diff line change
Expand Up @@ -764,9 +764,9 @@ nouveau_crtc_page_flip(struct drm_crtc *crtc, struct drm_framebuffer *fb,
}

ret = nouveau_page_flip_emit(chan, old_bo, new_bo, s, &fence);
mutex_unlock(&chan->cli->mutex);
if (ret)
goto fail_unreserve;
mutex_unlock(&chan->cli->mutex);

/* Update the crtc struct and cleanup */
crtc->fb = fb;
Expand Down

0 comments on commit 806cbc5

Please sign in to comment.