diff options
Diffstat (limited to 'drivers/gpu/nvgpu/gm20b/acr_gm20b.c')
-rw-r--r-- | drivers/gpu/nvgpu/gm20b/acr_gm20b.c | 70 |
1 files changed, 0 insertions, 70 deletions
diff --git a/drivers/gpu/nvgpu/gm20b/acr_gm20b.c b/drivers/gpu/nvgpu/gm20b/acr_gm20b.c index a4657ff3..e38e9a85 100644 --- a/drivers/gpu/nvgpu/gm20b/acr_gm20b.c +++ b/drivers/gpu/nvgpu/gm20b/acr_gm20b.c | |||
@@ -1045,76 +1045,6 @@ int acr_ucode_patch_sig(struct gk20a *g, | |||
1045 | return 0; | 1045 | return 0; |
1046 | } | 1046 | } |
1047 | 1047 | ||
1048 | int gm20b_init_nspmu_setup_hw1(struct gk20a *g) | ||
1049 | { | ||
1050 | struct nvgpu_pmu *pmu = &g->pmu; | ||
1051 | int err = 0; | ||
1052 | |||
1053 | nvgpu_log_fn(g, " "); | ||
1054 | |||
1055 | nvgpu_mutex_acquire(&pmu->isr_mutex); | ||
1056 | nvgpu_flcn_reset(pmu->flcn); | ||
1057 | pmu->isr_enabled = true; | ||
1058 | nvgpu_mutex_release(&pmu->isr_mutex); | ||
1059 | |||
1060 | /* setup apertures - virtual */ | ||
1061 | gk20a_writel(g, pwr_fbif_transcfg_r(GK20A_PMU_DMAIDX_UCODE), | ||
1062 | pwr_fbif_transcfg_mem_type_virtual_f()); | ||
1063 | gk20a_writel(g, pwr_fbif_transcfg_r(GK20A_PMU_DMAIDX_VIRT), | ||
1064 | pwr_fbif_transcfg_mem_type_virtual_f()); | ||
1065 | /* setup apertures - physical */ | ||
1066 | gk20a_writel(g, pwr_fbif_transcfg_r(GK20A_PMU_DMAIDX_PHYS_VID), | ||
1067 | pwr_fbif_transcfg_mem_type_physical_f() | | ||
1068 | pwr_fbif_transcfg_target_local_fb_f()); | ||
1069 | gk20a_writel(g, pwr_fbif_transcfg_r(GK20A_PMU_DMAIDX_PHYS_SYS_COH), | ||
1070 | pwr_fbif_transcfg_mem_type_physical_f() | | ||
1071 | pwr_fbif_transcfg_target_coherent_sysmem_f()); | ||
1072 | gk20a_writel(g, pwr_fbif_transcfg_r(GK20A_PMU_DMAIDX_PHYS_SYS_NCOH), | ||
1073 | pwr_fbif_transcfg_mem_type_physical_f() | | ||
1074 | pwr_fbif_transcfg_target_noncoherent_sysmem_f()); | ||
1075 | |||
1076 | err = g->ops.pmu.pmu_nsbootstrap(pmu); | ||
1077 | |||
1078 | return err; | ||
1079 | } | ||
1080 | |||
1081 | void gm20b_setup_apertures(struct gk20a *g) | ||
1082 | { | ||
1083 | /* setup apertures - virtual */ | ||
1084 | gk20a_writel(g, pwr_fbif_transcfg_r(GK20A_PMU_DMAIDX_UCODE), | ||
1085 | pwr_fbif_transcfg_mem_type_physical_f() | | ||
1086 | pwr_fbif_transcfg_target_local_fb_f()); | ||
1087 | gk20a_writel(g, pwr_fbif_transcfg_r(GK20A_PMU_DMAIDX_VIRT), | ||
1088 | pwr_fbif_transcfg_mem_type_virtual_f()); | ||
1089 | /* setup apertures - physical */ | ||
1090 | gk20a_writel(g, pwr_fbif_transcfg_r(GK20A_PMU_DMAIDX_PHYS_VID), | ||
1091 | pwr_fbif_transcfg_mem_type_physical_f() | | ||
1092 | pwr_fbif_transcfg_target_local_fb_f()); | ||
1093 | gk20a_writel(g, pwr_fbif_transcfg_r(GK20A_PMU_DMAIDX_PHYS_SYS_COH), | ||
1094 | pwr_fbif_transcfg_mem_type_physical_f() | | ||
1095 | pwr_fbif_transcfg_target_coherent_sysmem_f()); | ||
1096 | gk20a_writel(g, pwr_fbif_transcfg_r(GK20A_PMU_DMAIDX_PHYS_SYS_NCOH), | ||
1097 | pwr_fbif_transcfg_mem_type_physical_f() | | ||
1098 | pwr_fbif_transcfg_target_noncoherent_sysmem_f()); | ||
1099 | } | ||
1100 | |||
1101 | void gm20b_update_lspmu_cmdline_args(struct gk20a *g) | ||
1102 | { | ||
1103 | struct nvgpu_pmu *pmu = &g->pmu; | ||
1104 | /*Copying pmu cmdline args*/ | ||
1105 | g->ops.pmu_ver.set_pmu_cmdline_args_cpu_freq(pmu, | ||
1106 | g->ops.clk.get_rate(g, CTRL_CLK_DOMAIN_PWRCLK)); | ||
1107 | g->ops.pmu_ver.set_pmu_cmdline_args_secure_mode(pmu, 1); | ||
1108 | g->ops.pmu_ver.set_pmu_cmdline_args_trace_size( | ||
1109 | pmu, GK20A_PMU_TRACE_BUFSIZE); | ||
1110 | g->ops.pmu_ver.set_pmu_cmdline_args_trace_dma_base(pmu); | ||
1111 | g->ops.pmu_ver.set_pmu_cmdline_args_trace_dma_idx( | ||
1112 | pmu, GK20A_PMU_DMAIDX_VIRT); | ||
1113 | nvgpu_flcn_copy_to_dmem(pmu->flcn, g->acr.pmu_args, | ||
1114 | (u8 *)(g->ops.pmu_ver.get_pmu_cmdline_args_ptr(pmu)), | ||
1115 | g->ops.pmu_ver.get_pmu_cmdline_args_size(pmu), 0); | ||
1116 | } | ||
1117 | |||
1118 | static int nvgpu_gm20b_acr_wait_for_completion(struct gk20a *g, | 1048 | static int nvgpu_gm20b_acr_wait_for_completion(struct gk20a *g, |
1119 | struct nvgpu_falcon *flcn, unsigned int timeout) | 1049 | struct nvgpu_falcon *flcn, unsigned int timeout) |
1120 | { | 1050 | { |