From: Matt Roper Date: Mon, 1 Dec 2014 23:40:12 +0000 (-0800) Subject: drm/i915: Introduce intel_prepare_cursor_plane() (v2) X-Git-Tag: omap-for-v4.1/prcm-dts-mfd-syscon-fix~75^2~43^2~58 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f4a2cf295d07b1fba9fc3599c1579681132b658a;p=pandora-kernel.git drm/i915: Introduce intel_prepare_cursor_plane() (v2) Primary and sprite planes have already been refactored to include a 'prepare' step which handles all the commit-time operations that could fail (i.e., pinning buffers and such). Refactor the cursor commit in a similar manner. For simplicity and consistency with other plane types, we also switch to using intel_pin_and_fence_fb_obj() to perform our pinning for non-physical cursors. This will allow us to more easily migrate the code into the atomic 'begin' handler in a plane-agnostic manner in a future patchset. v2: - Update GEM fb tracking for physical cursors too. (Ander) - Use intel_unpin_fb_obj() rather than i915_gem_object_unpin_from_display_plane() and do so while holding struct_mutex. (Ander) - Update plane->fb in commit_cursor_plane. This isn't really necessary since the DRM core does this for us in __setplane_internal(), but doing it in our driver once we know we're going to succeed helps avoid confusion. (Ander) Signed-off-by: Matt Roper Reviewed-by: Ander Conselvan de Oliveira Signed-off-by: Daniel Vetter --- Reading git-diff-tree failed