aboutsummaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorBen Skeggs <bskeggs@redhat.com>2013-11-13 15:18:32 +1000
committerKamal Mostafa <kamal@canonical.com>2013-12-06 14:28:11 -0800
commit5aa2cfd0c212a6f1f956b1d9b5a06a324cec7736 (patch)
tree40b2fc463cf19e6c6f76cd7351b0478ab1330fe0 /drivers
parent09e6a1005b686f5ef9588263bb43a24c6bad46d5 (diff)
drm/nouveau: when bailing out of a pushbuf ioctl, do not remove previous fence
commit 9360bd1112d8874d21942e2ae74f5416b00a8db6 upstream. Signed-off-by: Ben Skeggs <bskeggs@redhat.com> Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/gpu/drm/nouveau/nouveau_gem.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_gem.c b/drivers/gpu/drm/nouveau/nouveau_gem.c
index 8bf695c52f95..3aa8e2fc0ffa 100644
--- a/drivers/gpu/drm/nouveau/nouveau_gem.c
+++ b/drivers/gpu/drm/nouveau/nouveau_gem.c
@@ -288,7 +288,8 @@ validate_fini_list(struct list_head *list, struct nouveau_fence *fence)
list_for_each_safe(entry, tmp, list) {
nvbo = list_entry(entry, struct nouveau_bo, entry);
- nouveau_bo_fence(nvbo, fence);
+ if (likely(fence))
+ nouveau_bo_fence(nvbo, fence);
if (unlikely(nvbo->validate_mapped)) {
ttm_bo_kunmap(&nvbo->kmap);