Skip to content

Commit

Permalink
net/iavf: fix HW ring scan method selection
Browse files Browse the repository at this point in the history
[ upstream commit 070ef4e ]

When setup Rx queue, the rxdid would be changed if it's
"IAVF_RXDID_LEGACY_0/1", that caused the scan HW ring used the wrong
function 'iavf_rx_scan_hw_ring_flex_rxd()'.

Ignore the rxdid changed when equals "IAVF_RXDID_LEGACY_0/1".

Fixes: 0ed16e0 ("net/iavf: fix function pointer in multi-process")

Signed-off-by: Steve Yang <stevex.yang@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
  • Loading branch information
Steve Yang authored and steevenlee committed Jun 15, 2022
1 parent faca682 commit 236835c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions drivers/net/iavf/iavf_rxtx.c
Expand Up @@ -441,6 +441,8 @@ iavf_rxd_to_pkt_fields_by_comms_aux_v2(struct iavf_rx_queue *rxq,

static const
iavf_rxd_to_pkt_fields_t rxd_to_pkt_fields_ops[IAVF_RXDID_LAST + 1] = {
[IAVF_RXDID_LEGACY_0] = iavf_rxd_to_pkt_fields_by_comms_ovs,
[IAVF_RXDID_LEGACY_1] = iavf_rxd_to_pkt_fields_by_comms_ovs,
[IAVF_RXDID_COMMS_AUX_VLAN] = iavf_rxd_to_pkt_fields_by_comms_aux_v1,
[IAVF_RXDID_COMMS_AUX_IPV4] = iavf_rxd_to_pkt_fields_by_comms_aux_v1,
[IAVF_RXDID_COMMS_AUX_IPV6] = iavf_rxd_to_pkt_fields_by_comms_aux_v1,
Expand Down Expand Up @@ -479,6 +481,8 @@ iavf_select_rxd_to_pkt_fields_handler(struct iavf_rx_queue *rxq, uint32_t rxdid)
rte_pmd_ifd_dynflag_proto_xtr_ip_offset_mask;
break;
case IAVF_RXDID_COMMS_OVS_1:
case IAVF_RXDID_LEGACY_0:
case IAVF_RXDID_LEGACY_1:
break;
default:
/* update this according to the RXDID for FLEX_DESC_NONE */
Expand Down

0 comments on commit 236835c

Please sign in to comment.