Lines Matching defs:fifo

30 #include <dev/nxge/include/xgehal-fifo.h>
56 xge_hal_fifo_t *fifo = (xge_hal_fifo_t *)channelh;
57 xge_hal_fifo_hw_pair_t *hw_pair = fifo->hw_pair;
73 xge_os_dma_sync(fifo->channel.pdev,
81 xge_os_pio_mem_write64(fifo->channel.pdev,
82 fifo->channel.regh1,
89 ctrl |= fifo->no_snoop_bits;
112 xge_os_pio_mem_write64(fifo->channel.pdev, fifo->channel.regh1,
127 fifo->channel.stats.total_posts++;
128 fifo->channel.usage_cnt++;
129 if (fifo->channel.stats.usage_max < fifo->channel.usage_cnt)
130 fifo->channel.stats.usage_max = fifo->channel.usage_cnt;
241 * xge_hal_fifo_dtr_reserve_many- Reserve fifo descriptors which span more
248 * Reserve TxDL(s) (that is, fifo descriptor)
269 xge_hal_fifo_t *fifo = (xge_hal_fifo_t *)channelh;
270 int max_frags = fifo->config->max_frags;
277 xge_assert(frags < (fifo->txdl_per_memblock * max_frags));
279 xge_os_spin_lock(&fifo->channel.reserve_lock);
281 xge_os_spin_lock_irq(&fifo->channel.reserve_lock, flags);
349 xge_os_spin_unlock(&fifo->channel.reserve_lock);
351 xge_os_spin_unlock_irq(&fifo->channel.reserve_lock, flags);
357 xge_hal_stats_channel_info_t *statsp = &fifo->channel.stats;
385 * xge_hal_fifo_dtr_reserve - Reserve fifo descriptor.
390 * Reserve a single TxDL (that is, fifo descriptor)
396 * for lengthy (e.g., LSO) transmit operation. A single fifo descriptor
397 * carries up to configured number (fifo.max_frags) of contiguous buffers.
460 * xge_hal_fifo_dtr_reserve_sp - Reserve fifo descriptor and store it in
490 * xge_hal_fifo_dtr_post - Post descriptor on the fifo channel.
497 * Post descriptor on the 'fifo' type channel for transmission.
507 xge_hal_fifo_t *fifo = (xge_hal_fifo_t *)channelh;
519 txdp_first->control_2 |= fifo->interrupt_type;
525 xge_os_spin_lock(fifo->post_lock_ptr);
527 xge_os_spin_lock_irq(fifo->post_lock_ptr, flags);
534 xge_os_spin_unlock(fifo->post_lock_ptr);
536 xge_os_spin_unlock_irq(fifo->post_lock_ptr, flags);
541 * xge_hal_fifo_dtr_post_many - Post multiple descriptors on fifo
544 * @num: Number of descriptors (i.e., fifo TxDLs) in the %dtrs[].
549 * Post multi-descriptor on the fifo channel. The operation is atomic:
561 xge_hal_fifo_t *fifo = (xge_hal_fifo_t *)channelh;
573 txdp_first->control_2 |= fifo->interrupt_type;
613 fifo->channel.stats.total_posts_many++;
656 xge_hal_fifo_t *fifo = (xge_hal_fifo_t *)channelh;
673 xge_os_dma_sync(fifo->channel.pdev,
693 if (fifo->channel.usage_cnt > 0)
694 fifo->channel.usage_cnt--;
794 * in fifo descriptor.
809 * All three APIs fill in the fields of the fifo descriptor,
842 xge_hal_fifo_t *fifo = (xge_hal_fifo_t *)channelh;
861 misaligned_size <= fifo->config->alignment_size);
869 if (txdl_priv->align_used_frags >= fifo->config->max_aligned_frags) {
878 fifo->channel.stats.total_buffers++;
881 txdl_priv->align_vaddr_start += fifo->config->alignment_size;
886 xge_os_dma_sync(fifo->channel.pdev,
903 fifo->channel.stats.total_buffers++;
933 xge_hal_fifo_t *fifo = (xge_hal_fifo_t *)channelh;
943 if (used + (unsigned int)size > (unsigned int)fifo->align_size)
949 fifo->channel.stats.copied_frags++;
974 xge_hal_fifo_t *fifo = (xge_hal_fifo_t *)channelh;
979 xge_assert(frag_idx < fifo->config->max_frags);
993 fifo->channel.stats.total_buffers++;
994 fifo->channel.stats.copied_buffers++;
1000 xge_os_dma_sync(fifo->channel.pdev,
1026 * All three APIs fill in the fields of the fifo descriptor,
1045 xge_hal_fifo_t *fifo = (xge_hal_fifo_t *)channelh;
1066 fifo->channel.stats.total_buffers++;
1080 * All these APIs fill in the fields of the fifo descriptor,
1108 * All these APIs fill in the fields of the fifo descriptor,