From de2656300ae74df5075a3a7e38a701c8048af3b2 Mon Sep 17 00:00:00 2001 From: Terje Bergstrom Date: Mon, 9 Nov 2015 09:06:37 -0800 Subject: Revert "gpu: nvgpu: gp10b: Implement sparse PDEs" This reverts commit c2707054192b058eec24a52c7f586b030f9ff007. It introduces regression in T124. Bug 1702063 Signed-off-by: Terje Bergstrom Change-Id: I8516c0bfe129bb1ac3d7a1983846061df8ae967b Reviewed-on: http://git-master/r/830787 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit --- drivers/gpu/nvgpu/gp10b/mm_gp10b.c | 21 ++++++--------------- 1 file changed, 6 insertions(+), 15 deletions(-) (limited to 'drivers/gpu/nvgpu/gp10b/mm_gp10b.c') diff --git a/drivers/gpu/nvgpu/gp10b/mm_gp10b.c b/drivers/gpu/nvgpu/gp10b/mm_gp10b.c index b5ea5d68..d3297e31 100644 --- a/drivers/gpu/nvgpu/gp10b/mm_gp10b.c +++ b/drivers/gpu/nvgpu/gp10b/mm_gp10b.c @@ -157,18 +157,17 @@ static int update_gmmu_pde3_locked(struct vm_gk20a *vm, int rw_flag, bool sparse, bool priv) { u64 pte_addr = 0; + u64 pde_addr = 0; struct gk20a_mm_entry *pte = parent->entries + i; u32 pde_v[2] = {0, 0}; u32 *pde; gk20a_dbg_fn(""); - if (!sparse) - pte_addr = sg_phys(pte->sgt->sgl) - >> gmmu_new_pde_address_shift_v(); + pte_addr = sg_phys(pte->sgt->sgl) >> gmmu_new_pde_address_shift_v(); + pde_addr = sg_phys(parent->sgt->sgl); - pde_v[0] |= sparse ? gmmu_new_pde_aperture_invalid_f() - : gmmu_new_pde_aperture_video_memory_f(); + pde_v[0] |= gmmu_new_pde_aperture_video_memory_f(); pde_v[0] |= gmmu_new_pde_address_sys_f(u64_lo32(pte_addr)); pde_v[0] |= gmmu_new_pde_vol_true_f(); pde_v[1] |= pte_addr >> 24; @@ -205,12 +204,9 @@ static int update_gmmu_pde0_locked(struct vm_gk20a *vm, u32 *pde; gk20a_dbg_fn(""); - gk20a_dbg(gpu_dbg_pte, "entry %p\n", entry); - small_valid = !sparse && entry->size - && entry->pgsz == gmmu_page_size_small; - big_valid = !sparse && entry->size - && entry->pgsz == gmmu_page_size_big; + small_valid = entry->size && entry->pgsz == gmmu_page_size_small; + big_valid = entry->size && entry->pgsz == gmmu_page_size_big; if (small_valid) pte_addr_small = sg_phys(entry->sgt->sgl) @@ -234,11 +230,6 @@ static int update_gmmu_pde0_locked(struct vm_gk20a *vm, pde_v[1] |= pte_addr_big >> 28; } - if (sparse) { - pde_v[0] |= gmmu_new_dual_pde_aperture_big_invalid_f(); - pde_v[0] |= gmmu_new_dual_pde_vol_big_true_f(); - } - pde = pde0_from_index(pte, i); gk20a_mem_wr32(pde, 0, pde_v[0]); -- cgit v1.2.2