lkml.org 
[lkml]   [2012]   [Dec]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 182/241] drm/i915: Use cpu relocations if the object is in the GTT but not mappable
    Date
    3.5.7.2 -stable review patch.  If anyone has any objections, please let me know.

    ------------------

    From: Chris Wilson <chris@chris-wilson.co.uk>

    commit 504c7267a1e84b157cbd7e9c1b805e1bc0c2c846 upstream.

    This prevents the case of unbinding the object in order to process the
    relocations through the GTT and then rebinding it only to then proceed
    to use cpu relocations as the object is now in the CPU write domain. By
    choosing to use cpu relocations up front, we can therefore avoid the
    rebind penalty.

    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
    Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
    Signed-off-by: Herton Ronaldo Krzesinski <herton.krzesinski@canonical.com>
    ---
    drivers/gpu/drm/i915/i915_gem_execbuffer.c | 1 +
    1 file changed, 1 insertion(+)

    diff --git a/drivers/gpu/drm/i915/i915_gem_execbuffer.c b/drivers/gpu/drm/i915/i915_gem_execbuffer.c
    index 974a9f1..3debf95 100644
    --- a/drivers/gpu/drm/i915/i915_gem_execbuffer.c
    +++ b/drivers/gpu/drm/i915/i915_gem_execbuffer.c
    @@ -269,6 +269,7 @@ eb_destroy(struct eb_objects *eb)
    static inline int use_cpu_reloc(struct drm_i915_gem_object *obj)
    {
    return (obj->base.write_domain == I915_GEM_DOMAIN_CPU ||
    + !obj->map_and_fenceable ||
    obj->cache_level != I915_CACHE_NONE);
    }

    --
    1.7.9.5


    \
     
     \ /
      Last update: 2012-12-13 15:21    [W:3.253 / U:0.072 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site