61 vmxnet3_tx_comp *tx_comp;
106 vmxnet3_tx_desc *txd = 0;
107 u32 desc_idx, generation, first_idx;
129 u16 space_needed = 1,
i;
139 while (b->
flags & VLIB_BUFFER_NEXT_PRESENT)
155 VMXNET3_TX_ERROR_NO_FREE_SLOTS, 1);
172 for (
i = 0;
i < space_needed;
i++)
194 ASSERT (vd->gso_enable == 1);
205 txd->flags[1] = hdr_len;
210 asm volatile (
"":::
"memory");
226 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
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.
#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)
vlib_main_t vlib_node_runtime_t vlib_frame_t * frame
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)