Lines Matching refs:cmd
994 static int bnxt_grxclsrlall(struct bnxt *bp, struct ethtool_rxnfc *cmd, in bnxt_grxclsrlall() argument
999 cmd->data = bp->ntp_fltr_count; in bnxt_grxclsrlall()
1007 if (j == cmd->rule_cnt) in bnxt_grxclsrlall()
1012 if (j == cmd->rule_cnt) in bnxt_grxclsrlall()
1015 cmd->rule_cnt = j; in bnxt_grxclsrlall()
1019 static int bnxt_grxclsrule(struct bnxt *bp, struct ethtool_rxnfc *cmd) in bnxt_grxclsrule() argument
1022 (struct ethtool_rx_flow_spec *)&cmd->fs; in bnxt_grxclsrule()
1113 static int bnxt_grxfh(struct bnxt *bp, struct ethtool_rxnfc *cmd) in bnxt_grxfh() argument
1115 cmd->data = 0; in bnxt_grxfh()
1116 switch (cmd->flow_type) { in bnxt_grxfh()
1119 cmd->data |= RXH_IP_SRC | RXH_IP_DST | in bnxt_grxfh()
1121 cmd->data |= get_ethtool_ipv4_rss(bp); in bnxt_grxfh()
1125 cmd->data |= RXH_IP_SRC | RXH_IP_DST | in bnxt_grxfh()
1133 cmd->data |= get_ethtool_ipv4_rss(bp); in bnxt_grxfh()
1138 cmd->data |= RXH_IP_SRC | RXH_IP_DST | in bnxt_grxfh()
1140 cmd->data |= get_ethtool_ipv6_rss(bp); in bnxt_grxfh()
1144 cmd->data |= RXH_IP_SRC | RXH_IP_DST | in bnxt_grxfh()
1152 cmd->data |= get_ethtool_ipv6_rss(bp); in bnxt_grxfh()
1161 static int bnxt_srxfh(struct bnxt *bp, struct ethtool_rxnfc *cmd) in bnxt_srxfh() argument
1166 if (cmd->data == RXH_4TUPLE) in bnxt_srxfh()
1168 else if (cmd->data == RXH_2TUPLE) in bnxt_srxfh()
1170 else if (!cmd->data) in bnxt_srxfh()
1175 if (cmd->flow_type == TCP_V4_FLOW) { in bnxt_srxfh()
1179 } else if (cmd->flow_type == UDP_V4_FLOW) { in bnxt_srxfh()
1185 } else if (cmd->flow_type == TCP_V6_FLOW) { in bnxt_srxfh()
1189 } else if (cmd->flow_type == UDP_V6_FLOW) { in bnxt_srxfh()
1199 switch (cmd->flow_type) { in bnxt_srxfh()
1240 static int bnxt_get_rxnfc(struct net_device *dev, struct ethtool_rxnfc *cmd, in bnxt_get_rxnfc() argument
1246 switch (cmd->cmd) { in bnxt_get_rxnfc()
1249 cmd->data = bp->rx_nr_rings; in bnxt_get_rxnfc()
1253 cmd->rule_cnt = bp->ntp_fltr_count; in bnxt_get_rxnfc()
1254 cmd->data = BNXT_NTP_FLTR_MAX_FLTR; in bnxt_get_rxnfc()
1258 rc = bnxt_grxclsrlall(bp, cmd, (u32 *)rule_locs); in bnxt_get_rxnfc()
1262 rc = bnxt_grxclsrule(bp, cmd); in bnxt_get_rxnfc()
1267 rc = bnxt_grxfh(bp, cmd); in bnxt_get_rxnfc()
1278 static int bnxt_set_rxnfc(struct net_device *dev, struct ethtool_rxnfc *cmd) in bnxt_set_rxnfc() argument
1283 switch (cmd->cmd) { in bnxt_set_rxnfc()
1285 rc = bnxt_srxfh(bp, cmd); in bnxt_set_rxnfc()