Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

drm/amdgpu: cache the complete pde

Makes it easier to update the PDE with huge pages.

Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Junwei Zhang <Jerry.Zhang@amd.com>
Reviewed-by: Chunming Zhou <david1.zhou@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>

authored by

Christian König and committed by
Alex Deucher
53e2e91d bb37b67d

+5 -11
+5 -11
drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
··· 985 985 } 986 986 987 987 pt = amdgpu_bo_gpu_offset(bo); 988 + pt = amdgpu_gart_get_vm_pde(adev, pt); 988 989 if (parent->entries[pt_idx].addr == pt) 989 990 continue; 990 991 ··· 997 996 (count == AMDGPU_VM_MAX_UPDATE_SIZE)) { 998 997 999 998 if (count) { 1000 - uint64_t entry; 1001 - 1002 - entry = amdgpu_gart_get_vm_pde(adev, last_pt); 1003 999 if (shadow) 1004 1000 amdgpu_vm_do_set_ptes(&params, 1005 1001 last_shadow, 1006 - entry, count, 1002 + last_pt, count, 1007 1003 incr, 1008 1004 AMDGPU_PTE_VALID); 1009 1005 1010 1006 amdgpu_vm_do_set_ptes(&params, last_pde, 1011 - entry, count, incr, 1007 + last_pt, count, incr, 1012 1008 AMDGPU_PTE_VALID); 1013 1009 } 1014 1010 ··· 1019 1021 } 1020 1022 1021 1023 if (count) { 1022 - uint64_t entry; 1023 - 1024 - entry = amdgpu_gart_get_vm_pde(adev, last_pt); 1025 - 1026 1024 if (vm->root.bo->shadow) 1027 - amdgpu_vm_do_set_ptes(&params, last_shadow, entry, 1025 + amdgpu_vm_do_set_ptes(&params, last_shadow, last_pt, 1028 1026 count, incr, AMDGPU_PTE_VALID); 1029 1027 1030 - amdgpu_vm_do_set_ptes(&params, last_pde, entry, 1028 + amdgpu_vm_do_set_ptes(&params, last_pde, last_pt, 1031 1029 count, incr, AMDGPU_PTE_VALID); 1032 1030 } 1033 1031