63 vmxnet3_tx_comp *tx_comp;
108 vmxnet3_tx_desc *txd = 0;
109 u32 desc_idx, generation, first_idx;
131 u16 space_needed = 1,
i;
142 while (b->
flags & VLIB_BUFFER_NEXT_PRESENT)
158 VMXNET3_TX_ERROR_NO_FREE_SLOTS, 1);
175 for (
i = 0;
i < space_needed;
i++)
197 ASSERT (vd->gso_enable == 1);
200 if (b0->
flags & VNET_BUFFER_F_IS_IP6)
213 txq->
tx_desc[first_idx].flags[1] = hdr_len;
218 asm volatile (
"":::
"memory");
234 return (
frame->n_vectors - n_left);
static_always_inline void vmxnet3_tx_ring_advance_consume(vmxnet3_txq_t *txq)
u32 flags
buffer flags: VLIB_BUFFER_FREE_LIST_INDEX_MASK: bits used to store free list index, VLIB_BUFFER_IS_TRACED: trace this buffer.
static uword vlib_buffer_get_current_pa(vlib_main_t *vm, vlib_buffer_t *b)
static void vlib_buffer_free(vlib_main_t *vm, u32 *buffers, u32 n_buffers)
Free buffers Frees the entire buffer chain for each buffer.
static void vlib_error_count(vlib_main_t *vm, uword node_index, uword counter, uword increment)
static_always_inline void clib_spinlock_unlock_if_init(clib_spinlock_t *p)
u16 current_length
Nbytes between current data and the end of this buffer.
vmxnet3_main_t vmxnet3_main
#define VMXNET3_TXF_OM(x)
VNET_DEVICE_CLASS_TX_FN() vmxnet3_device_class(vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *frame)
#define static_always_inline
#define vec_elt_at_index(v, i)
Get vector value at index i checking that i is in bounds.
#define VNET_DEVICE_CLASS_TX_FN(devclass)
#define pool_elt_at_index(p, i)
Returns pointer to element at given index.
#define VMXNET3_TXC_INDEX
static_always_inline u16 vmxnet3_tx_ring_space_left(vmxnet3_txq_t *txq)
static_always_inline void vmxnet3_tx_ring_advance_produce(vmxnet3_txq_t *txq)
vmxnet3_tx_comp_ring tx_comp_ring
vmxnet3_tx_comp * tx_comp
sll srl srl sll sra u16x4 i
vlib_main_t vlib_node_runtime_t * node
static_always_inline void vmxnet3_txq_release(vlib_main_t *vm, vmxnet3_device_t *vd, vmxnet3_txq_t *txq)
static_always_inline void vmxnet3_tx_comp_ring_advance_next(vmxnet3_txq_t *txq)
u32 next_buffer
Next buffer for this linked-list of buffers.
vlib_main_t vlib_node_runtime_t vlib_frame_t * frame
#define VLIB_BUFFER_TRACE_TRAJECTORY_INIT(b)
VLIB buffer representation.
vmxnet3_tx_desc * tx_desc
static void * vlib_frame_vector_args(vlib_frame_t *f)
Get pointer to frame vector data.
vmxnet3_device_t * devices
#define VMXNET3_TXF_MSSCOF(x)
static void vlib_buffer_free_one(vlib_main_t *vm, u32 buffer_index)
Free one buffer Shorthand to free a single buffer chain.
static_always_inline void clib_spinlock_lock_if_init(clib_spinlock_t *p)
static vlib_buffer_t * vlib_get_buffer(vlib_main_t *vm, u32 buffer_index)
Translate buffer index into buffer pointer.
static_always_inline void vmxnet3_reg_write_inline(vmxnet3_device_t *vd, u8 bar, u32 addr, u32 val)