drm/i915: Don't leak framebuffer_references if drm_framebuffer_init() fails
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Thu, 14 Jan 2016 13:22:09 +0000 (15:22 +0200)
committerVille Syrjälä <ville.syrjala@linux.intel.com>
Fri, 15 Jan 2016 19:04:07 +0000 (21:04 +0200)
commit0b05e1e0c945ff4e8635890982fafa5434b262d9
tree7971f1207dd61f7b69f614c3a10fda6a64613e4d
parent013dd9e038723bbd2aa67be51847384b75be8253
drm/i915: Don't leak framebuffer_references if drm_framebuffer_init() fails

Don't increment obj->framebuffer_references until we know we actually
managed to create the framebuffer.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: http://patchwork.freedesktop.org/patch/msgid/1452777736-4909-2-git-send-email-ville.syrjala@linux.intel.com
drivers/gpu/drm/i915/intel_display.c