summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/common/linux/cde_gp10b.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/nvgpu/common/linux/cde_gp10b.c')
-rw-r--r--drivers/gpu/nvgpu/common/linux/cde_gp10b.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/gpu/nvgpu/common/linux/cde_gp10b.c b/drivers/gpu/nvgpu/common/linux/cde_gp10b.c
index ffae6e34..483a3ee7 100644
--- a/drivers/gpu/nvgpu/common/linux/cde_gp10b.c
+++ b/drivers/gpu/nvgpu/common/linux/cde_gp10b.c
@@ -26,6 +26,7 @@
26#include "cde_gp10b.h" 26#include "cde_gp10b.h"
27 27
28#include <nvgpu/log.h> 28#include <nvgpu/log.h>
29#include <nvgpu/dma.h>
29 30
30enum gp10b_programs { 31enum gp10b_programs {
31 GP10B_PROG_HPASS = 0, 32 GP10B_PROG_HPASS = 0,
@@ -56,10 +57,10 @@ void gp10b_cde_get_program_numbers(struct gk20a *g,
56 hprog = GP10B_PROG_HPASS_DEBUG; 57 hprog = GP10B_PROG_HPASS_DEBUG;
57 vprog = GP10B_PROG_VPASS_DEBUG; 58 vprog = GP10B_PROG_VPASS_DEBUG;
58 } 59 }
59 if (g->mm.bypass_smmu) { 60 if (!nvgpu_iommuable(g)) {
60 if (!g->mm.disable_bigpage) { 61 if (!g->mm.disable_bigpage) {
61 nvgpu_warn(g, 62 nvgpu_warn(g,
62 "when bypass_smmu is 1, disable_bigpage must be 1 too"); 63 "When no IOMMU big pages cannot be used");
63 } 64 }
64 hprog |= 1; 65 hprog |= 1;
65 vprog |= 1; 66 vprog |= 1;
@@ -72,7 +73,7 @@ void gp10b_cde_get_program_numbers(struct gk20a *g,
72 73
73bool gp10b_need_scatter_buffer(struct gk20a *g) 74bool gp10b_need_scatter_buffer(struct gk20a *g)
74{ 75{
75 return g->mm.bypass_smmu; 76 return !nvgpu_iommuable(g);
76} 77}
77 78
78static u8 parity(u32 a) 79static u8 parity(u32 a)