summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/common
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/nvgpu/common')
-rw-r--r--drivers/gpu/nvgpu/common/mm/gmmu.c10
-rw-r--r--drivers/gpu/nvgpu/common/mm/nvgpu_mem.c6
2 files changed, 9 insertions, 7 deletions
diff --git a/drivers/gpu/nvgpu/common/mm/gmmu.c b/drivers/gpu/nvgpu/common/mm/gmmu.c
index afbad75c..a5790e3a 100644
--- a/drivers/gpu/nvgpu/common/mm/gmmu.c
+++ b/drivers/gpu/nvgpu/common/mm/gmmu.c
@@ -1,5 +1,5 @@
1/* 1/*
2 * Copyright (c) 2017-2018, NVIDIA CORPORATION. All rights reserved. 2 * Copyright (c) 2017-2020, NVIDIA CORPORATION. All rights reserved.
3 * 3 *
4 * Permission is hereby granted, free of charge, to any person obtaining a 4 * Permission is hereby granted, free of charge, to any person obtaining a
5 * copy of this software and associated documentation files (the "Software"), 5 * copy of this software and associated documentation files (the "Software"),
@@ -628,7 +628,7 @@ static int __nvgpu_gmmu_update_page_table(struct vm_gk20a *vm,
628 "vm=%s " 628 "vm=%s "
629 "%-5s GPU virt %#-12llx +%#-9llx phys %#-12llx " 629 "%-5s GPU virt %#-12llx +%#-9llx phys %#-12llx "
630 "phys offset: %#-4llx; pgsz: %3dkb perm=%-2s | " 630 "phys offset: %#-4llx; pgsz: %3dkb perm=%-2s | "
631 "kind=%#02x APT=%-6s %c%c%c%c%c", 631 "kind=%#02x APT=%-6s %c%c%c%c%c%c",
632 vm->name, 632 vm->name,
633 (sgt != NULL) ? "MAP" : "UNMAP", 633 (sgt != NULL) ? "MAP" : "UNMAP",
634 virt_addr, 634 virt_addr,
@@ -643,7 +643,8 @@ static int __nvgpu_gmmu_update_page_table(struct vm_gk20a *vm,
643 attrs->sparse ? 'S' : '-', 643 attrs->sparse ? 'S' : '-',
644 attrs->priv ? 'P' : '-', 644 attrs->priv ? 'P' : '-',
645 attrs->coherent ? 'I' : '-', 645 attrs->coherent ? 'I' : '-',
646 attrs->valid ? 'V' : '-'); 646 attrs->valid ? 'V' : '-',
647 attrs->platform_atomic ? 'A' : '-');
647 648
648 err = __nvgpu_gmmu_do_update_page_table(vm, 649 err = __nvgpu_gmmu_do_update_page_table(vm,
649 sgt, 650 sgt,
@@ -702,7 +703,8 @@ u64 gk20a_locked_gmmu_map(struct vm_gk20a *vm,
702 .priv = priv, 703 .priv = priv,
703 .coherent = flags & NVGPU_VM_MAP_IO_COHERENT, 704 .coherent = flags & NVGPU_VM_MAP_IO_COHERENT,
704 .valid = (flags & NVGPU_VM_MAP_UNMAPPED_PTE) == 0U, 705 .valid = (flags & NVGPU_VM_MAP_UNMAPPED_PTE) == 0U,
705 .aperture = aperture 706 .aperture = aperture,
707 .platform_atomic = (flags & NVGPU_VM_MAP_PLATFORM_ATOMIC) != 0U
706 }; 708 };
707 709
708 /* 710 /*
diff --git a/drivers/gpu/nvgpu/common/mm/nvgpu_mem.c b/drivers/gpu/nvgpu/common/mm/nvgpu_mem.c
index 8f6bd66e..2326e0ae 100644
--- a/drivers/gpu/nvgpu/common/mm/nvgpu_mem.c
+++ b/drivers/gpu/nvgpu/common/mm/nvgpu_mem.c
@@ -1,5 +1,5 @@
1/* 1/*
2 * Copyright (c) 2017-2018, NVIDIA CORPORATION. All rights reserved. 2 * Copyright (c) 2017-2020, NVIDIA CORPORATION. All rights reserved.
3 * 3 *
4 * Permission is hereby granted, free of charge, to any person obtaining a 4 * Permission is hereby granted, free of charge, to any person obtaining a
5 * copy of this software and associated documentation files (the "Software"), 5 * copy of this software and associated documentation files (the "Software"),
@@ -31,7 +31,7 @@
31 * will not add any checks. If you want to simply use the default coherency then 31 * will not add any checks. If you want to simply use the default coherency then
32 * use nvgpu_aperture_mask(). 32 * use nvgpu_aperture_mask().
33 */ 33 */
34u32 nvgpu_aperture_mask_coh(struct gk20a *g, enum nvgpu_aperture aperture, 34u32 nvgpu_aperture_mask_raw(struct gk20a *g, enum nvgpu_aperture aperture,
35 u32 sysmem_mask, u32 sysmem_coh_mask, 35 u32 sysmem_mask, u32 sysmem_coh_mask,
36 u32 vidmem_mask) 36 u32 vidmem_mask)
37{ 37{
@@ -71,7 +71,7 @@ u32 nvgpu_aperture_mask(struct gk20a *g, struct nvgpu_mem *mem,
71 ap = APERTURE_SYSMEM_COH; 71 ap = APERTURE_SYSMEM_COH;
72 } 72 }
73 73
74 return nvgpu_aperture_mask_coh(g, ap, 74 return nvgpu_aperture_mask_raw(g, ap,
75 sysmem_mask, 75 sysmem_mask,
76 sysmem_coh_mask, 76 sysmem_coh_mask,
77 vidmem_mask); 77 vidmem_mask);