drm/xe: Introduce a range-fence utility
authorThomas Hellström <thomas.hellstrom@linux.intel.com>
Sun, 9 Jul 2023 16:54:59 +0000 (09:54 -0700)
committerRodrigo Vivi <rodrigo.vivi@intel.com>
Thu, 21 Dec 2023 16:37:52 +0000 (11:37 -0500)
commit845f64bdbfc96cefd7070621b18ff8f50c7857fb
tree9157d9cf33d62ae1cb5fda0023c8f92b9b37af10
parent0043a3e8a1f57e3aca91d4a99ff49031416119b6
drm/xe: Introduce a range-fence utility

Add generic utility to track range conflicts signaled by a dma-fence.
Tracking implemented via an interval tree. An example use case being
tracking conflicts for pending (un)binds from multiple bind engines. By
being generic ths idea would this could moved to the DRM level and used
in multiple drivers for similar problems.

v2: Make interval tree functions static (CI)
v3: Remove non-static cleanup function (CI)

Reviewed-by: Matthew Brost <matthew.brost@intel.com>
Signed-off-by: Matthew Brost <matthew.brost@intel.com>
Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
drivers/gpu/drm/xe/Makefile
drivers/gpu/drm/xe/xe_range_fence.c [new file with mode: 0644]
drivers/gpu/drm/xe/xe_range_fence.h [new file with mode: 0644]