#include <vnet/vnet.h>
#include <vlib/vlib.h>
#include <vppinfra/error.h>
#include <cndp/cndp.h>
#include <cndp/cne.h>
#include <cndp/xskdev.h>
VNET_DEVICE_CLASS_TX_FN (cndp_device_class)
(vlib_main_t *vm, vlib_node_runtime_t *node, vlib_frame_t *f)
{
uword n_sent = 0;
vlib_buffer_t *tx_pkts[VLIB_FRAME_SIZE];
cndp_main_t *cmp = &cndp_main;
vnet_interface_output_runtime_t *rd = (void *)node->runtime_data;
u32 n_packets = f->n_vectors;
u32 thread_index = vm->thread_index;
cndp_device_t *d = cmp->devices[rd->dev_instance];
cndp_lport_t *port =
vec_elt_at_index (d->lports, thread_index % pool_elts (d->lports));
ASSERT (n_packets <= VLIB_FRAME_SIZE);
vlib_get_buffers (vm, vlib_frame_vector_args (f), tx_pkts, n_packets);
if (tid < 0)
{
char *name =
(char *)format (0, "vpp_thread_%d", vlib_get_thread_index ());
}
return n_sent;
}
VNET_DEVICE_CLASS (cndp_device_class) = {
.name = "cndp",
.format_device_name = format_cndp_device_name,
};
CNDP_API int cne_id(void)
CNDP_API int cne_register(const char *name)
CNDP_API __cne_always_inline uint16_t xskdev_tx_burst(xskdev_info_t *xi, void **bufs, uint16_t nb_pkts)