drm/i915: Move drm_framebuffer_unreference out of struct_mutex for takeover
authorTvrtko Ursulin <tvrtko.ursulin@intel.com>
Mon, 13 Apr 2015 15:03:03 +0000 (16:03 +0100)
committerJani Nikula <jani.nikula@intel.com>
Tue, 14 Apr 2015 13:09:05 +0000 (16:09 +0300)
commite0d6149b3debce1a7e17dfda7c2829935917dc58
treefce1cc2151d4a8c9250230f4514b7bc7c3899dc8
parent08d9bc920d465bbbbd762cac9383249c19bf69a2
drm/i915: Move drm_framebuffer_unreference out of struct_mutex for takeover

intel_user_framebuffer_destroy() requires the struct_mutex for its
object bookkeeping, so this means that all calls to
drm_framebuffer_unreference must be held without that lock.

This is a simplified version of the identically named patch by Chris Wilson.

    Regression from commit ab8d66752a9c28cd6c94fa173feacdfc1554aa03
    Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
    Date:   Mon Feb 2 15:44:15 2015 +0000

        drm/i915: Track old framebuffer instead of object

v2: Bikeshedding.

References: https://bugs.freedesktop.org/show_bug.cgi?id=89166
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
drivers/gpu/drm/i915/intel_display.c