Lines Matching refs:mmio_read
799 struct ena_com_mmio_read *mmio_read = &ena_dev->mmio_read; in ena_com_reg_bar_read32() local
801 mmio_read->read_resp; in ena_com_reg_bar_read32()
804 u32 timeout = mmio_read->reg_read_to; in ena_com_reg_bar_read32()
812 if (!mmio_read->readless_supported) in ena_com_reg_bar_read32()
815 spin_lock_irqsave(&mmio_read->lock, flags); in ena_com_reg_bar_read32()
816 mmio_read->seq_num++; in ena_com_reg_bar_read32()
818 read_resp->req_id = mmio_read->seq_num + 0xDEAD; in ena_com_reg_bar_read32()
821 mmio_read_reg |= mmio_read->seq_num & in ena_com_reg_bar_read32()
827 if (READ_ONCE(read_resp->req_id) == mmio_read->seq_num) in ena_com_reg_bar_read32()
836 mmio_read->seq_num, offset, read_resp->req_id, read_resp->reg_off); in ena_com_reg_bar_read32()
848 spin_unlock_irqrestore(&mmio_read->lock, flags); in ena_com_reg_bar_read32()
1669 struct ena_com_mmio_read *mmio_read = &ena_dev->mmio_read; in ena_com_mmio_reg_read_request_init() local
1671 spin_lock_init(&mmio_read->lock); in ena_com_mmio_reg_read_request_init()
1672 mmio_read->read_resp = dma_alloc_coherent(ena_dev->dmadev, sizeof(*mmio_read->read_resp), in ena_com_mmio_reg_read_request_init()
1673 &mmio_read->read_resp_dma_addr, GFP_KERNEL); in ena_com_mmio_reg_read_request_init()
1674 if (unlikely(!mmio_read->read_resp)) in ena_com_mmio_reg_read_request_init()
1679 mmio_read->read_resp->req_id = 0x0; in ena_com_mmio_reg_read_request_init()
1680 mmio_read->seq_num = 0x0; in ena_com_mmio_reg_read_request_init()
1681 mmio_read->readless_supported = true; in ena_com_mmio_reg_read_request_init()
1692 struct ena_com_mmio_read *mmio_read = &ena_dev->mmio_read; in ena_com_set_mmio_read_mode() local
1694 mmio_read->readless_supported = readless_supported; in ena_com_set_mmio_read_mode()
1699 struct ena_com_mmio_read *mmio_read = &ena_dev->mmio_read; in ena_com_mmio_reg_read_request_destroy() local
1704 dma_free_coherent(ena_dev->dmadev, sizeof(*mmio_read->read_resp), mmio_read->read_resp, in ena_com_mmio_reg_read_request_destroy()
1705 mmio_read->read_resp_dma_addr); in ena_com_mmio_reg_read_request_destroy()
1707 mmio_read->read_resp = NULL; in ena_com_mmio_reg_read_request_destroy()
1712 struct ena_com_mmio_read *mmio_read = &ena_dev->mmio_read; in ena_com_mmio_reg_read_request_write_dev_addr() local
1715 addr_low = ENA_DMA_ADDR_TO_UINT32_LOW(mmio_read->read_resp_dma_addr); in ena_com_mmio_reg_read_request_write_dev_addr()
1716 addr_high = ENA_DMA_ADDR_TO_UINT32_HIGH(mmio_read->read_resp_dma_addr); in ena_com_mmio_reg_read_request_write_dev_addr()