Home
last modified time | relevance | path

Searched refs:flow_cfg (Results 1 – 11 of 11) sorted by relevance

/linux/drivers/net/ethernet/marvell/octeontx2/nic/
H A Dotx2_flows.c33 static void otx2_clear_ntuple_flow_info(struct otx2_nic *pfvf, struct otx2_flow_config *flow_cfg) in otx2_clear_ntuple_flow_info() argument
35 devm_kfree(pfvf->dev, flow_cfg->flow_ent); in otx2_clear_ntuple_flow_info()
36 flow_cfg->flow_ent = NULL; in otx2_clear_ntuple_flow_info()
37 flow_cfg->max_flows = 0; in otx2_clear_ntuple_flow_info()
42 struct otx2_flow_config *flow_cfg = pfvf->flow_cfg; in otx2_free_ntuple_mcam_entries() local
46 if (!flow_cfg->max_flows) in otx2_free_ntuple_mcam_entries()
50 for (ent = 0; ent < flow_cfg->max_flows; ent++) { in otx2_free_ntuple_mcam_entries()
55 req->entry = flow_cfg->flow_ent[ent]; in otx2_free_ntuple_mcam_entries()
63 otx2_clear_ntuple_flow_info(pfvf, flow_cfg); in otx2_free_ntuple_mcam_entries()
69 struct otx2_flow_config *flow_cfg = pfvf->flow_cfg; in otx2_alloc_mcam_entries() local
[all …]
H A Dotx2_tc.c528 refcount_inc(&nic->flow_cfg->mark_flows); in otx2_tc_parse_actions()
961 struct otx2_flow_config *flow_cfg = pfvf->flow_cfg; in otx2_destroy_tc_flow_list() local
967 list_for_each_entry_safe(iter, tmp, &flow_cfg->flow_list_tc, list) { in otx2_destroy_tc_flow_list()
970 flow_cfg->nr_flows--; in otx2_destroy_tc_flow_list()
974 static struct otx2_tc_flow *otx2_tc_get_entry_by_cookie(struct otx2_flow_config *flow_cfg, in otx2_tc_get_entry_by_cookie() argument
979 list_for_each_entry(tmp, &flow_cfg->flow_list_tc, list) { in otx2_tc_get_entry_by_cookie()
987 static struct otx2_tc_flow *otx2_tc_get_entry_by_index(struct otx2_flow_config *flow_cfg, in otx2_tc_get_entry_by_index() argument
993 list_for_each_entry(tmp, &flow_cfg->flow_list_tc, list) { in otx2_tc_get_entry_by_index()
1002 static void otx2_tc_del_from_flow_list(struct otx2_flow_config *flow_cfg, in otx2_tc_del_from_flow_list() argument
1008 list_for_each_safe(pos, n, &flow_cfg->flow_list_tc) { in otx2_tc_del_from_flow_list()
[all …]
H A Drep.c43 rep->flow_cfg = kzalloc_objs(struct otx2_flow_config, 1); in rvu_rep_mcam_flow_init()
45 if (!rep->flow_cfg) in rvu_rep_mcam_flow_init()
50 rep->flow_cfg->flow_ent = kcalloc(count, sizeof(u16), GFP_KERNEL); in rvu_rep_mcam_flow_init()
51 if (!rep->flow_cfg->flow_ent) in rvu_rep_mcam_flow_init()
74 rep->flow_cfg->flow_ent[ent + allocated] = rsp->entry_list[ent]; in rvu_rep_mcam_flow_init()
88 sort(&rep->flow_cfg->flow_ent[0], allocated, in rvu_rep_mcam_flow_init()
89 sizeof(rep->flow_cfg->flow_ent[0]), mcam_entry_cmp, NULL); in rvu_rep_mcam_flow_init()
93 rep->flow_cfg->max_flows = allocated; in rvu_rep_mcam_flow_init()
101 INIT_LIST_HEAD(&rep->flow_cfg->flow_list); in rvu_rep_mcam_flow_init()
102 INIT_LIST_HEAD(&rep->flow_cfg->flow_list_tc); in rvu_rep_mcam_flow_init()
[all …]
H A Drep.h39 struct otx2_flow_config *flow_cfg; member
H A Dotx2_pf.c1298 if (enable && !bitmap_empty(pf->flow_cfg->dmacflt_bmap, in otx2_cgx_config_loopback()
1299 pf->flow_cfg->dmacflt_max_flows)) in otx2_cgx_config_loopback()
1855 (netdev_uc_count(netdev) > pf->flow_cfg->ucast_flt_cnt)) { in otx2_do_set_rx_mode()
2579 struct otx2_flow_config *flow_cfg = pf->flow_cfg; in otx2_do_set_vf_vlan() local
2620 flow_cfg->def_ent[flow_cfg->vf_vlan_offset + idx]; in otx2_do_set_vf_vlan()
2633 flow_cfg->def_ent[flow_cfg->vf_vlan_offset + idx]; in otx2_do_set_vf_vlan()
2647 req->entry = flow_cfg->def_ent[flow_cfg->vf_vlan_offset + idx]; in otx2_do_set_vf_vlan()
2698 req->entry = flow_cfg->def_ent[flow_cfg->vf_vlan_offset + idx]; in otx2_do_set_vf_vlan()
H A Dotx2_common.h513 struct otx2_flow_config *flow_cfg; member
1001 if (!pfvf->flow_cfg) in otx2_tc_flower_rule_cnt()
1004 return pfvf->flow_cfg->nr_flows; in otx2_tc_flower_rule_cnt()
1133 int otx2_get_maxflows(struct otx2_flow_config *flow_cfg);
H A Dotx2_ethtool.c756 nfc->rule_cnt = pfvf->flow_cfg->nr_flows; in otx2_get_rxnfc()
780 pfvf->flow_cfg->ntuple = ntuple; in otx2_set_rxnfc()
H A Dotx2_common.c2040 if (!pfvf->flow_cfg->max_flows) { in otx2_handle_ntuple_tc_features()
/linux/drivers/net/ethernet/ti/icssg/
H A Dicssg_config.c512 struct icssg_flow_cfg __iomem *flow_cfg; in icssg_config() local
547 flow_cfg = config + PSI_L_REGULAR_FLOW_ID_BASE_OFFSET; in icssg_config()
548 writew(emac->rx_flow_id_base, &flow_cfg->rx_base_flow); in icssg_config()
549 writew(0, &flow_cfg->mgm_base_flow); in icssg_config()
H A Dicssg_prueth.c897 struct icssg_flow_cfg __iomem *flow_cfg; in emac_ndo_open() local
953 flow_cfg = emac->dram.va + ICSSG_CONFIG_OFFSET + PSI_L_REGULAR_FLOW_ID_BASE_OFFSET; in emac_ndo_open()
954 writew(emac->rx_flow_id_base, &flow_cfg->rx_base_flow); in emac_ndo_open()
/linux/drivers/net/ethernet/marvell/octeontx2/af/
H A Drvu_nix.c3962 static int get_flowkey_alg_idx(struct nix_hw *nix_hw, u32 flow_cfg) in get_flowkey_alg_idx() argument
3968 if (nix_hw->flowkey.flowkey[i] == flow_cfg) in get_flowkey_alg_idx()
3979 static int set_flowkey_fields(struct nix_rx_flowkey_alg *alg, u32 flow_cfg) in set_flowkey_fields() argument
4019 l3_l4_src_dst = flow_cfg; in set_flowkey_fields()
4021 flow_cfg &= NIX_FLOW_KEY_TYPE_L3_L4_MASK; in set_flowkey_fields()
4025 field = &tmp; max_bit_pos = fls(flow_cfg); in set_flowkey_fields()
4030 valid_key = flow_cfg & key_type; in set_flowkey_fields()
4306 static int reserve_flowkey_alg_idx(struct rvu *rvu, int blkaddr, u32 flow_cfg) in reserve_flowkey_alg_idx() argument
4321 rc = set_flowkey_fields((struct nix_rx_flowkey_alg *)field, flow_cfg); in reserve_flowkey_alg_idx()
4333 hw->flowkey.flowkey[rc] = flow_cfg; in reserve_flowkey_alg_idx()