diff options
-rw-r--r-- | drivers/gpu/nvgpu/gv11b/fifo_gv11b.c | 16 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/gv11b/pmu_gv11b.c | 4 |
2 files changed, 12 insertions, 8 deletions
diff --git a/drivers/gpu/nvgpu/gv11b/fifo_gv11b.c b/drivers/gpu/nvgpu/gv11b/fifo_gv11b.c index b018f3d9..847bf172 100644 --- a/drivers/gpu/nvgpu/gv11b/fifo_gv11b.c +++ b/drivers/gpu/nvgpu/gv11b/fifo_gv11b.c | |||
@@ -718,12 +718,12 @@ static int gv11b_fifo_preempt_channel(struct gk20a *g, u32 hw_chid) | |||
718 | 718 | ||
719 | nvgpu_mutex_acquire(&f->runlist_info[runlist_id].mutex); | 719 | nvgpu_mutex_acquire(&f->runlist_info[runlist_id].mutex); |
720 | 720 | ||
721 | mutex_ret = pmu_mutex_acquire(&g->pmu, PMU_MUTEX_ID_FIFO, &token); | 721 | mutex_ret = nvgpu_pmu_mutex_acquire(&g->pmu, PMU_MUTEX_ID_FIFO, &token); |
722 | 722 | ||
723 | ret = __locked_fifo_preempt(g, hw_chid, false); | 723 | ret = __locked_fifo_preempt(g, hw_chid, false); |
724 | 724 | ||
725 | if (!mutex_ret) | 725 | if (!mutex_ret) |
726 | pmu_mutex_release(&g->pmu, PMU_MUTEX_ID_FIFO, &token); | 726 | nvgpu_pmu_mutex_release(&g->pmu, PMU_MUTEX_ID_FIFO, &token); |
727 | 727 | ||
728 | nvgpu_mutex_release(&f->runlist_info[runlist_id].mutex); | 728 | nvgpu_mutex_release(&f->runlist_info[runlist_id].mutex); |
729 | 729 | ||
@@ -770,12 +770,12 @@ static int gv11b_fifo_preempt_tsg(struct gk20a *g, u32 tsgid) | |||
770 | 770 | ||
771 | nvgpu_mutex_acquire(&f->runlist_info[runlist_id].mutex); | 771 | nvgpu_mutex_acquire(&f->runlist_info[runlist_id].mutex); |
772 | 772 | ||
773 | mutex_ret = pmu_mutex_acquire(&g->pmu, PMU_MUTEX_ID_FIFO, &token); | 773 | mutex_ret = nvgpu_pmu_mutex_acquire(&g->pmu, PMU_MUTEX_ID_FIFO, &token); |
774 | 774 | ||
775 | ret = __locked_fifo_preempt(g, tsgid, true); | 775 | ret = __locked_fifo_preempt(g, tsgid, true); |
776 | 776 | ||
777 | if (!mutex_ret) | 777 | if (!mutex_ret) |
778 | pmu_mutex_release(&g->pmu, PMU_MUTEX_ID_FIFO, &token); | 778 | nvgpu_pmu_mutex_release(&g->pmu, PMU_MUTEX_ID_FIFO, &token); |
779 | 779 | ||
780 | nvgpu_mutex_release(&f->runlist_info[runlist_id].mutex); | 780 | nvgpu_mutex_release(&f->runlist_info[runlist_id].mutex); |
781 | 781 | ||
@@ -798,12 +798,12 @@ static int gv11b_fifo_preempt_runlists(struct gk20a *g, u32 runlists_mask) | |||
798 | runlist_info[runlist_id].mutex); | 798 | runlist_info[runlist_id].mutex); |
799 | } | 799 | } |
800 | 800 | ||
801 | mutex_ret = pmu_mutex_acquire(&g->pmu, PMU_MUTEX_ID_FIFO, &token); | 801 | mutex_ret = nvgpu_pmu_mutex_acquire(&g->pmu, PMU_MUTEX_ID_FIFO, &token); |
802 | 802 | ||
803 | ret = __locked_fifo_preempt_runlists(g, runlists_mask); | 803 | ret = __locked_fifo_preempt_runlists(g, runlists_mask); |
804 | 804 | ||
805 | if (!mutex_ret) | 805 | if (!mutex_ret) |
806 | pmu_mutex_release(&g->pmu, PMU_MUTEX_ID_FIFO, &token); | 806 | nvgpu_pmu_mutex_release(&g->pmu, PMU_MUTEX_ID_FIFO, &token); |
807 | 807 | ||
808 | for (runlist_id = 0; runlist_id < g->fifo.max_runlists; runlist_id++) { | 808 | for (runlist_id = 0; runlist_id < g->fifo.max_runlists; runlist_id++) { |
809 | if (runlists_mask & fifo_runlist_preempt_runlist_m(runlist_id)) | 809 | if (runlists_mask & fifo_runlist_preempt_runlist_m(runlist_id)) |
@@ -858,12 +858,12 @@ static int gv11b_fifo_preempt_ch_tsg(struct gk20a *g, u32 id, | |||
858 | 858 | ||
859 | nvgpu_mutex_acquire(&f->runlist_info[runlist_id].mutex); | 859 | nvgpu_mutex_acquire(&f->runlist_info[runlist_id].mutex); |
860 | 860 | ||
861 | mutex_ret = pmu_mutex_acquire(&g->pmu, PMU_MUTEX_ID_FIFO, &token); | 861 | mutex_ret = nvgpu_pmu_mutex_acquire(&g->pmu, PMU_MUTEX_ID_FIFO, &token); |
862 | 862 | ||
863 | ret = __locked_fifo_preempt_ch_tsg(g, id, id_type, timeout_rc_type); | 863 | ret = __locked_fifo_preempt_ch_tsg(g, id, id_type, timeout_rc_type); |
864 | 864 | ||
865 | if (!mutex_ret) | 865 | if (!mutex_ret) |
866 | pmu_mutex_release(&g->pmu, PMU_MUTEX_ID_FIFO, &token); | 866 | nvgpu_pmu_mutex_release(&g->pmu, PMU_MUTEX_ID_FIFO, &token); |
867 | 867 | ||
868 | nvgpu_mutex_release(&f->runlist_info[runlist_id].mutex); | 868 | nvgpu_mutex_release(&f->runlist_info[runlist_id].mutex); |
869 | 869 | ||
diff --git a/drivers/gpu/nvgpu/gv11b/pmu_gv11b.c b/drivers/gpu/nvgpu/gv11b/pmu_gv11b.c index 35246138..4c2b6dca 100644 --- a/drivers/gpu/nvgpu/gv11b/pmu_gv11b.c +++ b/drivers/gpu/nvgpu/gv11b/pmu_gv11b.c | |||
@@ -158,5 +158,9 @@ void gv11b_init_pmu_ops(struct gpu_ops *gops) | |||
158 | gops->pmu.pmu_get_queue_head_size = pwr_pmu_queue_head__size_1_v; | 158 | gops->pmu.pmu_get_queue_head_size = pwr_pmu_queue_head__size_1_v; |
159 | gops->pmu.pmu_get_queue_tail = pwr_pmu_queue_tail_r; | 159 | gops->pmu.pmu_get_queue_tail = pwr_pmu_queue_tail_r; |
160 | gops->pmu.pmu_get_queue_tail_size = pwr_pmu_queue_tail__size_1_v; | 160 | gops->pmu.pmu_get_queue_tail_size = pwr_pmu_queue_tail__size_1_v; |
161 | gops->pmu.pmu_queue_head = gk20a_pmu_queue_head; | ||
162 | gops->pmu.pmu_queue_tail = gk20a_pmu_queue_tail; | ||
163 | gops->pmu.pmu_mutex_acquire = gk20a_pmu_mutex_acquire; | ||
164 | gops->pmu.pmu_mutex_release = gk20a_pmu_mutex_release; | ||
161 | gops->pmu.pmu_elpg_statistics = gp106_pmu_elpg_statistics; | 165 | gops->pmu.pmu_elpg_statistics = gp106_pmu_elpg_statistics; |
162 | } | 166 | } |