]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915: Only pwrite through the GTT if there is space in the aperture
authorChris Wilson <chris@chris-wilson.co.uk>
Sat, 11 Aug 2012 14:41:04 +0000 (15:41 +0100)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Fri, 24 Aug 2012 00:03:33 +0000 (02:03 +0200)
commit2650c63bed7935991f3c76fe5ca69d6c8c2f6d22
treed8eb2c95987bdf4c1fa6ef3998615eeee88ced08
parente1fcb4059751b069cf6abe903e678fdaf5909045
drm/i915: Only pwrite through the GTT if there is space in the aperture

Avoid stalling and waiting for the GPU by checking to see if there is
sufficient inactive space in the aperture for us to bind the buffer
prior to writing through the GTT. If there is inadequate space we will
have to stall waiting for the GPU, and incur overheads moving objects
about. Instead, only incur the clflush overhead on the target object by
writing through shmem.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/i915_drv.h
drivers/gpu/drm/i915/i915_gem.c
drivers/gpu/drm/i915/i915_gem_context.c
drivers/gpu/drm/i915/i915_gem_evict.c
drivers/gpu/drm/i915/i915_gem_execbuffer.c
drivers/gpu/drm/i915/intel_overlay.c
drivers/gpu/drm/i915/intel_pm.c
drivers/gpu/drm/i915/intel_ringbuffer.c