drm/i915: Kill drop_pages()
authorChris Wilson <chris@chris-wilson.co.uk>
Thu, 4 Aug 2016 06:52:28 +0000 (07:52 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Thu, 4 Aug 2016 07:09:19 +0000 (08:09 +0100)
commit4717ca9eec1bb88513fb5cbe62f44348d5bc946c
tree1463832dd62918a8be2c51fddd695ceb598b0828
parentaa653a685d816648dd903f76c14a30d8baa23933
drm/i915: Kill drop_pages()

The drop_pages() function is a dangerous trap in that it can release the
passed in object pointer and so unless the caller is aware, it can
easily trick us into using the stale object afterwards. Move it into its
solitary callsite where we know it is safe.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1470293567-10811-9-git-send-email-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/i915_gem.c