diff options
Diffstat (limited to 'drivers/gpu/nvgpu/common')
-rw-r--r-- | drivers/gpu/nvgpu/common/fb/fb_gv11b.c | 2 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/common/ltc.c | 17 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/common/posix/stubs.c | 6 |
3 files changed, 8 insertions, 17 deletions
diff --git a/drivers/gpu/nvgpu/common/fb/fb_gv11b.c b/drivers/gpu/nvgpu/common/fb/fb_gv11b.c index 664b2dd1..6973e04d 100644 --- a/drivers/gpu/nvgpu/common/fb/fb_gv11b.c +++ b/drivers/gpu/nvgpu/common/fb/fb_gv11b.c | |||
@@ -102,6 +102,8 @@ void gv11b_fb_init_cbc(struct gk20a *g, struct gr_gk20a *gr) | |||
102 | else | 102 | else |
103 | compbit_store_iova = nvgpu_mem_get_addr(g, | 103 | compbit_store_iova = nvgpu_mem_get_addr(g, |
104 | &gr->compbit_store.mem); | 104 | &gr->compbit_store.mem); |
105 | /* must be aligned to 64 KB */ | ||
106 | compbit_store_iova = roundup(compbit_store_iova, (u64)SZ_64K); | ||
105 | 107 | ||
106 | compbit_base_post_divide64 = compbit_store_iova >> | 108 | compbit_base_post_divide64 = compbit_store_iova >> |
107 | fb_mmu_cbc_base_address_alignment_shift_v(); | 109 | fb_mmu_cbc_base_address_alignment_shift_v(); |
diff --git a/drivers/gpu/nvgpu/common/ltc.c b/drivers/gpu/nvgpu/common/ltc.c index dec4a80c..1beb1974 100644 --- a/drivers/gpu/nvgpu/common/ltc.c +++ b/drivers/gpu/nvgpu/common/ltc.c | |||
@@ -52,20 +52,3 @@ void nvgpu_ltc_sync_enabled(struct gk20a *g) | |||
52 | } | 52 | } |
53 | nvgpu_spinlock_release(&g->ltc_enabled_lock); | 53 | nvgpu_spinlock_release(&g->ltc_enabled_lock); |
54 | } | 54 | } |
55 | |||
56 | int nvgpu_ltc_alloc_cbc(struct gk20a *g, size_t compbit_backing_size) | ||
57 | { | ||
58 | struct gr_gk20a *gr = &g->gr; | ||
59 | unsigned long flags = 0; | ||
60 | |||
61 | if (nvgpu_mem_is_valid(&gr->compbit_store.mem)) | ||
62 | return 0; | ||
63 | |||
64 | if (!nvgpu_iommuable(g)) | ||
65 | flags = NVGPU_DMA_FORCE_CONTIGUOUS; | ||
66 | |||
67 | return nvgpu_dma_alloc_flags_sys(g, | ||
68 | flags, | ||
69 | compbit_backing_size, | ||
70 | &gr->compbit_store.mem); | ||
71 | } | ||
diff --git a/drivers/gpu/nvgpu/common/posix/stubs.c b/drivers/gpu/nvgpu/common/posix/stubs.c index 0fa80bff..1e50930a 100644 --- a/drivers/gpu/nvgpu/common/posix/stubs.c +++ b/drivers/gpu/nvgpu/common/posix/stubs.c | |||
@@ -26,6 +26,7 @@ | |||
26 | */ | 26 | */ |
27 | 27 | ||
28 | #include <nvgpu/ecc.h> | 28 | #include <nvgpu/ecc.h> |
29 | #include <nvgpu/ltc.h> | ||
29 | 30 | ||
30 | #include "gk20a/dbg_gpu_gk20a.h" | 31 | #include "gk20a/dbg_gpu_gk20a.h" |
31 | 32 | ||
@@ -41,3 +42,8 @@ int nvgpu_ecc_sysfs_init(struct gk20a *g) | |||
41 | void nvgpu_ecc_sysfs_remove(struct gk20a *g) | 42 | void nvgpu_ecc_sysfs_remove(struct gk20a *g) |
42 | { | 43 | { |
43 | } | 44 | } |
45 | |||
46 | int nvgpu_ltc_alloc_cbc(struct gk20a *g, size_t compbit_backing_size) | ||
47 | { | ||
48 | return 0; | ||
49 | } | ||