Now that we have improved the handling faulting in a full PMD only increases the overhead on my test system from 21us to 29us if only a single page is requested, but massively improves the performance for all other use cases.
So re-apply that change again to improve the fault handling for large allocations bringing us close to improving it by a factor of 10. This reverts commit c358a809cb58af944d496944391a240e02f5837a. Signed-off-by: Christian König <christian.koe...@amd.com> --- include/drm/ttm/ttm_bo.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/include/drm/ttm/ttm_bo.h b/include/drm/ttm/ttm_bo.h index 903cd1030110..e96477606207 100644 --- a/include/drm/ttm/ttm_bo.h +++ b/include/drm/ttm/ttm_bo.h @@ -39,7 +39,11 @@ #include "ttm_device.h" /* Default number of pre-faulted pages in the TTM fault handler */ +#if CONFIG_PGTABLE_LEVELS > 2 +#define TTM_BO_VM_NUM_PREFAULT (1 << (PMD_SHIFT - PAGE_SHIFT)) +#else #define TTM_BO_VM_NUM_PREFAULT 16 +#endif struct iosys_map; -- 2.43.0