Lines Matching refs:psp
48 static int psp_v12_0_init_microcode(struct psp_context *psp) in psp_v12_0_init_microcode() argument
50 struct amdgpu_device *adev = psp->adev; in psp_v12_0_init_microcode()
57 err = psp_init_asd_microcode(psp, ucode_prefix); in psp_v12_0_init_microcode()
61 err = psp_init_ta_microcode(psp, ucode_prefix); in psp_v12_0_init_microcode()
67 adev->psp.securedisplay_context.context.bin_desc.size_bytes = 0; in psp_v12_0_init_microcode()
72 static int psp_v12_0_bootloader_load_sysdrv(struct psp_context *psp) in psp_v12_0_bootloader_load_sysdrv() argument
76 struct amdgpu_device *adev = psp->adev; in psp_v12_0_bootloader_load_sysdrv()
87 ret = psp_wait_for(psp, SOC15_REG_OFFSET(MP0, 0, mmMP0_SMN_C2PMSG_35), in psp_v12_0_bootloader_load_sysdrv()
93 psp_copy_fw(psp, psp->sys.start_addr, psp->sys.size_bytes); in psp_v12_0_bootloader_load_sysdrv()
97 (uint32_t)(psp->fw_pri_mc_addr >> 20)); in psp_v12_0_bootloader_load_sysdrv()
105 ret = psp_wait_for(psp, SOC15_REG_OFFSET(MP0, 0, mmMP0_SMN_C2PMSG_35), in psp_v12_0_bootloader_load_sysdrv()
111 static int psp_v12_0_bootloader_load_sos(struct psp_context *psp) in psp_v12_0_bootloader_load_sos() argument
115 struct amdgpu_device *adev = psp->adev; in psp_v12_0_bootloader_load_sos()
126 ret = psp_wait_for(psp, SOC15_REG_OFFSET(MP0, 0, mmMP0_SMN_C2PMSG_35), in psp_v12_0_bootloader_load_sos()
132 psp_copy_fw(psp, psp->sos.start_addr, psp->sos.size_bytes); in psp_v12_0_bootloader_load_sos()
136 (uint32_t)(psp->fw_pri_mc_addr >> 20)); in psp_v12_0_bootloader_load_sos()
143 ret = psp_wait_for(psp, SOC15_REG_OFFSET(MP0, 0, mmMP0_SMN_C2PMSG_81), in psp_v12_0_bootloader_load_sos()
150 static void psp_v12_0_reroute_ih(struct psp_context *psp) in psp_v12_0_reroute_ih() argument
152 struct amdgpu_device *adev = psp->adev; in psp_v12_0_reroute_ih()
165 psp_wait_for(psp, SOC15_REG_OFFSET(MP0, 0, mmMP0_SMN_C2PMSG_64), in psp_v12_0_reroute_ih()
177 psp_wait_for(psp, SOC15_REG_OFFSET(MP0, 0, mmMP0_SMN_C2PMSG_64), in psp_v12_0_reroute_ih()
181 static int psp_v12_0_ring_create(struct psp_context *psp, in psp_v12_0_ring_create() argument
186 struct psp_ring *ring = &psp->km_ring; in psp_v12_0_ring_create()
187 struct amdgpu_device *adev = psp->adev; in psp_v12_0_ring_create()
189 psp_v12_0_reroute_ih(psp); in psp_v12_0_ring_create()
191 if (amdgpu_sriov_vf(psp->adev)) { in psp_v12_0_ring_create()
207 ret = psp_wait_for(psp, SOC15_REG_OFFSET(MP0, 0, mmMP0_SMN_C2PMSG_101), in psp_v12_0_ring_create()
229 ret = psp_wait_for(psp, SOC15_REG_OFFSET(MP0, 0, mmMP0_SMN_C2PMSG_64), in psp_v12_0_ring_create()
236 static int psp_v12_0_ring_stop(struct psp_context *psp, in psp_v12_0_ring_stop() argument
240 struct amdgpu_device *adev = psp->adev; in psp_v12_0_ring_stop()
255 ret = psp_wait_for(psp, SOC15_REG_OFFSET(MP0, 0, mmMP0_SMN_C2PMSG_101), in psp_v12_0_ring_stop()
258 ret = psp_wait_for(psp, SOC15_REG_OFFSET(MP0, 0, mmMP0_SMN_C2PMSG_64), in psp_v12_0_ring_stop()
264 static int psp_v12_0_ring_destroy(struct psp_context *psp, in psp_v12_0_ring_destroy() argument
268 struct psp_ring *ring = &psp->km_ring; in psp_v12_0_ring_destroy()
269 struct amdgpu_device *adev = psp->adev; in psp_v12_0_ring_destroy()
271 ret = psp_v12_0_ring_stop(psp, ring_type); in psp_v12_0_ring_destroy()
282 static int psp_v12_0_mode1_reset(struct psp_context *psp) in psp_v12_0_mode1_reset() argument
286 struct amdgpu_device *adev = psp->adev; in psp_v12_0_mode1_reset()
290 ret = psp_wait_for(psp, offset, 0x80000000, 0x8000FFFF, false); in psp_v12_0_mode1_reset()
304 ret = psp_wait_for(psp, offset, 0x80000000, 0x80000000, false); in psp_v12_0_mode1_reset()
316 static uint32_t psp_v12_0_ring_get_wptr(struct psp_context *psp) in psp_v12_0_ring_get_wptr() argument
319 struct amdgpu_device *adev = psp->adev; in psp_v12_0_ring_get_wptr()
329 static void psp_v12_0_ring_set_wptr(struct psp_context *psp, uint32_t value) in psp_v12_0_ring_set_wptr() argument
331 struct amdgpu_device *adev = psp->adev; in psp_v12_0_ring_set_wptr()
352 void psp_v12_0_set_psp_funcs(struct psp_context *psp) in psp_v12_0_set_psp_funcs() argument
354 psp->funcs = &psp_v12_0_funcs; in psp_v12_0_set_psp_funcs()