diff options
-rw-r--r-- | drivers/gpu/drm/i915/i915_dma.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c index 272614389c02..051134c56aef 100644 --- a/drivers/gpu/drm/i915/i915_dma.c +++ b/drivers/gpu/drm/i915/i915_dma.c | |||
@@ -713,18 +713,18 @@ static int i915_cmdbuffer(struct drm_device *dev, void *data, | |||
713 | mutex_unlock(&dev->struct_mutex); | 713 | mutex_unlock(&dev->struct_mutex); |
714 | if (ret) { | 714 | if (ret) { |
715 | DRM_ERROR("i915_dispatch_cmdbuffer failed\n"); | 715 | DRM_ERROR("i915_dispatch_cmdbuffer failed\n"); |
716 | goto fail_batch_free; | 716 | goto fail_clip_free; |
717 | } | 717 | } |
718 | 718 | ||
719 | if (sarea_priv) | 719 | if (sarea_priv) |
720 | sarea_priv->last_dispatch = READ_BREADCRUMB(dev_priv); | 720 | sarea_priv->last_dispatch = READ_BREADCRUMB(dev_priv); |
721 | 721 | ||
722 | fail_batch_free: | ||
723 | drm_free(batch_data, cmdbuf->sz, DRM_MEM_DRIVER); | ||
724 | fail_clip_free: | 722 | fail_clip_free: |
725 | drm_free(cliprects, | 723 | drm_free(cliprects, |
726 | cmdbuf->num_cliprects * sizeof(struct drm_clip_rect), | 724 | cmdbuf->num_cliprects * sizeof(struct drm_clip_rect), |
727 | DRM_MEM_DRIVER); | 725 | DRM_MEM_DRIVER); |
726 | fail_batch_free: | ||
727 | drm_free(batch_data, cmdbuf->sz, DRM_MEM_DRIVER); | ||
728 | 728 | ||
729 | return ret; | 729 | return ret; |
730 | } | 730 | } |