]> git.droids-corp.org - dpdk.git/commitdiff
net/iavf: fix HW ring scan method selection
authorSteve Yang <stevex.yang@intel.com>
Mon, 14 Mar 2022 09:31:46 +0000 (09:31 +0000)
committerQi Zhang <qi.z.zhang@intel.com>
Mon, 18 Apr 2022 05:47:18 +0000 (07:47 +0200)
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: 0ed16e01313e ("net/iavf: fix function pointer in multi-process")
Cc: stable@dpdk.org
Signed-off-by: Steve Yang <stevex.yang@intel.com>
Acked-by: Beilei Xing <beilei.xing@intel.com>
drivers/net/iavf/iavf_rxtx.c

index d2cc3ed4bdd794c6fa6fd7b5a2058e58cd9162c3..764218ace0ef0931fc6127652c2d1782c1cd2b5d 100644 (file)
@@ -477,6 +477,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,
@@ -521,6 +523,8 @@ iavf_select_rxd_to_pkt_fields_handler(struct iavf_rx_queue *rxq, uint32_t rxdid)
                        rte_pmd_ifd_dynflag_proto_xtr_ipsec_crypto_said_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 */