drm/i915: Mark shadow batch buffers as purgeable
authorBrad Volkin <bradley.d.volkin@intel.com>
Thu, 11 Dec 2014 20:13:11 +0000 (12:13 -0800)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Tue, 16 Dec 2014 09:39:09 +0000 (10:39 +0100)
commit0079a7df3a47bfd0b64dc6e6ef47a651263760dc
tree0b883212e4550a4a64fd29cb1e6878d8a798fdb0
parentb9ffd80ed659c559152c042e74741f4f60cac691
drm/i915: Mark shadow batch buffers as purgeable

By adding a new exec_entry flag, we cleanly mark the shadow objects
as purgeable after they are on the active list.

v2:
- Move 'shadow_batch_obj->madv = I915_MADV_WILLNEED' inside _get
  fnc (danvet, from v4 6/7 feedback)

v3:
- Remove duplicate 'madv = I915_MADV_WILLNEED' (danvet, from v6 4/5)

Issue: VIZ-4719
Signed-off-by: Brad Volkin <bradley.d.volkin@intel.com>
Reviewed-By: Jon Bloomfield <jon.bloomfield@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/i915_gem_batch_pool.c
drivers/gpu/drm/i915/i915_gem_execbuffer.c