Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 48 additions & 0 deletions drivers/net/ethernet/intel/iavf/iavf_adv_rss.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,38 @@ iavf_fill_adv_rss_sctp_hdr(struct virtchnl_proto_hdr *hdr, u64 hash_flds)
VIRTCHNL_ADD_PROTO_HDR_FIELD_BIT(hdr, SCTP, DST_PORT);
}

/**
* iavf_fill_adv_rss_gtpeh_hdr - fill the GTP-EH RSS protocol header
* @hdr: the virtchnl message protocol header data structure
* @hash_flds: the RSS configuration protocol hash fields
*/
static int
iavf_fill_adv_rss_gtp_hdr(struct virtchnl_proto_hdrs *proto_hdrs, u32 packet_hdrs, u64 hash_flds)
{
struct virtchnl_proto_hdr *hdr;

hdr = &proto_hdrs->proto_hdr[proto_hdrs->count++];
switch (packet_hdrs & IAVF_ADV_RSS_FLOW_SEG_HDR_GTP) {
case IAVF_ADV_RSS_FLOW_SEG_HDR_GTPC:
VIRTCHNL_SET_PROTO_HDR_TYPE(hdr, GTPC);
break;
case IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_EH:
VIRTCHNL_SET_PROTO_HDR_TYPE(hdr, GTPU_EH);
break;
case IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_UP:
VIRTCHNL_SET_PROTO_HDR_TYPE(hdr, GTPU_EH_PDU_UP);
break;
case IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_DWN:
VIRTCHNL_SET_PROTO_HDR_TYPE(hdr, GTPU_EH_PDU_DWN);
break;
default:
return -EINVAL;

}

return 0;
}

/**
* iavf_fill_adv_rss_cfg_msg - fill the RSS configuration into virtchnl message
* @rss_cfg: the virtchnl message to be filled with RSS configuration setting
Expand Down Expand Up @@ -125,6 +157,10 @@ iavf_fill_adv_rss_cfg_msg(struct virtchnl_rss_cfg *rss_cfg,
return -EINVAL;
}

if(packet_hdrs & IAVF_ADV_RSS_FLOW_SEG_HDR_GTP) {
return iavf_fill_adv_rss_gtp_hdr(proto_hdrs, packet_hdrs, hash_flds);
}

hdr = &proto_hdrs->proto_hdr[proto_hdrs->count++];
switch (packet_hdrs & IAVF_ADV_RSS_FLOW_SEG_HDR_L4) {
case IAVF_ADV_RSS_FLOW_SEG_HDR_TCP:
Expand Down Expand Up @@ -186,6 +222,8 @@ iavf_print_adv_rss_cfg(struct iavf_adapter *adapter, struct iavf_adv_rss *rss,
proto = "UDP";
else if (packet_hdrs & IAVF_ADV_RSS_FLOW_SEG_HDR_SCTP)
proto = "SCTP";
else if (packet_hdrs & IAVF_ADV_RSS_FLOW_SEG_HDR_GTP)
proto = "GTP";
else
return;

Expand All @@ -211,6 +249,16 @@ iavf_print_adv_rss_cfg(struct iavf_adapter *adapter, struct iavf_adv_rss *rss,
IAVF_ADV_RSS_HASH_FLD_UDP_DST_PORT |
IAVF_ADV_RSS_HASH_FLD_SCTP_DST_PORT))
strcat(hash_opt, "dst port,");
if (hash_flds & IAVF_ADV_RSS_HASH_FLD_GTPC_TEID)
strcat(hash_opt, "gtp-c,");
if (hash_flds & IAVF_ADV_RSS_HASH_FLD_GTPU_IP_TEID)
strcat(hash_opt, "gtp-u ip,");
if (hash_flds & IAVF_ADV_RSS_HASH_FLD_GTPU_EH_TEID)
strcat(hash_opt, "gtp-u ext,");
if (hash_flds & IAVF_ADV_RSS_HASH_FLD_GTPU_UP_TEID)
strcat(hash_opt, "gtp-u ul,");
if (hash_flds & IAVF_ADV_RSS_HASH_FLD_GTPU_DWN_TEID)
strcat(hash_opt, "gtp-u dl,");

if (!action)
action = "";
Expand Down
32 changes: 32 additions & 0 deletions drivers/net/ethernet/intel/iavf/iavf_adv_rss.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,13 @@ enum iavf_adv_rss_flow_seg_hdr {
IAVF_ADV_RSS_FLOW_SEG_HDR_TCP = 0x00000004,
IAVF_ADV_RSS_FLOW_SEG_HDR_UDP = 0x00000008,
IAVF_ADV_RSS_FLOW_SEG_HDR_SCTP = 0x00000010,
/* RESERVED */
IAVF_ADV_RSS_FLOW_SEG_HDR_GTPC = 0x00000400,
IAVF_ADV_RSS_FLOW_SEG_HDR_GTPC_TEID = 0x00000800,
IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_IP = 0x00001000,
IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_EH = 0x00002000,
IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_DWN = 0x00004000,
IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_UP = 0x00008000,
};

#define IAVF_ADV_RSS_FLOW_SEG_HDR_L3 \
Expand All @@ -33,6 +40,14 @@ enum iavf_adv_rss_flow_seg_hdr {
IAVF_ADV_RSS_FLOW_SEG_HDR_UDP | \
IAVF_ADV_RSS_FLOW_SEG_HDR_SCTP)

#define IAVF_ADV_RSS_FLOW_SEG_HDR_GTP \
(IAVF_ADV_RSS_FLOW_SEG_HDR_GTPC | \
IAVF_ADV_RSS_FLOW_SEG_HDR_GTPC_TEID| \
IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_IP| \
IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_EH| \
IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_DWN| \
IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_UP)

enum iavf_adv_rss_flow_field {
/* L3 */
IAVF_ADV_RSS_FLOW_FIELD_IDX_IPV4_SA,
Expand All @@ -46,6 +61,17 @@ enum iavf_adv_rss_flow_field {
IAVF_ADV_RSS_FLOW_FIELD_IDX_UDP_DST_PORT,
IAVF_ADV_RSS_FLOW_FIELD_IDX_SCTP_SRC_PORT,
IAVF_ADV_RSS_FLOW_FIELD_IDX_SCTP_DST_PORT,
/* GTPC_TEID */
IAVF_ADV_RSS_FLOW_FIELD_IDX_GTPC_TEID,
/* GTPU_IP */
IAVF_ADV_RSS_FLOW_FIELD_IDX_GTPU_IP_TEID,
/* GTPU_EH */
IAVF_ADV_RSS_FLOW_FIELD_IDX_GTPU_EH_TEID,
IAVF_ADV_RSS_FLOW_FIELD_IDX_GTPU_EH_QFI,
/* GTPU_UP */
IAVF_ADV_RSS_FLOW_FIELD_IDX_GTPU_UP_TEID,
/* GTPU_DWN */
IAVF_ADV_RSS_FLOW_FIELD_IDX_GTPU_DWN_TEID,

/* The total number of enums must not exceed 64 */
IAVF_ADV_RSS_FLOW_FIELD_IDX_MAX
Expand All @@ -72,6 +98,12 @@ enum iavf_adv_rss_flow_field {
BIT_ULL(IAVF_ADV_RSS_FLOW_FIELD_IDX_SCTP_SRC_PORT)
#define IAVF_ADV_RSS_HASH_FLD_SCTP_DST_PORT \
BIT_ULL(IAVF_ADV_RSS_FLOW_FIELD_IDX_SCTP_DST_PORT)
#define IAVF_ADV_RSS_HASH_FLD_GTPC_TEID BIT_ULL(IAVF_ADV_RSS_FLOW_FIELD_IDX_GTPC_TEID)
#define IAVF_ADV_RSS_HASH_FLD_GTPU_IP_TEID BIT_ULL(IAVF_ADV_RSS_FLOW_FIELD_IDX_GTPU_IP_TEID)
#define IAVF_ADV_RSS_HASH_FLD_GTPU_EH_TEID BIT_ULL(IAVF_ADV_RSS_FLOW_FIELD_IDX_GTPU_EH_TEID)
#define IAVF_ADV_RSS_HASH_FLD_GTPU_UP_TEID BIT_ULL(IAVF_ADV_RSS_FLOW_FIELD_IDX_GTPU_UP_TEID)
#define IAVF_ADV_RSS_HASH_FLD_GTPU_DWN_TEID \
BIT_ULL(IAVF_ADV_RSS_FLOW_FIELD_IDX_GTPU_DWN_TEID)

/* bookkeeping of advanced RSS configuration */
struct iavf_adv_rss {
Expand Down
74 changes: 74 additions & 0 deletions drivers/net/ethernet/intel/iavf/iavf_ethtool.c
Original file line number Diff line number Diff line change
Expand Up @@ -1349,6 +1349,42 @@ static u32 iavf_adv_rss_parse_hdrs(struct ethtool_rxnfc *cmd)
hdrs |= IAVF_ADV_RSS_FLOW_SEG_HDR_SCTP |
IAVF_ADV_RSS_FLOW_SEG_HDR_IPV6;
break;
case GTPU_V4_FLOW:
hdrs |= IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_IP | IAVF_ADV_RSS_FLOW_SEG_HDR_IPV4;
break;
case GTPC_V4_FLOW:
hdrs |= IAVF_ADV_RSS_FLOW_SEG_HDR_GTPC | IAVF_ADV_RSS_FLOW_SEG_HDR_IPV4;
break;
case GTPC_TEID_V4_FLOW:
hdrs |= IAVF_ADV_RSS_FLOW_SEG_HDR_GTPC_TEID | IAVF_ADV_RSS_FLOW_SEG_HDR_IPV4;
break;
case GTPU_EH_V4_FLOW:
hdrs |= IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_EH | IAVF_ADV_RSS_FLOW_SEG_HDR_IPV4;
break;
case GTPU_UL_V4_FLOW:
hdrs |= IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_UP | IAVF_ADV_RSS_FLOW_SEG_HDR_IPV4;
break;
case GTPU_DL_V4_FLOW:
hdrs |= IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_DWN | IAVF_ADV_RSS_FLOW_SEG_HDR_IPV4;
break;
case GTPU_V6_FLOW:
hdrs |= IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_IP | IAVF_ADV_RSS_FLOW_SEG_HDR_IPV6;
break;
case GTPC_V6_FLOW:
hdrs |= IAVF_ADV_RSS_FLOW_SEG_HDR_GTPC | IAVF_ADV_RSS_FLOW_SEG_HDR_IPV6;
break;
case GTPC_TEID_V6_FLOW:
hdrs |= IAVF_ADV_RSS_FLOW_SEG_HDR_GTPC_TEID | IAVF_ADV_RSS_FLOW_SEG_HDR_IPV6;
break;
case GTPU_EH_V6_FLOW:
hdrs |= IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_EH | IAVF_ADV_RSS_FLOW_SEG_HDR_IPV6;
break;
case GTPU_UL_V6_FLOW:
hdrs |= IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_UP | IAVF_ADV_RSS_FLOW_SEG_HDR_IPV6;
break;
case GTPU_DL_V6_FLOW:
hdrs |= IAVF_ADV_RSS_FLOW_SEG_HDR_GTPU_DWN | IAVF_ADV_RSS_FLOW_SEG_HDR_IPV6;
break;
default:
break;
}
Expand All @@ -1373,6 +1409,12 @@ static u64 iavf_adv_rss_parse_hash_flds(struct ethtool_rxnfc *cmd, bool symm)
case TCP_V4_FLOW:
case UDP_V4_FLOW:
case SCTP_V4_FLOW:
case GTPU_V4_FLOW:
case GTPC_V4_FLOW:
case GTPC_TEID_V4_FLOW:
case GTPU_EH_V4_FLOW:
case GTPU_UL_V4_FLOW:
case GTPU_DL_V4_FLOW:
if (cmd->data & RXH_IP_SRC)
hfld |= IAVF_ADV_RSS_HASH_FLD_IPV4_SA;
if (cmd->data & RXH_IP_DST)
Expand All @@ -1381,6 +1423,12 @@ static u64 iavf_adv_rss_parse_hash_flds(struct ethtool_rxnfc *cmd, bool symm)
case TCP_V6_FLOW:
case UDP_V6_FLOW:
case SCTP_V6_FLOW:
case GTPU_V6_FLOW:
case GTPC_V6_FLOW:
case GTPC_TEID_V6_FLOW:
case GTPU_EH_V6_FLOW:
case GTPU_UL_V6_FLOW:
case GTPU_DL_V6_FLOW:
if (cmd->data & RXH_IP_SRC)
hfld |= IAVF_ADV_RSS_HASH_FLD_IPV6_SA;
if (cmd->data & RXH_IP_DST)
Expand Down Expand Up @@ -1418,6 +1466,32 @@ static u64 iavf_adv_rss_parse_hash_flds(struct ethtool_rxnfc *cmd, bool symm)
break;
}
}
if (cmd->data & RXH_GTP_TEID) {
switch (cmd->flow_type) {
case GTPC_TEID_V4_FLOW:
case GTPC_TEID_V6_FLOW:
hfld |= IAVF_ADV_RSS_HASH_FLD_GTPC_TEID;
break;
case GTPU_V4_FLOW:
case GTPU_V6_FLOW:
hfld |= IAVF_ADV_RSS_HASH_FLD_GTPU_IP_TEID;
break;
case GTPU_EH_V4_FLOW:
case GTPU_EH_V6_FLOW:
hfld |= IAVF_ADV_RSS_HASH_FLD_GTPU_EH_TEID;
break;
case GTPU_UL_V4_FLOW:
case GTPU_UL_V6_FLOW:
hfld |= IAVF_ADV_RSS_HASH_FLD_GTPU_UP_TEID;
break;
case GTPU_DL_V4_FLOW:
case GTPU_DL_V6_FLOW:
hfld |= IAVF_ADV_RSS_HASH_FLD_GTPU_DWN_TEID;
break;
default:
break;
}
}

return hfld;
}
Expand Down
2 changes: 1 addition & 1 deletion drivers/net/ethernet/intel/iavf/iavf_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ static int iavf_check_reset_complete(struct iavf_hw *hw);

char iavf_driver_name[] = "iavf";
static const char iavf_driver_string[] =
"Intel(R) Ethernet Adaptive Virtual Function Network Driver";
"Intel(R) Ethernet Adaptive Virtual Function Network Driver +GTP-Uv15";

static const char iavf_copyright[] =
"Copyright (c) 2013 - 2018 Intel Corporation.";
Expand Down
12 changes: 12 additions & 0 deletions drivers/net/ethernet/intel/ice/ice_adminq_cmd.h
Original file line number Diff line number Diff line change
Expand Up @@ -2033,6 +2033,16 @@ struct ice_aqc_get_set_rss_lut {
__le32 addr_low;
};

/* Clear FD Table Command (direct, 0x0B06) */
struct ice_aqc_clear_fd_table {
u8 clear_type;
#define CL_FD_VM_VF_TYPE_VSI_IDX 1
#define CL_FD_VM_VF_TYPE_PF_IDX 2
u8 rsvd;
__le16 vsi_index;
u8 reserved[12];
};

/* Sideband Control Interface Commands */
/* Neighbor Device Request (indirect 0x0C00); also used for the response. */
struct ice_aqc_neigh_dev_req {
Expand Down Expand Up @@ -2596,6 +2606,7 @@ struct ice_aq_desc {
struct ice_aqc_lldp_filter_ctrl lldp_filter_ctrl;
struct ice_aqc_get_set_rss_lut get_set_rss_lut;
struct ice_aqc_get_set_rss_key get_set_rss_key;
struct ice_aqc_clear_fd_table clear_fd_table;
struct ice_aqc_neigh_dev_req neigh_dev;
struct ice_aqc_add_txqs add_txqs;
struct ice_aqc_dis_txqs dis_txqs;
Expand Down Expand Up @@ -2791,6 +2802,7 @@ enum ice_adminq_opc {
ice_aqc_opc_set_rss_lut = 0x0B03,
ice_aqc_opc_get_rss_key = 0x0B04,
ice_aqc_opc_get_rss_lut = 0x0B05,
ice_aqc_opc_clear_fd_table = 0x0B06,

/* Sideband Control Interface commands */
ice_aqc_opc_neighbour_device_request = 0x0C00,
Expand Down
15 changes: 14 additions & 1 deletion drivers/net/ethernet/intel/ice/ice_ethtool.c
Original file line number Diff line number Diff line change
Expand Up @@ -2883,6 +2883,19 @@ static u32 ice_parse_hdrs(struct ethtool_rxnfc *nfc)
return hdrs;
}

#define ICE_FLOW_HASH_FLD_IPV4_SA BIT_ULL(ICE_FLOW_FIELD_IDX_IPV4_SA)
#define ICE_FLOW_HASH_FLD_IPV6_SA BIT_ULL(ICE_FLOW_FIELD_IDX_IPV6_SA)
#define ICE_FLOW_HASH_FLD_IPV4_DA BIT_ULL(ICE_FLOW_FIELD_IDX_IPV4_DA)
#define ICE_FLOW_HASH_FLD_IPV6_DA BIT_ULL(ICE_FLOW_FIELD_IDX_IPV6_DA)
#define ICE_FLOW_HASH_FLD_TCP_SRC_PORT BIT_ULL(ICE_FLOW_FIELD_IDX_TCP_SRC_PORT)
#define ICE_FLOW_HASH_FLD_TCP_DST_PORT BIT_ULL(ICE_FLOW_FIELD_IDX_TCP_DST_PORT)
#define ICE_FLOW_HASH_FLD_UDP_SRC_PORT BIT_ULL(ICE_FLOW_FIELD_IDX_UDP_SRC_PORT)
#define ICE_FLOW_HASH_FLD_UDP_DST_PORT BIT_ULL(ICE_FLOW_FIELD_IDX_UDP_DST_PORT)
#define ICE_FLOW_HASH_FLD_SCTP_SRC_PORT \
BIT_ULL(ICE_FLOW_FIELD_IDX_SCTP_SRC_PORT)
#define ICE_FLOW_HASH_FLD_SCTP_DST_PORT \
BIT_ULL(ICE_FLOW_FIELD_IDX_SCTP_DST_PORT)

/**
* ice_parse_hash_flds - parses hash fields from RSS hash input
* @nfc: ethtool rxnfc command
Expand Down Expand Up @@ -3033,7 +3046,7 @@ ice_set_rss_hash_opt(struct ice_vsi *vsi, struct ethtool_rxnfc *nfc)
cfg.hdr_type = ICE_RSS_ANY_HEADERS;
cfg.symm = symm;

status = ice_add_rss_cfg(&pf->hw, vsi, &cfg);
status = ice_add_rss_cfg(&pf->hw, vsi->idx, &cfg);
if (status) {
dev_dbg(dev, "ice_add_rss_cfg failed, vsi num = %d, error = %d\n",
vsi->vsi_num, status);
Expand Down
26 changes: 15 additions & 11 deletions drivers/net/ethernet/intel/ice/ice_ethtool_fdir.c
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,7 @@ void ice_fdir_rem_adq_chnl(struct ice_hw *hw, u16 vsi_idx)
/* find flow profile corresponding to prof_id and clear
* vsi_idx from bitmap.
*/
status = ice_flow_rem_vsi_prof(hw, vsi_idx, prof_id);
status = ice_flow_rem_vsi_prof(hw, ICE_BLK_FD, vsi_idx, prof_id);
if (status) {
dev_err(ice_hw_to_dev(hw), "ice_flow_rem_vsi_prof() failed status=%d\n",
status);
Expand Down Expand Up @@ -449,7 +449,7 @@ void ice_fdir_replay_flows(struct ice_hw *hw)
prof = hw->fdir_prof[flow];
ice_flow_add_prof(hw, ICE_BLK_FD, ICE_FLOW_RX,
prof->fdir_seg[tun], TNL_SEG_CNT(tun),
false, &hw_prof);
NULL, 0, false, &hw_prof);
for (j = 0; j < prof->cnt; j++) {
enum ice_flow_priority prio;
u64 entry_h = 0;
Expand All @@ -461,7 +461,8 @@ void ice_fdir_replay_flows(struct ice_hw *hw)
prof->vsi_h[0],
prof->vsi_h[j],
prio, prof->fdir_seg,
&entry_h);
NULL, 0, &entry_h);

if (err) {
dev_err(ice_hw_to_dev(hw), "Could not replay Flow Director, flow type %d\n",
flow);
Expand Down Expand Up @@ -689,17 +690,20 @@ ice_fdir_set_hw_fltr_rule(struct ice_pf *pf, struct ice_flow_seg_info *seg,
* actions (NULL) and zero actions 0.
*/
err = ice_flow_add_prof(hw, ICE_BLK_FD, ICE_FLOW_RX, seg,
TNL_SEG_CNT(tun), false, &prof);
TNL_SEG_CNT(tun), NULL, 0, false, &prof);

if (err)
return err;

err = ice_flow_add_entry(hw, ICE_BLK_FD, prof->id, main_vsi->idx,
main_vsi->idx, ICE_FLOW_PRIO_NORMAL,
seg, &entry1_h);
main_vsi->idx, ICE_FLOW_PRIO_NORMAL, seg, NULL,
0, &entry1_h);
if (err)
goto err_prof;

err = ice_flow_add_entry(hw, ICE_BLK_FD, prof->id, main_vsi->idx,
ctrl_vsi->idx, ICE_FLOW_PRIO_NORMAL,
seg, &entry2_h);
ctrl_vsi->idx, ICE_FLOW_PRIO_NORMAL, seg, NULL,
0, &entry2_h);
if (err)
goto err_entry;

Expand All @@ -724,7 +728,7 @@ ice_fdir_set_hw_fltr_rule(struct ice_pf *pf, struct ice_flow_seg_info *seg,
err = ice_flow_add_entry(hw, ICE_BLK_FD, prof->id,
main_vsi->idx, vsi_h,
ICE_FLOW_PRIO_NORMAL, seg,
&entry1_h);
NULL, 0, &entry1_h);
if (err) {
dev_err(dev, "Could not add Channel VSI %d to flow group\n",
idx);
Expand Down Expand Up @@ -1570,7 +1574,7 @@ ice_fdir_write_all_fltr(struct ice_pf *pf, struct ice_fdir_fltr *input,
bool is_tun = tun == ICE_FD_HW_SEG_TUN;
int err;

if (is_tun && !ice_get_open_tunnel_port(&pf->hw, &port_num, TNL_ALL))
if (is_tun && !ice_get_open_tunnel_port(&pf->hw, TNL_ALL, &port_num))

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Przemek mentioned this on list,. I agree with him that we shouldn't reverse the order of arguments on this function for seemingly no reason. If you just want to align upstream with out-of-tree, we should invert the order out-of-tree.

continue;
err = ice_fdir_write_fltr(pf, input, add, is_tun);
if (err)
Expand Down Expand Up @@ -2026,7 +2030,7 @@ int ice_add_fdir_ethtool(struct ice_vsi *vsi, struct ethtool_rxnfc *cmd)
}

/* return error if not an update and no available filters */
fltrs_needed = ice_get_open_tunnel_port(hw, &tunnel_port, TNL_ALL) ? 2 : 1;
fltrs_needed = ice_get_open_tunnel_port(hw, TNL_ALL, &tunnel_port) ? 2 : 1;
if (!ice_fdir_find_fltr_by_idx(hw, fsp->location) &&
ice_fdir_num_avail_fltr(hw, pf->vsi[vsi->idx]) < fltrs_needed) {
dev_err(dev, "Failed to add filter. The maximum number of flow director filters has been reached.\n");
Expand Down
Loading