src/dpdk/drivers/net/i40e/i40e_rxtx_vec_neon.c
static uint16_t
i40e_recv_scattered_burst_vec(void *rx_queue, struct rte_mbuf **rx_pkts,
			      uint16_t nb_pkts)
{

	struct i40e_rx_queue *rxq = rx_queue;
	uint8_t split_flags[RTE_I40E_VPMD_RX_BURST] = {0};

	/* get some new buffers */
	uint16_t nb_bufs = _recv_raw_pkts_vec(rxq, rx_pkts, nb_pkts,
			split_flags);
	if (nb_bufs == 0)
		return 0;

	/* happy day case, full burst + no packets to be joined */
	const uint64_t *split_fl64 = (uint64_t *)split_flags;

	if (rxq->pkt_first_seg == NULL &&
			split_fl64[0] == 0 && split_fl64[1] == 0 &&
			split_fl64[2] == 0 && split_fl64[3] == 0)
		return nb_bufs;

	/* reassemble any packets that need reassembly*/
	unsigned i = 0;

	if (rxq->pkt_first_seg == NULL) {
		/* find the first split flag, and only reassemble then*/
		while (i < nb_bufs && !split_flags[i])
			i++;
		if (i == nb_bufs)
			return nb_bufs;
		rxq->pkt_first_seg = rx_pkts[i];
	}
	return i + reassemble_packets(rxq, &rx_pkts[i], nb_bufs - i,
		&split_flags[i]);
}
/**
 * vPMD receive routine that reassembles single burst of 32 scattered packets
 *
 * Notice:
 * - nb_pkts < RTE_I40E_DESCS_PER_LOOP, just return no packet
 */
vPMD receive routine that reassembles single burst of 32 scattered packets
Notice:
- nb_pkts < RTE_I40E_DESCS_PER_LOOP, just return no packet
vPMD receive routine that reassembles single burst of 32 scattered packets Notice : - nb_pkts < RTE_I40E_DESCS_PER_LOOP just return no packet
static uint16_t
i40e_recv_scattered_burst_vec(void *rx_queue, struct rte_mbuf **rx_pkts,
			      uint16_t nb_pkts)
{
	struct i40e_rx_queue *rxq = rx_queue;
	uint8_t split_flags[RTE_I40E_VPMD_RX_BURST] = {0};
	uint16_t nb_bufs = _recv_raw_pkts_vec(rxq, rx_pkts, nb_pkts,
			split_flags);
	if (nb_bufs == 0)
		return 0;
	const uint64_t *split_fl64 = (uint64_t *)split_flags;
	if (rxq->pkt_first_seg == NULL &&
			split_fl64[0] == 0 && split_fl64[1] == 0 &&
			split_fl64[2] == 0 && split_fl64[3] == 0)
		return nb_bufs;
	unsigned i = 0;
	if (rxq->pkt_first_seg == NULL) {
		while (i < nb_bufs && !split_flags[i])
			i++;
		if (i == nb_bufs)
			return nb_bufs;
		rxq->pkt_first_seg = rx_pkts[i];
	}
	return i + reassemble_packets(rxq, &rx_pkts[i], nb_bufs - i,
		&split_flags[i]);
}
static uint16_t i40e_recv_scattered_burst_vec ( void * rx_queue , struct rte_mbuf * * rx_pkts , uint16_t nb_pkts ) { struct i40e_rx_queue * rxq = rx_queue ; uint8_t split_flags [ RTE_I40E_VPMD_RX_BURST ] = { 0 } ; uint16_t nb_bufs = _recv_raw_pkts_vec ( rxq , rx_pkts , nb_pkts , split_flags ) ; if ( nb_bufs == 0 ) return 0 ; const uint64_t * split_fl64 = ( uint64_t * ) split_flags ; if ( rxq -> pkt_first_seg == NULL && split_fl64 [ 0 ] == 0 && split_fl64 [ 1 ] == 0 && split_fl64 [ 2 ] == 0 && split_fl64 [ 3 ] == 0 ) return nb_bufs ; unsigned i = 0 ; if ( rxq -> pkt_first_seg == NULL ) { while ( i < nb_bufs && ! split_flags [ i ] ) i ++ ; if ( i == nb_bufs ) return nb_bufs ; rxq -> pkt_first_seg = rx_pkts [ i ] ; } return i + reassemble_packets ( rxq , & rx_pkts [ i ] , nb_bufs - i , & split_flags [ i ] ) ; }
vPMD receive routine that reassembles single burst of 32 scattered packets
 Notice:
 - nb_pkts < RTE_I40E_DESCS_PER_LOOP, just return no packet
vPMD receive routine that reassembles single burst of 32 scattered packets Notice : - nb_pkts < RTE_I40E_DESCS_PER_LOOP just return no packet
/* get some new buffers */ /* happy day case, full burst + no packets to be joined */ /* reassemble any packets that need reassembly*/ /* find the first split flag, and only reassemble then*/