• Chris Wilson's avatar
    drm/i915: Delay allocation of stolen space for FBC · 11be49eb
    Chris Wilson authored
    As FBC is commonly disabled due to limitations of the chipset upon
    output configurations, on many systems FBC is never enabled. For those
    systems, it is advantageous to make use of the stolen memory for other
    objects and so we defer allocation of the FBC chunk until we actually
    require it. This increases the likelihood of that allocation failing,
    but that in turns means that we are already taking advantage of the
    stolen memory!
    
    As well as delaying the allocation from driver initialisation until the
    first use of FBC, we also return the stolen block after we finish using
    it - allowing greater flexibility in our usage of stolen space. A side
    effect of this is that we can then attempt to allocate only the required
    amount of space (with a little slack to reduce reallocation rate and
    avoid fragmentation).
    Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
    Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
    11be49eb
i915_gem_stolen.c 6.03 KB