]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915/gt: Prefer recycling an idle fence
authorChris Wilson <chris@chris-wilson.co.uk>
Wed, 23 Dec 2020 12:20:50 +0000 (12:20 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Wed, 23 Dec 2020 21:58:00 +0000 (21:58 +0000)
commit4a4ca382d57f26fac75a3cf150be23369bf4c11c
treeefdc7d646bfe753af5e78001c9330c4f797ef0f8
parent280f084366f1bd1ec24745add72fc573b740eac6
drm/i915/gt: Prefer recycling an idle fence

If we want to reuse a fence that is in active use by the GPU, we have to
wait an uncertain amount of time, but if we reuse an inactive fence, we
can change it right away. Loop through the list of available fences
twice, ignoring any active fences on the first pass.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20201223122051.4624-1-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/gt/intel_ggtt_fencing.c