X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=drivers%2Fnet%2Fmlx5%2Fmlx5_rxtx_vec_sse.h;h=adf991f013929a0d4705521df9dadbd32a32cfba;hb=8d7d4fcdcabe7f71ea79e62ac8d23257099623e6;hp=661fa7273c7eafd8d84c5def9d61f2b7d50fb9de;hpb=b57e414b48c0da58e445e3d2e92a05758632147d;p=dpdk.git diff --git a/drivers/net/mlx5/mlx5_rxtx_vec_sse.h b/drivers/net/mlx5/mlx5_rxtx_vec_sse.h index 661fa7273c..adf991f013 100644 --- a/drivers/net/mlx5/mlx5_rxtx_vec_sse.h +++ b/drivers/net/mlx5/mlx5_rxtx_vec_sse.h @@ -565,7 +565,7 @@ rxq_cq_process_v(struct mlx5_rxq_data *rxq, volatile struct mlx5_cqe *cq, const __m128i flow_mark_adj = _mm_set_epi32(rxq->mark * (-1), 0, 0, 0); /* * A. load first Qword (8bytes) in one loop. - * B. copy 4 mbuf pointers from elts ring to returing pkts. + * B. copy 4 mbuf pointers from elts ring to returning pkts. * C. load remained CQE data and extract necessary fields. * Final 16bytes cqes[] extracted from original 64bytes CQE has the * following structure: @@ -769,25 +769,19 @@ rxq_cq_process_v(struct mlx5_rxq_data *rxq, volatile struct mlx5_cqe *cq, /* This code is subject for futher optimization. */ int32_t offs = rxq->flow_meta_offset; uint32_t mask = rxq->flow_meta_port_mask; - uint32_t shift = - __builtin_popcount(rxq->flow_meta_port_mask); *RTE_MBUF_DYNFIELD(pkts[pos], offs, uint32_t *) = - (rte_be_to_cpu_32 - (cq[pos].flow_table_metadata) >> shift) & - mask; + rte_be_to_cpu_32 + (cq[pos].flow_table_metadata) & mask; *RTE_MBUF_DYNFIELD(pkts[pos + 1], offs, uint32_t *) = - (rte_be_to_cpu_32 - (cq[pos + p1].flow_table_metadata) >> shift) & - mask; + rte_be_to_cpu_32 + (cq[pos + p1].flow_table_metadata) & mask; *RTE_MBUF_DYNFIELD(pkts[pos + 2], offs, uint32_t *) = - (rte_be_to_cpu_32 - (cq[pos + p2].flow_table_metadata) >> shift) & - mask; + rte_be_to_cpu_32 + (cq[pos + p2].flow_table_metadata) & mask; *RTE_MBUF_DYNFIELD(pkts[pos + 3], offs, uint32_t *) = - (rte_be_to_cpu_32 - (cq[pos + p3].flow_table_metadata) >> shift) & - mask; + rte_be_to_cpu_32 + (cq[pos + p3].flow_table_metadata) & mask; if (*RTE_MBUF_DYNFIELD(pkts[pos], offs, uint32_t *)) pkts[pos]->ol_flags |= rxq->flow_meta_mask; if (*RTE_MBUF_DYNFIELD(pkts[pos + 1], offs, uint32_t *))