[PATCH 3/5] vmwgfx: Unreference surface on cursor error path
Thomas Hellstrom
thellstrom at vmware.com
Thu Nov 3 13:03:06 PDT 2011
From: Jakob Bornecrantz <jakob at 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
More information about the dri-devel
mailing list