Lines Matching refs:msg_tx_ring
183 struct rio_msg_tx_ring msg_tx_ring; member
227 int slot = (dqp - rmu->msg_tx_ring.phys) >> 5; in fsl_rio_tx_handler()
229 port->outb_msg[0].mcback(port, rmu->msg_tx_ring.dev_id, in fsl_rio_tx_handler()
665 struct rio_tx_desc *desc = (struct rio_tx_desc *)rmu->msg_tx_ring.virt in fsl_add_outb_message()
666 + rmu->msg_tx_ring.tx_slot; in fsl_add_outb_message()
677 memcpy(rmu->msg_tx_ring.virt_buffer[rmu->msg_tx_ring.tx_slot], buffer, in fsl_add_outb_message()
680 memset(rmu->msg_tx_ring.virt_buffer[rmu->msg_tx_ring.tx_slot] in fsl_add_outb_message()
694 | rmu->msg_tx_ring.phys_buffer[rmu->msg_tx_ring.tx_slot]; in fsl_add_outb_message()
701 if (++rmu->msg_tx_ring.tx_slot == rmu->msg_tx_ring.size) in fsl_add_outb_message()
702 rmu->msg_tx_ring.tx_slot = 0; in fsl_add_outb_message()
733 rmu->msg_tx_ring.dev_id = dev_id; in fsl_open_outb_mbox()
734 rmu->msg_tx_ring.size = entries; in fsl_open_outb_mbox()
736 for (i = 0; i < rmu->msg_tx_ring.size; i++) { in fsl_open_outb_mbox()
737 rmu->msg_tx_ring.virt_buffer[i] = in fsl_open_outb_mbox()
739 &rmu->msg_tx_ring.phys_buffer[i], GFP_KERNEL); in fsl_open_outb_mbox()
740 if (!rmu->msg_tx_ring.virt_buffer[i]) { in fsl_open_outb_mbox()
742 for (j = 0; j < rmu->msg_tx_ring.size; j++) in fsl_open_outb_mbox()
743 if (rmu->msg_tx_ring.virt_buffer[j]) in fsl_open_outb_mbox()
746 rmu->msg_tx_ring. in fsl_open_outb_mbox()
748 rmu->msg_tx_ring. in fsl_open_outb_mbox()
755 rmu->msg_tx_ring.virt = dma_alloc_coherent(priv->dev, in fsl_open_outb_mbox()
756 rmu->msg_tx_ring.size * RIO_MSG_DESC_SIZE, in fsl_open_outb_mbox()
757 &rmu->msg_tx_ring.phys, in fsl_open_outb_mbox()
759 if (!rmu->msg_tx_ring.virt) { in fsl_open_outb_mbox()
763 rmu->msg_tx_ring.tx_slot = 0; in fsl_open_outb_mbox()
766 out_be32(&rmu->msg_regs->odqdpar, rmu->msg_tx_ring.phys); in fsl_open_outb_mbox()
767 out_be32(&rmu->msg_regs->odqepar, rmu->msg_tx_ring.phys); in fsl_open_outb_mbox()
803 rmu->msg_tx_ring.size * RIO_MSG_DESC_SIZE, in fsl_open_outb_mbox()
804 rmu->msg_tx_ring.virt, rmu->msg_tx_ring.phys); in fsl_open_outb_mbox()
807 for (i = 0; i < rmu->msg_tx_ring.size; i++) in fsl_open_outb_mbox()
809 rmu->msg_tx_ring.virt_buffer[i], in fsl_open_outb_mbox()
810 rmu->msg_tx_ring.phys_buffer[i]); in fsl_open_outb_mbox()
833 rmu->msg_tx_ring.size * RIO_MSG_DESC_SIZE, in fsl_close_outb_mbox()
834 rmu->msg_tx_ring.virt, rmu->msg_tx_ring.phys); in fsl_close_outb_mbox()