]> www.infradead.org Git - users/jedix/linux-maple.git/commit
drm/ttm: increase ttm pre-fault value to PMD size
authorZhu Lingshan <lingshan.zhu@amd.com>
Tue, 4 Jun 2024 08:49:34 +0000 (16:49 +0800)
committerChristian König <christian.koenig@amd.com>
Thu, 20 Jun 2024 13:47:34 +0000 (15:47 +0200)
commit0ddd2ae586d28e521d37393364d989ce118802e0
tree67c314d73a0532ef2a161e3bba78636071dbfd65
parentc1391205754f0ddab5f990cd0642d0fa8fc4c6b7
drm/ttm: increase ttm pre-fault value to PMD size

ttm page fault handler ttm_bo_vm_fault_reserved() maps
TTM_BO_VM_NUM_PREFAULT more pages beforehand
due to the principle of locality.

However, on some platform the page faults are more costly, this
patch intends to increase the number of ttm pre-fault to relieve
the number of page faults.

When multiple levels of page table is supported, the new default
value would be the PMD size, similar to huge page.

Signed-off-by: Zhu Lingshan <lingshan.zhu@amd.com>
Reported-and-tested-by: Li Jingxiang <jingxiang.li@ecarxgroup.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240604084934.225738-1-lingshan.zhu@amd.com
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Christian König <christian.koenig@amd.com>
include/drm/ttm/ttm_bo.h