Lines Matching refs:vr_entry

3116 	struct mlxsw_sp_nexthop_group_vr_entry *vr_entry;  in mlxsw_sp_nexthop_group_vr_entry_create()  local
3119 vr_entry = kzalloc(sizeof(*vr_entry), GFP_KERNEL); in mlxsw_sp_nexthop_group_vr_entry_create()
3120 if (!vr_entry) in mlxsw_sp_nexthop_group_vr_entry_create()
3123 vr_entry->key.vr_id = fib->vr->id; in mlxsw_sp_nexthop_group_vr_entry_create()
3124 vr_entry->key.proto = fib->proto; in mlxsw_sp_nexthop_group_vr_entry_create()
3125 refcount_set(&vr_entry->ref_count, 1); in mlxsw_sp_nexthop_group_vr_entry_create()
3127 err = rhashtable_insert_fast(&nh_grp->vr_ht, &vr_entry->ht_node, in mlxsw_sp_nexthop_group_vr_entry_create()
3132 list_add(&vr_entry->list, &nh_grp->vr_list); in mlxsw_sp_nexthop_group_vr_entry_create()
3137 kfree(vr_entry); in mlxsw_sp_nexthop_group_vr_entry_create()
3143 struct mlxsw_sp_nexthop_group_vr_entry *vr_entry) in mlxsw_sp_nexthop_group_vr_entry_destroy() argument
3145 list_del(&vr_entry->list); in mlxsw_sp_nexthop_group_vr_entry_destroy()
3146 rhashtable_remove_fast(&nh_grp->vr_ht, &vr_entry->ht_node, in mlxsw_sp_nexthop_group_vr_entry_destroy()
3148 kfree(vr_entry); in mlxsw_sp_nexthop_group_vr_entry_destroy()
3155 struct mlxsw_sp_nexthop_group_vr_entry *vr_entry; in mlxsw_sp_nexthop_group_vr_link() local
3157 vr_entry = mlxsw_sp_nexthop_group_vr_entry_lookup(nh_grp, fib); in mlxsw_sp_nexthop_group_vr_link()
3158 if (vr_entry) { in mlxsw_sp_nexthop_group_vr_link()
3159 refcount_inc(&vr_entry->ref_count); in mlxsw_sp_nexthop_group_vr_link()
3170 struct mlxsw_sp_nexthop_group_vr_entry *vr_entry; in mlxsw_sp_nexthop_group_vr_unlink() local
3172 vr_entry = mlxsw_sp_nexthop_group_vr_entry_lookup(nh_grp, fib); in mlxsw_sp_nexthop_group_vr_unlink()
3173 if (WARN_ON_ONCE(!vr_entry)) in mlxsw_sp_nexthop_group_vr_unlink()
3176 if (!refcount_dec_and_test(&vr_entry->ref_count)) in mlxsw_sp_nexthop_group_vr_unlink()
3179 mlxsw_sp_nexthop_group_vr_entry_destroy(nh_grp, vr_entry); in mlxsw_sp_nexthop_group_vr_unlink()
3428 struct mlxsw_sp_nexthop_group_vr_entry *vr_entry; in mlxsw_sp_adj_index_mass_update() local
3431 list_for_each_entry(vr_entry, &nh_grp->vr_list, list) { in mlxsw_sp_adj_index_mass_update()
3433 vr_entry->key.proto, in mlxsw_sp_adj_index_mass_update()
3434 vr_entry->key.vr_id, in mlxsw_sp_adj_index_mass_update()
3445 list_for_each_entry_continue_reverse(vr_entry, &nh_grp->vr_list, list) in mlxsw_sp_adj_index_mass_update()
3446 mlxsw_sp_adj_index_mass_update_vr(mlxsw_sp, vr_entry->key.proto, in mlxsw_sp_adj_index_mass_update()
3447 vr_entry->key.vr_id, in mlxsw_sp_adj_index_mass_update()