mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-19 23:48:36 +07:00
83bc4ec372
Searching for an available hole by address is slow, as there no guarantee that a hole will be available and so we must walk over all nodes in the rbtree before we determine the search was futile. In many cases, the caller doesn't strictly care for the highest available hole and was just opportunistically laying out the address space in a preferred order. In such cases, the caller can accept any address and would rather do so then do a slow walk. To be able to mix search strategies, the caller wants to tell the drm_mm how long to spend on the search. Without a good guide for what should be the best split, start with a request to try once at most. That is return the top-most (or lowest) hole if it fulfils the alignment and size requirements. v2: Documentation, by why of example (selftests) and kerneldoc. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20180521082131.13744-2-chris@chris-wilson.co.uk
28 lines
944 B
C
28 lines
944 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
/* List each unit test as selftest(name, function)
|
|
*
|
|
* The name is used as both an enum and expanded as igt__name to create
|
|
* a module parameter. It must be unique and legal for a C identifier.
|
|
*
|
|
* Tests are executed in order by igt/drm_mm
|
|
*/
|
|
selftest(sanitycheck, igt_sanitycheck) /* keep first (selfcheck for igt) */
|
|
selftest(init, igt_init)
|
|
selftest(debug, igt_debug)
|
|
selftest(reserve, igt_reserve)
|
|
selftest(insert, igt_insert)
|
|
selftest(replace, igt_replace)
|
|
selftest(insert_range, igt_insert_range)
|
|
selftest(align, igt_align)
|
|
selftest(align32, igt_align32)
|
|
selftest(align64, igt_align64)
|
|
selftest(evict, igt_evict)
|
|
selftest(evict_range, igt_evict_range)
|
|
selftest(bottomup, igt_bottomup)
|
|
selftest(lowest, igt_lowest)
|
|
selftest(topdown, igt_topdown)
|
|
selftest(highest, igt_highest)
|
|
selftest(color, igt_color)
|
|
selftest(color_evict, igt_color_evict)
|
|
selftest(color_evict_range, igt_color_evict_range)
|