summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/common
diff options
context:
space:
mode:
authorDeepak Nibade <dnibade@nvidia.com>2017-11-15 04:34:59 -0500
committermobile promotions <svcmobile_promotions@nvidia.com>2017-11-15 11:46:09 -0500
commit3ff666c4b97c5ad869aefe0d9c335c187962c20e (patch)
tree42ad94e7e5b877154a482e07746bb45e6a0b0d6c /drivers/gpu/nvgpu/common
parent592a31fd925d84622602b235647e9b50e2d34f47 (diff)
gpu: nvgpu: deprecate TSG/CHANNEL_SET_PRIORITY IOCTLs
TSG/CHANNEL_SET_PRIORITY IOCTLs are deprecated and user space should be using combination of timeslice and interleave levels to decide the priority Hence remove the IOCTLs and all corresponding APIs Jira NVGPU-393 Change-Id: I7cf0785689269536eca0c278c774b0e9e74f8c2f Signed-off-by: Deepak Nibade <dnibade@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1598581 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/common')
-rw-r--r--drivers/gpu/nvgpu/common/linux/ioctl_channel.c15
-rw-r--r--drivers/gpu/nvgpu/common/linux/ioctl_tsg.c34
-rw-r--r--drivers/gpu/nvgpu/common/mm/mm.c1
3 files changed, 0 insertions, 50 deletions
diff --git a/drivers/gpu/nvgpu/common/linux/ioctl_channel.c b/drivers/gpu/nvgpu/common/linux/ioctl_channel.c
index 6feb6fb7..31651795 100644
--- a/drivers/gpu/nvgpu/common/linux/ioctl_channel.c
+++ b/drivers/gpu/nvgpu/common/linux/ioctl_channel.c
@@ -1314,21 +1314,6 @@ long gk20a_channel_ioctl(struct file *filp,
1314 ((struct nvgpu_get_param_args *)buf)->value = 1314 ((struct nvgpu_get_param_args *)buf)->value =
1315 ch->has_timedout; 1315 ch->has_timedout;
1316 break; 1316 break;
1317 case NVGPU_IOCTL_CHANNEL_SET_PRIORITY:
1318 err = gk20a_busy(ch->g);
1319 if (err) {
1320 dev_err(dev,
1321 "%s: failed to host gk20a for ioctl cmd: 0x%x",
1322 __func__, cmd);
1323 break;
1324 }
1325 err = ch->g->ops.fifo.channel_set_priority(ch,
1326 ((struct nvgpu_set_priority_args *)buf)->priority);
1327
1328 gk20a_idle(ch->g);
1329 gk20a_channel_trace_sched_param(
1330 trace_gk20a_channel_set_priority, ch);
1331 break;
1332 case NVGPU_IOCTL_CHANNEL_ENABLE: 1317 case NVGPU_IOCTL_CHANNEL_ENABLE:
1333 err = gk20a_busy(ch->g); 1318 err = gk20a_busy(ch->g);
1334 if (err) { 1319 if (err) {
diff --git a/drivers/gpu/nvgpu/common/linux/ioctl_tsg.c b/drivers/gpu/nvgpu/common/linux/ioctl_tsg.c
index eb223382..b17d7e74 100644
--- a/drivers/gpu/nvgpu/common/linux/ioctl_tsg.c
+++ b/drivers/gpu/nvgpu/common/linux/ioctl_tsg.c
@@ -296,33 +296,6 @@ int nvgpu_ioctl_tsg_dev_release(struct inode *inode, struct file *filp)
296 return 0; 296 return 0;
297} 297}
298 298
299static int gk20a_tsg_ioctl_set_priority(struct gk20a *g,
300 struct tsg_gk20a *tsg, struct nvgpu_set_priority_args *arg)
301{
302 struct nvgpu_os_linux *l = nvgpu_os_linux_from_gk20a(g);
303 struct gk20a_sched_ctrl *sched = &l->sched_ctrl;
304 int err;
305
306 nvgpu_mutex_acquire(&sched->control_lock);
307 if (sched->control_locked) {
308 err = -EPERM;
309 goto done;
310 }
311
312 err = gk20a_busy(g);
313 if (err) {
314 nvgpu_err(g, "failed to power on gpu");
315 goto done;
316 }
317
318 err = gk20a_tsg_set_priority(g, tsg, arg->priority);
319
320 gk20a_idle(g);
321done:
322 nvgpu_mutex_release(&sched->control_lock);
323 return err;
324}
325
326static int gk20a_tsg_ioctl_set_runlist_interleave(struct gk20a *g, 299static int gk20a_tsg_ioctl_set_runlist_interleave(struct gk20a *g,
327 struct tsg_gk20a *tsg, struct nvgpu_runlist_interleave_args *arg) 300 struct tsg_gk20a *tsg, struct nvgpu_runlist_interleave_args *arg)
328{ 301{
@@ -475,13 +448,6 @@ long nvgpu_ioctl_tsg_dev_ioctl(struct file *filp, unsigned int cmd,
475 break; 448 break;
476 } 449 }
477 450
478 case NVGPU_IOCTL_TSG_SET_PRIORITY:
479 {
480 err = gk20a_tsg_ioctl_set_priority(g, tsg,
481 (struct nvgpu_set_priority_args *)buf);
482 break;
483 }
484
485 case NVGPU_IOCTL_TSG_EVENT_ID_CTRL: 451 case NVGPU_IOCTL_TSG_EVENT_ID_CTRL:
486 { 452 {
487 err = gk20a_tsg_event_id_ctrl(g, tsg, 453 err = gk20a_tsg_event_id_ctrl(g, tsg,
diff --git a/drivers/gpu/nvgpu/common/mm/mm.c b/drivers/gpu/nvgpu/common/mm/mm.c
index 86dc46c5..db87c4c4 100644
--- a/drivers/gpu/nvgpu/common/mm/mm.c
+++ b/drivers/gpu/nvgpu/common/mm/mm.c
@@ -262,7 +262,6 @@ void nvgpu_init_mm_ce_context(struct gk20a *g)
262 gk20a_ce_create_context(g, 262 gk20a_ce_create_context(g,
263 gk20a_fifo_get_fast_ce_runlist_id(g), 263 gk20a_fifo_get_fast_ce_runlist_id(g),
264 -1, 264 -1,
265 -1,
266 -1); 265 -1);
267 266
268 if (g->mm.vidmem.ce_ctx_id == (u32)~0) 267 if (g->mm.vidmem.ce_ctx_id == (u32)~0)