summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/common/fifo/channel.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/nvgpu/common/fifo/channel.c')
-rw-r--r--drivers/gpu/nvgpu/common/fifo/channel.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/drivers/gpu/nvgpu/common/fifo/channel.c b/drivers/gpu/nvgpu/common/fifo/channel.c
index adb59ac4..6ebeb596 100644
--- a/drivers/gpu/nvgpu/common/fifo/channel.c
+++ b/drivers/gpu/nvgpu/common/fifo/channel.c
@@ -1228,7 +1228,9 @@ int nvgpu_channel_setup_bind(struct channel_gk20a *c,
1228 nvgpu_log_info(g, "channel %d : gpfifo_base 0x%016llx, size %d", 1228 nvgpu_log_info(g, "channel %d : gpfifo_base 0x%016llx, size %d",
1229 c->chid, gpfifo_gpu_va, c->gpfifo.entry_num); 1229 c->chid, gpfifo_gpu_va, c->gpfifo.entry_num);
1230 1230
1231 g->ops.fifo.setup_userd(c); 1231 if (!c->usermode_submit_enabled) {
1232 g->ops.fifo.setup_userd(c);
1233 }
1232 1234
1233 if (g->aggressive_sync_destroy_thresh == 0U) { 1235 if (g->aggressive_sync_destroy_thresh == 0U) {
1234 nvgpu_mutex_acquire(&c->sync_lock); 1236 nvgpu_mutex_acquire(&c->sync_lock);
@@ -1326,7 +1328,10 @@ void gk20a_channel_free_usermode_buffers(struct channel_gk20a *c)
1326 nvgpu_dma_free(c->g, &c->usermode_userd); 1328 nvgpu_dma_free(c->g, &c->usermode_userd);
1327 } 1329 }
1328 if (nvgpu_mem_is_valid(&c->usermode_gpfifo)) { 1330 if (nvgpu_mem_is_valid(&c->usermode_gpfifo)) {
1329 nvgpu_dma_free(c->g, &c->usermode_gpfifo); 1331 nvgpu_dma_unmap_free(c->vm, &c->usermode_gpfifo);
1332 }
1333 if (c->g->os_channel.free_usermode_buffers != NULL) {
1334 c->g->os_channel.free_usermode_buffers(c);
1330 } 1335 }
1331} 1336}
1332 1337