Lines Matching refs:aeq
216 struct irdma_aeq *aeq = &rf->aeq; in irdma_process_aeq() local
217 struct irdma_sc_aeq *sc_aeq = &aeq->sc_aeq; in irdma_process_aeq()
612 struct irdma_aeq *aeq = &rf->aeq; in irdma_destroy_virt_aeq() local
613 u32 pg_cnt = DIV_ROUND_UP(aeq->mem.size, PAGE_SIZE); in irdma_destroy_virt_aeq()
614 dma_addr_t *pg_arr = (dma_addr_t *)aeq->palloc.level1.addr; in irdma_destroy_virt_aeq()
617 irdma_free_pble(rf->pble_rsrc, &aeq->palloc); in irdma_destroy_virt_aeq()
618 vfree(aeq->mem.va); in irdma_destroy_virt_aeq()
632 struct irdma_aeq *aeq = &rf->aeq; in irdma_destroy_aeq() local
642 aeq->sc_aeq.size = 0; in irdma_destroy_aeq()
643 status = irdma_cqp_aeq_cmd(dev, &aeq->sc_aeq, IRDMA_OP_AEQ_DESTROY); in irdma_destroy_aeq()
648 if (aeq->virtual_map) { in irdma_destroy_aeq()
651 dma_free_coherent(dev->hw->device, aeq->mem.size, aeq->mem.va, in irdma_destroy_aeq()
652 aeq->mem.pa); in irdma_destroy_aeq()
653 aeq->mem.va = NULL; in irdma_destroy_aeq()
1340 struct irdma_aeq *aeq = &rf->aeq; in irdma_create_virt_aeq() local
1348 aeq->mem.size = sizeof(struct irdma_sc_aeqe) * size; in irdma_create_virt_aeq()
1349 aeq->mem.va = vzalloc(aeq->mem.size); in irdma_create_virt_aeq()
1351 if (!aeq->mem.va) in irdma_create_virt_aeq()
1354 pg_cnt = DIV_ROUND_UP(aeq->mem.size, PAGE_SIZE); in irdma_create_virt_aeq()
1355 status = irdma_get_pble(rf->pble_rsrc, &aeq->palloc, pg_cnt, true); in irdma_create_virt_aeq()
1357 vfree(aeq->mem.va); in irdma_create_virt_aeq()
1361 pg_arr = (dma_addr_t *)aeq->palloc.level1.addr; in irdma_create_virt_aeq()
1362 status = irdma_map_vm_page_list(&rf->hw, aeq->mem.va, pg_arr, pg_cnt); in irdma_create_virt_aeq()
1364 irdma_free_pble(rf->pble_rsrc, &aeq->palloc); in irdma_create_virt_aeq()
1365 vfree(aeq->mem.va); in irdma_create_virt_aeq()
1383 struct irdma_aeq *aeq = &rf->aeq; in irdma_create_aeq() local
1393 aeq->mem.size = ALIGN(sizeof(struct irdma_sc_aeqe) * aeq_size, in irdma_create_aeq()
1395 aeq->mem.va = dma_alloc_coherent(dev->hw->device, aeq->mem.size, in irdma_create_aeq()
1396 &aeq->mem.pa, in irdma_create_aeq()
1398 if (aeq->mem.va) in irdma_create_aeq()
1407 aeq->virtual_map = info.virtual_map; in irdma_create_aeq()
1409 info.first_pm_pbl_idx = aeq->palloc.level1.idx; in irdma_create_aeq()
1412 info.aeqe_base = aeq->mem.va; in irdma_create_aeq()
1413 info.aeq_elem_pa = aeq->mem.pa; in irdma_create_aeq()
1417 status = irdma_sc_aeq_init(&aeq->sc_aeq, &info); in irdma_create_aeq()
1421 status = irdma_cqp_aeq_cmd(dev, &aeq->sc_aeq, IRDMA_OP_AEQ_CREATE); in irdma_create_aeq()
1428 if (aeq->virtual_map) { in irdma_create_aeq()
1431 dma_free_coherent(dev->hw->device, aeq->mem.size, aeq->mem.va, in irdma_create_aeq()
1432 aeq->mem.pa); in irdma_create_aeq()
1433 aeq->mem.va = NULL; in irdma_create_aeq()