Fixes port number in mbuf structure when using with eth_af_packet
Signed-off-by: Pavel Krauz <pavel.krauz@anritsu.com>
unsigned int framenum;
struct rte_mempool *mb_pool;
+ uint8_t in_port;
volatile unsigned long rx_pkts;
volatile unsigned long err_pkts;
ppd->tp_status = TP_STATUS_KERNEL;
if (++framenum >= framecount)
framenum = 0;
+ mbuf->port = pkt_q->in_port;
/* account for the receive frame */
bufs[i] = mbuf;
}
dev->data->rx_queues[rx_queue_id] = pkt_q;
+ pkt_q->in_port = dev->data->port_id;
return 0;
}