Lines Matching full:sdma
76 for (i = 0; i < adev->sdma.num_instances; i++) { in cik_sdma_free_microcode()
77 release_firmware(adev->sdma.instance[i].fw); in cik_sdma_free_microcode()
78 adev->sdma.instance[i].fw = NULL; in cik_sdma_free_microcode()
83 * sDMA - System DMA
91 * (ring buffer, IBs, etc.), but sDMA has it's own
93 * used by the CP. sDMA supports copying data, writing
135 for (i = 0; i < adev->sdma.num_instances; i++) { in cik_sdma_init_microcode()
140 err = request_firmware(&adev->sdma.instance[i].fw, fw_name, adev->dev); in cik_sdma_init_microcode()
143 err = amdgpu_ucode_validate(adev->sdma.instance[i].fw); in cik_sdma_init_microcode()
148 for (i = 0; i < adev->sdma.num_instances; i++) { in cik_sdma_init_microcode()
149 release_firmware(adev->sdma.instance[i].fw); in cik_sdma_init_microcode()
150 adev->sdma.instance[i].fw = NULL; in cik_sdma_init_microcode()
203 struct amdgpu_sdma_instance *sdma = amdgpu_sdma_get_instance_from_ring(ring); in cik_sdma_ring_insert_nop() local
207 if (sdma && sdma->burst_nop && (i == 0)) in cik_sdma_ring_insert_nop()
317 for (i = 0; i < adev->sdma.num_instances; i++) { in cik_sdma_gfx_stop()
374 for (i = 0; i < adev->sdma.num_instances; i++) { in cik_ctx_switch_enable()
412 for (i = 0; i < adev->sdma.num_instances; i++) { in cik_sdma_enable()
437 for (i = 0; i < adev->sdma.num_instances; i++) { in cik_sdma_gfx_resume()
438 ring = &adev->sdma.instance[i].ring; in cik_sdma_gfx_resume()
443 /* SDMA GFX */ in cik_sdma_gfx_resume()
446 /* XXX SDMA RLC - todo */ in cik_sdma_gfx_resume()
502 for (i = 0; i < adev->sdma.num_instances; i++) { in cik_sdma_gfx_resume()
503 ring = &adev->sdma.instance[i].ring; in cik_sdma_gfx_resume()
530 * cik_sdma_load_microcode - load the sDMA ME ucode
547 for (i = 0; i < adev->sdma.num_instances; i++) { in cik_sdma_load_microcode()
548 if (!adev->sdma.instance[i].fw) in cik_sdma_load_microcode()
550 hdr = (const struct sdma_firmware_header_v1_0 *)adev->sdma.instance[i].fw->data; in cik_sdma_load_microcode()
553 adev->sdma.instance[i].fw_version = le32_to_cpu(hdr->header.ucode_version); in cik_sdma_load_microcode()
554 adev->sdma.instance[i].feature_version = le32_to_cpu(hdr->ucode_feature_version); in cik_sdma_load_microcode()
555 if (adev->sdma.instance[i].feature_version >= 20) in cik_sdma_load_microcode()
556 adev->sdma.instance[i].burst_nop = true; in cik_sdma_load_microcode()
558 (adev->sdma.instance[i].fw->data + le32_to_cpu(hdr->header.ucode_array_offset_bytes)); in cik_sdma_load_microcode()
562 WREG32(mmSDMA0_UCODE_ADDR + sdma_offsets[i], adev->sdma.instance[i].fw_version); in cik_sdma_load_microcode()
586 /* enable sdma ring preemption */ in cik_sdma_start()
724 * Update PTEs by copying them from the GART using sDMA (CIK).
751 * Update PTEs by writing them manually using sDMA (CIK).
772 * cik_sdma_vm_set_pte_pde - update the page tables using sDMA
781 * Update the page tables using sDMA (CIK).
809 struct amdgpu_sdma_instance *sdma = amdgpu_sdma_get_instance_from_ring(ring); in cik_sdma_ring_pad_ib() local
815 if (sdma && sdma->burst_nop && (i == 0)) in cik_sdma_ring_pad_ib()
849 * cik_sdma_ring_emit_vm_flush - cik vm flush using sDMA
856 * using sDMA (CIK).
935 adev->sdma.num_instances = SDMA_MAX_INSTANCE; in cik_sdma_early_init()
953 DRM_ERROR("Failed to load sdma firmware!\n"); in cik_sdma_sw_init()
957 /* SDMA trap event */ in cik_sdma_sw_init()
959 &adev->sdma.trap_irq); in cik_sdma_sw_init()
963 /* SDMA Privileged inst */ in cik_sdma_sw_init()
965 &adev->sdma.illegal_inst_irq); in cik_sdma_sw_init()
969 /* SDMA Privileged inst */ in cik_sdma_sw_init()
971 &adev->sdma.illegal_inst_irq); in cik_sdma_sw_init()
975 for (i = 0; i < adev->sdma.num_instances; i++) { in cik_sdma_sw_init()
976 ring = &adev->sdma.instance[i].ring; in cik_sdma_sw_init()
978 sprintf(ring->name, "sdma%d", i); in cik_sdma_sw_init()
980 &adev->sdma.trap_irq, in cik_sdma_sw_init()
996 for (i = 0; i < adev->sdma.num_instances; i++) in cik_sdma_sw_fini()
997 amdgpu_ring_fini(&adev->sdma.instance[i].ring); in cik_sdma_sw_fini()
1162 DRM_DEBUG("IH: SDMA trap\n"); in cik_sdma_process_trap_irq()
1167 amdgpu_fence_process(&adev->sdma.instance[0].ring); in cik_sdma_process_trap_irq()
1180 amdgpu_fence_process(&adev->sdma.instance[1].ring); in cik_sdma_process_trap_irq()
1201 DRM_ERROR("Illegal instruction in SDMA command stream\n"); in cik_sdma_process_illegal_inst_irq()
1203 drm_sched_fault(&adev->sdma.instance[instance_id].ring.sched); in cik_sdma_process_illegal_inst_irq()
1276 for (i = 0; i < adev->sdma.num_instances; i++) { in cik_sdma_set_ring_funcs()
1277 adev->sdma.instance[i].ring.funcs = &cik_sdma_ring_funcs; in cik_sdma_set_ring_funcs()
1278 adev->sdma.instance[i].ring.me = i; in cik_sdma_set_ring_funcs()
1293 adev->sdma.trap_irq.num_types = AMDGPU_SDMA_IRQ_LAST; in cik_sdma_set_irq_funcs()
1294 adev->sdma.trap_irq.funcs = &cik_sdma_trap_irq_funcs; in cik_sdma_set_irq_funcs()
1295 adev->sdma.illegal_inst_irq.funcs = &cik_sdma_illegal_inst_irq_funcs; in cik_sdma_set_irq_funcs()
1299 * cik_sdma_emit_copy_buffer - copy buffer using the sDMA engine
1327 * cik_sdma_emit_fill_buffer - fill buffer using the sDMA engine
1361 adev->mman.buffer_funcs_ring = &adev->sdma.instance[0].ring; in cik_sdma_set_buffer_funcs()
1377 for (i = 0; i < adev->sdma.num_instances; i++) { in cik_sdma_set_vm_pte_funcs()
1379 &adev->sdma.instance[i].ring.sched; in cik_sdma_set_vm_pte_funcs()
1381 adev->vm_manager.vm_pte_num_scheds = adev->sdma.num_instances; in cik_sdma_set_vm_pte_funcs()