> Subject: [PATCH 08/13] net/ice: use common descriptor creation functions
>
> Update ice driver to use the descriptor creation functions from common
> rather than having it maintain its own copies of them.
>
> Signed-off-by: Bruce Richardson <[email protected]>
> ---
> drivers/net/intel/ice/ice_rxtx_vec_avx2.c | 73 ++-------------------
> drivers/net/intel/ice/ice_rxtx_vec_avx512.c | 64 ++----------------
> drivers/net/intel/ice/ice_rxtx_vec_common.h | 59 -----------------
> 3 files changed, 12 insertions(+), 184 deletions(-)
>
> diff --git a/drivers/net/intel/ice/ice_rxtx_vec_avx2.c
> b/drivers/net/intel/ice/ice_rxtx_vec_avx2.c
> index b72f69a47b..68401560ce 100644
> --- a/drivers/net/intel/ice/ice_rxtx_vec_avx2.c
> +++ b/drivers/net/intel/ice/ice_rxtx_vec_avx2.c
> @@ -5,6 +5,7 @@
> #include "ice_rxtx_vec_common.h"
>
> #include "../common/rx_vec_x86.h"
> +#include "../common/tx_vec_x86.h"
>
> #include <rte_vect.h>
>
> @@ -773,70 +774,6 @@ ice_recv_scattered_pkts_vec_avx2_offload(void
> *rx_queue,
> true);
> }
>
> -static __rte_always_inline void
> -ice_vtx1(volatile struct ci_tx_desc *txdp,
> - struct rte_mbuf *pkt, uint64_t flags, bool offload)
> -{
> - uint64_t high_qw = (CI_TX_DESC_DTYPE_DATA |
> - ((uint64_t)flags << CI_TXD_QW1_CMD_S) |
> - ((uint64_t)pkt->data_len << CI_TXD_QW1_TX_BUF_SZ_S));
> - if (offload)
> - ice_txd_enable_offload(pkt, &high_qw);
> -
> - __m128i descriptor = _mm_set_epi64x(high_qw,
> rte_pktmbuf_iova(pkt));
AI caught this for me on review, and I was able to reproduce it:
When you build with -Denable_iova_as_pa=false the ice driver build will fail.
"require_iova_in_mbuf = false" is set in the ice meson.build file. So either
that needs to be flipped to true, or ice needs to keep using rte_pktmbuf_iova.
> - _mm_store_si128(RTE_CAST_PTR(__m128i *, txdp), descriptor);
> -}
> -
> -static __rte_always_inline void
> -ice_vtx(volatile struct ci_tx_desc *txdp,
> - struct rte_mbuf **pkt, uint16_t nb_pkts, uint64_t flags, bool offload)
> -{