Lines Matching refs:dma_buf
501 struct hbq_dmabuf *dma_buf; in lpfc_sli4_rb_alloc() local
503 dma_buf = kzalloc(sizeof(struct hbq_dmabuf), GFP_KERNEL); in lpfc_sli4_rb_alloc()
504 if (!dma_buf) in lpfc_sli4_rb_alloc()
507 dma_buf->hbuf.virt = pci_pool_alloc(phba->lpfc_hrb_pool, GFP_KERNEL, in lpfc_sli4_rb_alloc()
508 &dma_buf->hbuf.phys); in lpfc_sli4_rb_alloc()
509 if (!dma_buf->hbuf.virt) { in lpfc_sli4_rb_alloc()
510 kfree(dma_buf); in lpfc_sli4_rb_alloc()
513 dma_buf->dbuf.virt = pci_pool_alloc(phba->lpfc_drb_pool, GFP_KERNEL, in lpfc_sli4_rb_alloc()
514 &dma_buf->dbuf.phys); in lpfc_sli4_rb_alloc()
515 if (!dma_buf->dbuf.virt) { in lpfc_sli4_rb_alloc()
516 pci_pool_free(phba->lpfc_hrb_pool, dma_buf->hbuf.virt, in lpfc_sli4_rb_alloc()
517 dma_buf->hbuf.phys); in lpfc_sli4_rb_alloc()
518 kfree(dma_buf); in lpfc_sli4_rb_alloc()
521 dma_buf->size = LPFC_BPL_SIZE; in lpfc_sli4_rb_alloc()
522 return dma_buf; in lpfc_sli4_rb_alloc()