]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915: Round tile chunks up for constructing partial VMAs
authorChris Wilson <chris@chris-wilson.co.uk>
Mon, 7 Nov 2016 10:54:43 +0000 (10:54 +0000)
committerJani Nikula <jani.nikula@intel.com>
Mon, 7 Nov 2016 16:24:10 +0000 (18:24 +0200)
commitfa4ee5c8eea9bc45a9fa2b8d12b11e9e07298d8f
treec0a99356ad3bcf21ba2e9a5f73e8de31926325a3
parent5a1cb3001ff7df5d1eefa8c0cedf9b7100748fc7
drm/i915: Round tile chunks up for constructing partial VMAs

When we split a large object up into chunks for GTT faulting (because we
can't fit the whole object into the aperture) we have to align our cuts
with the fence registers. Each partial VMA must cover a complete set of
tile rows or the offset into each partial VMA is not aligned with the
whole image. Currently we enforce a minimum size on each partial VMA,
but this minimum size itself was not aligned to the tile row causing
distortion.

Reported-by: Andreas Reis <andreas.reis@gmail.com>
Reported-by: Chris Clayton <chris2553@googlemail.com>
Reported-by: Norbert Preining <preining@logic.at>
Tested-by: Norbert Preining <preining@logic.at>
Tested-by: Chris Clayton <chris2553@googlemail.com>
Fixes: 4677e547e882 ("drm/i915: Choose partial chunksize based on tile row size")
Fixes: 40d2771853fd ("drm/i915: Fix partial GGTT faulting") # enabling patch
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=98402
Testcase: igt/gem_mmap_gtt/medium-copy-odd
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Jani Nikula <jani.nikula@linux.intel.com>
Cc: <drm-intel-fixes@lists.freedesktop.org> # v4.9-rc1+
Link: http://patchwork.freedesktop.org/patch/msgid/20161107105443.27855-1-chris@chris-wilson.co.uk
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
(cherry picked from commit 0ef723cbceb6dce8116e75d44c5b8679b2eba69a)
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
drivers/gpu/drm/i915/i915_gem.c