drm/nouveau/mmu/gp100-: always invalidate TLBs at CACHE_LEVEL_ALL
authorBen Skeggs <bskeggs@redhat.com>
Tue, 19 Sep 2023 21:55:59 +0000 (17:55 -0400)
committerLyude Paul <lyude@redhat.com>
Tue, 19 Sep 2023 22:21:51 +0000 (18:21 -0400)
Fixes some issues when running on top of RM.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
Acked-by: Danilo Krummrich <me@dakr.org>
Signed-off-by: Lyude Paul <lyude@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20230919220442.202488-5-lyude@redhat.com
drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmmgp100.c
drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmmtu102.c

index f3630d0..bddac77 100644 (file)
@@ -558,7 +558,7 @@ gp100_vmm_invalidate_pdb(struct nvkm_vmm *vmm, u64 addr)
 void
 gp100_vmm_flush(struct nvkm_vmm *vmm, int depth)
 {
-       u32 type = (5 /* CACHE_LEVEL_UP_TO_PDE3 */ - depth) << 24;
+       u32 type = 0;
        if (atomic_read(&vmm->engref[NVKM_SUBDEV_BAR]))
                type |= 0x00000004; /* HUB_ONLY */
        type |= 0x00000001; /* PAGE_ALL */
index 6cb5eef..0095d58 100644 (file)
@@ -27,7 +27,7 @@ static void
 tu102_vmm_flush(struct nvkm_vmm *vmm, int depth)
 {
        struct nvkm_device *device = vmm->mmu->subdev.device;
-       u32 type = (5 /* CACHE_LEVEL_UP_TO_PDE3 */ - depth) << 24;
+       u32 type = 0;
 
        type |= 0x00000001; /* PAGE_ALL */
        if (atomic_read(&vmm->engref[NVKM_SUBDEV_BAR]))