Lines Matching refs:rule
2333 struct ixgbe_fdir_filter *rule = NULL; in ixgbe_get_ethtool_fdir_entry() local
2338 hlist_for_each_entry_safe(rule, node2, in ixgbe_get_ethtool_fdir_entry()
2340 if (fsp->location <= rule->sw_idx) in ixgbe_get_ethtool_fdir_entry()
2344 if (!rule || fsp->location != rule->sw_idx) in ixgbe_get_ethtool_fdir_entry()
2350 switch (rule->filter.formatted.flow_type) { in ixgbe_get_ethtool_fdir_entry()
2370 fsp->h_u.tcp_ip4_spec.psrc = rule->filter.formatted.src_port; in ixgbe_get_ethtool_fdir_entry()
2372 fsp->h_u.tcp_ip4_spec.pdst = rule->filter.formatted.dst_port; in ixgbe_get_ethtool_fdir_entry()
2374 fsp->h_u.tcp_ip4_spec.ip4src = rule->filter.formatted.src_ip[0]; in ixgbe_get_ethtool_fdir_entry()
2376 fsp->h_u.tcp_ip4_spec.ip4dst = rule->filter.formatted.dst_ip[0]; in ixgbe_get_ethtool_fdir_entry()
2378 fsp->h_ext.vlan_tci = rule->filter.formatted.vlan_id; in ixgbe_get_ethtool_fdir_entry()
2380 fsp->h_ext.vlan_etype = rule->filter.formatted.flex_bytes; in ixgbe_get_ethtool_fdir_entry()
2382 fsp->h_ext.data[1] = htonl(rule->filter.formatted.vm_pool); in ixgbe_get_ethtool_fdir_entry()
2387 if (rule->action == IXGBE_FDIR_DROP_QUEUE) in ixgbe_get_ethtool_fdir_entry()
2390 fsp->ring_cookie = rule->action; in ixgbe_get_ethtool_fdir_entry()
2400 struct ixgbe_fdir_filter *rule; in ixgbe_get_ethtool_fdir_all() local
2406 hlist_for_each_entry_safe(rule, node2, in ixgbe_get_ethtool_fdir_all()
2410 rule_locs[cnt] = rule->sw_idx; in ixgbe_get_ethtool_fdir_all()
2498 struct ixgbe_fdir_filter *rule, *parent; in ixgbe_update_ethtool_fdir_entry() local
2502 rule = NULL; in ixgbe_update_ethtool_fdir_entry()
2504 hlist_for_each_entry_safe(rule, node2, in ixgbe_update_ethtool_fdir_entry()
2507 if (rule->sw_idx >= sw_idx) in ixgbe_update_ethtool_fdir_entry()
2509 parent = rule; in ixgbe_update_ethtool_fdir_entry()
2513 if (rule && (rule->sw_idx == sw_idx)) { in ixgbe_update_ethtool_fdir_entry()
2514 if (!input || (rule->filter.formatted.bkt_hash != in ixgbe_update_ethtool_fdir_entry()
2517 &rule->filter, in ixgbe_update_ethtool_fdir_entry()
2521 hlist_del(&rule->fdir_node); in ixgbe_update_ethtool_fdir_entry()
2522 kfree(rule); in ixgbe_update_ethtool_fdir_entry()