Lines Matching refs:l2_node
952 struct bnxt_tc_l2_node *l2_node = flow_node->l2_node; in bnxt_tc_put_l2_node() local
958 if (--l2_node->refcount == 0) { in bnxt_tc_put_l2_node()
959 rc = rhashtable_remove_fast(&tc_info->l2_table, &l2_node->node, in bnxt_tc_put_l2_node()
965 kfree_rcu(l2_node, rcu); in bnxt_tc_put_l2_node()
975 struct bnxt_tc_l2_node *l2_node; in bnxt_tc_get_l2_node() local
978 l2_node = rhashtable_lookup_fast(l2_table, l2_key, ht_params); in bnxt_tc_get_l2_node()
979 if (!l2_node) { in bnxt_tc_get_l2_node()
980 l2_node = kzalloc(sizeof(*l2_node), GFP_KERNEL); in bnxt_tc_get_l2_node()
981 if (!l2_node) { in bnxt_tc_get_l2_node()
986 l2_node->key = *l2_key; in bnxt_tc_get_l2_node()
987 rc = rhashtable_insert_fast(l2_table, &l2_node->node, in bnxt_tc_get_l2_node()
990 kfree_rcu(l2_node, rcu); in bnxt_tc_get_l2_node()
996 INIT_LIST_HEAD(&l2_node->common_l2_flows); in bnxt_tc_get_l2_node()
998 return l2_node; in bnxt_tc_get_l2_node()
1011 struct bnxt_tc_l2_node *l2_node; in bnxt_tc_get_ref_flow_handle() local
1013 l2_node = bnxt_tc_get_l2_node(bp, &tc_info->l2_table, in bnxt_tc_get_ref_flow_handle()
1016 if (!l2_node) in bnxt_tc_get_ref_flow_handle()
1022 if (l2_node->refcount > 0) { in bnxt_tc_get_ref_flow_handle()
1023 ref_flow_node = list_first_entry(&l2_node->common_l2_flows, in bnxt_tc_get_ref_flow_handle()
1035 flow_node->l2_node = l2_node; in bnxt_tc_get_ref_flow_handle()
1036 list_add(&flow_node->l2_list_node, &l2_node->common_l2_flows); in bnxt_tc_get_ref_flow_handle()
1037 l2_node->refcount++; in bnxt_tc_get_ref_flow_handle()