From: Jakob Bornecrantz <ja...@vmware.com> Signed-off-by: Jakob Bornecrantz <jakob at vmware.com> Reviewed-by: Thomas Hellstrom <thellstrom at vmware.com> --- drivers/gpu/drm/vmwgfx/vmwgfx_kms.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_kms.c b/drivers/gpu/drm/vmwgfx/vmwgfx_kms.c index 667437b..66e92ac 100644 --- a/drivers/gpu/drm/vmwgfx/vmwgfx_kms.c +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_kms.c @@ -111,6 +111,7 @@ int vmw_du_crtc_cursor_set(struct drm_crtc *crtc, struct drm_file *file_priv, if (!ret) { if (!surface->snooper.image) { DRM_ERROR("surface not suitable for cursor\n"); + vmw_surface_unreference(&surface); return -EINVAL; } } else { -- 1.7.4.4