Lines Matching full:nh
23 static void remove_nexthop(struct net *net, struct nexthop *nh,
101 const struct nexthop *nh) in nh_notifier_single_info_init() argument
103 struct nh_info *nhi = rtnl_dereference(nh->nh_info); in nh_notifier_single_info_init()
106 info->nh = kzalloc(sizeof(*info->nh), GFP_KERNEL); in nh_notifier_single_info_init()
107 if (!info->nh) in nh_notifier_single_info_init()
110 __nh_notifier_single_info_init(info->nh, nhi); in nh_notifier_single_info_init()
117 kfree(info->nh); in nh_notifier_single_info_fini()
139 nhi = rtnl_dereference(nhge->nh->nh_info); in nh_notifier_mpath_info_init()
140 info->nh_grp->nh_entries[i].id = nhge->nh->id; in nh_notifier_mpath_info_init()
142 __nh_notifier_single_info_init(&info->nh_grp->nh_entries[i].nh, in nh_notifier_mpath_info_init()
172 nhi = rtnl_dereference(nhge->nh->nh_info); in nh_notifier_res_table_info_init()
181 const struct nexthop *nh) in nh_notifier_grp_info_init() argument
183 struct nh_group *nhg = rtnl_dereference(nh->nh_grp); in nh_notifier_grp_info_init()
193 const struct nexthop *nh) in nh_notifier_grp_info_fini() argument
195 struct nh_group *nhg = rtnl_dereference(nh->nh_grp); in nh_notifier_grp_info_fini()
204 const struct nexthop *nh) in nh_notifier_info_init() argument
206 info->id = nh->id; in nh_notifier_info_init()
208 if (nh->is_group) in nh_notifier_info_init()
209 return nh_notifier_grp_info_init(info, nh); in nh_notifier_info_init()
211 return nh_notifier_single_info_init(info, nh); in nh_notifier_info_init()
215 const struct nexthop *nh) in nh_notifier_info_fini() argument
217 if (nh->is_group) in nh_notifier_info_fini()
218 nh_notifier_grp_info_fini(info, nh); in nh_notifier_info_fini()
225 struct nexthop *nh, in call_nexthop_notifiers() argument
239 err = nh_notifier_info_init(&info, nh); in call_nexthop_notifiers()
247 nh_notifier_info_fini(&info, nh); in call_nexthop_notifiers()
258 struct nexthop *nh; in nh_notifier_res_bucket_idle_timer_get() local
277 nh = nexthop_find_by_id(info->net, info->id); in nh_notifier_res_bucket_idle_timer_get()
278 if (!nh) { in nh_notifier_res_bucket_idle_timer_get()
283 nhg = rcu_dereference(nh->nh_grp); in nh_notifier_res_bucket_idle_timer_get()
355 * 1) a collection of callbacks for NH maintenance. This operates under
390 static int call_nexthop_res_table_notifiers(struct net *net, struct nexthop *nh, in call_nexthop_res_table_notifiers() argument
409 nhg = rtnl_dereference(nh->nh_grp); in call_nexthop_res_table_notifiers()
426 struct nexthop *nh, in call_nexthop_notifier() argument
435 err = nh_notifier_info_init(&info, nh); in call_nexthop_notifier()
440 nh_notifier_info_fini(&info, nh); in call_nexthop_notifier()
467 static void nexthop_free_group(struct nexthop *nh) in nexthop_free_group() argument
472 nhg = rcu_dereference_raw(nh->nh_grp); in nexthop_free_group()
477 nexthop_put(nhge->nh); in nexthop_free_group()
489 static void nexthop_free_single(struct nexthop *nh) in nexthop_free_single() argument
493 nhi = rcu_dereference_raw(nh->nh_info); in nexthop_free_single()
496 fib_nh_release(nh->net, &nhi->fib_nh); in nexthop_free_single()
507 struct nexthop *nh = container_of(head, struct nexthop, rcu); in nexthop_free_rcu() local
509 if (nh->is_group) in nexthop_free_rcu()
510 nexthop_free_group(nh); in nexthop_free_rcu()
512 nexthop_free_single(nh); in nexthop_free_rcu()
514 kfree(nh); in nexthop_free_rcu()
520 struct nexthop *nh; in nexthop_alloc() local
522 nh = kzalloc(sizeof(struct nexthop), GFP_KERNEL); in nexthop_alloc()
523 if (nh) { in nexthop_alloc()
524 INIT_LIST_HEAD(&nh->fi_list); in nexthop_alloc()
525 INIT_LIST_HEAD(&nh->f6i_list); in nexthop_alloc()
526 INIT_LIST_HEAD(&nh->grp_list); in nexthop_alloc()
527 INIT_LIST_HEAD(&nh->fdb_list); in nexthop_alloc()
529 return nh; in nexthop_alloc()
580 struct nexthop *nh; in nexthop_find_by_id() local
587 nh = rb_entry(parent, struct nexthop, rb_node); in nexthop_find_by_id()
588 if (id < nh->id) in nexthop_find_by_id()
590 else if (id > nh->id) in nexthop_find_by_id()
593 return nh; in nexthop_find_by_id()
679 p->id = nhg->nh_entries[i].nh->id; in nla_put_nh_group()
693 static int nh_fill_node(struct sk_buff *skb, struct nexthop *nh, in nh_fill_node() argument
708 nhm->nh_flags = nh->nh_flags; in nh_fill_node()
709 nhm->nh_protocol = nh->protocol; in nh_fill_node()
713 if (nla_put_u32(skb, NHA_ID, nh->id)) in nh_fill_node()
716 if (nh->is_group) { in nh_fill_node()
717 struct nh_group *nhg = rtnl_dereference(nh->nh_grp); in nh_fill_node()
726 nhi = rtnl_dereference(nh->nh_info); in nh_fill_node()
783 static size_t nh_nlmsg_size_grp(struct nexthop *nh) in nh_nlmsg_size_grp() argument
785 struct nh_group *nhg = rtnl_dereference(nh->nh_grp); in nh_nlmsg_size_grp()
796 static size_t nh_nlmsg_size_single(struct nexthop *nh) in nh_nlmsg_size_single() argument
798 struct nh_info *nhi = rtnl_dereference(nh->nh_info); in nh_nlmsg_size_single()
827 static size_t nh_nlmsg_size(struct nexthop *nh) in nh_nlmsg_size() argument
833 if (nh->is_group) in nh_nlmsg_size()
834 sz += nh_nlmsg_size_grp(nh); in nh_nlmsg_size()
836 sz += nh_nlmsg_size_single(nh); in nh_nlmsg_size()
841 static void nexthop_notify(int event, struct nexthop *nh, struct nl_info *info) in nexthop_notify() argument
848 skb = nlmsg_new(nh_nlmsg_size(nh), gfp_any()); in nexthop_notify()
852 err = nh_fill_node(skb, nh, event, info->portid, seq, nlflags); in nexthop_notify()
914 static int nh_fill_res_bucket(struct sk_buff *skb, struct nexthop *nh, in nh_fill_res_bucket() argument
932 nhm->nh_protocol = nh->protocol; in nh_fill_res_bucket()
936 if (nla_put_u32(skb, NHA_ID, nh->id)) in nh_fill_res_bucket()
944 nla_put_u32(skb, NHA_RES_BUCKET_NH_ID, nhge->nh->id) || in nh_fill_res_bucket()
966 struct nexthop *nh = nhge->nh_parent; in nexthop_bucket_notify() local
974 err = nh_fill_res_bucket(skb, nh, bucket, bucket_index, in nexthop_bucket_notify()
982 rtnl_notify(skb, nh->net, 0, RTNLGRP_NEXTHOP, NULL, GFP_KERNEL); in nexthop_bucket_notify()
986 rtnl_set_sk_err(nh->net, RTNLGRP_NEXTHOP, err); in nexthop_bucket_notify()
989 static bool valid_group_nh(struct nexthop *nh, unsigned int npaths, in valid_group_nh() argument
992 if (nh->is_group) { in valid_group_nh()
993 struct nh_group *nhg = rtnl_dereference(nh->nh_grp); in valid_group_nh()
1008 struct nh_info *nhi = rtnl_dereference(nh->nh_info); in valid_group_nh()
1021 static int nh_check_attr_fdb_group(struct nexthop *nh, u8 *nh_family, in nh_check_attr_fdb_group() argument
1026 nhi = rtnl_dereference(nh->nh_info); in nh_check_attr_fdb_group()
1084 struct nexthop *nh; in nh_check_attr_group() local
1087 nh = nexthop_find_by_id(net, nhg[i].id); in nh_check_attr_group()
1088 if (!nh) { in nh_check_attr_group()
1092 if (!valid_group_nh(nh, len, &is_fdb_nh, extack)) in nh_check_attr_group()
1095 if (nhg_fdb && nh_check_attr_fdb_group(nh, &nh_family, extack)) in nh_check_attr_group()
1122 static bool ipv6_good_nh(const struct fib6_nh *nh) in ipv6_good_nh() argument
1129 n = __ipv6_neigh_lookup_noref_stub(nh->fib_nh_dev, &nh->fib_nh_gw6); in ipv6_good_nh()
1138 static bool ipv4_good_nh(const struct fib_nh *nh) in ipv4_good_nh() argument
1145 n = __ipv4_neigh_lookup_noref(nh->fib_nh_dev, in ipv4_good_nh()
1146 (__force u32)nh->fib_nh_gw4); in ipv4_good_nh()
1167 nhi = rcu_dereference(nhge->nh->nh_info); in nexthop_select_path_hthr()
1169 return nhge->nh; in nexthop_select_path_hthr()
1177 return nhge->nh; in nexthop_select_path_hthr()
1181 return nhge->nh; in nexthop_select_path_hthr()
1186 rc = nhge->nh; in nexthop_select_path_hthr()
1205 return nhge->nh; in nexthop_select_path_res()
1208 struct nexthop *nexthop_select_path(struct nexthop *nh, int hash) in nexthop_select_path() argument
1212 if (!nh->is_group) in nexthop_select_path()
1213 return nh; in nexthop_select_path()
1215 nhg = rcu_dereference(nh->nh_grp); in nexthop_select_path()
1226 int nexthop_for_each_fib6_nh(struct nexthop *nh, in nexthop_for_each_fib6_nh() argument
1227 int (*cb)(struct fib6_nh *nh, void *arg), in nexthop_for_each_fib6_nh() argument
1233 if (nh->is_group) { in nexthop_for_each_fib6_nh()
1237 nhg = rcu_dereference_rtnl(nh->nh_grp); in nexthop_for_each_fib6_nh()
1241 nhi = rcu_dereference_rtnl(nhge->nh->nh_info); in nexthop_for_each_fib6_nh()
1247 nhi = rcu_dereference_rtnl(nh->nh_info); in nexthop_for_each_fib6_nh()
1267 int fib6_check_nexthop(struct nexthop *nh, struct fib6_config *cfg, in fib6_check_nexthop() argument
1282 if (nh->is_group) { in fib6_check_nexthop()
1285 nhg = rtnl_dereference(nh->nh_grp); in fib6_check_nexthop()
1290 nhi = rtnl_dereference(nh->nh_info); in fib6_check_nexthop()
1348 int fib_check_nexthop(struct nexthop *nh, u8 scope, in fib_check_nexthop() argument
1354 if (nh->is_group) { in fib_check_nexthop()
1357 nhg = rtnl_dereference(nh->nh_grp); in fib_check_nexthop()
1371 nhi = rtnl_dereference(nhg->nh_entries[0].nh->nh_info); in fib_check_nexthop()
1374 nhi = rtnl_dereference(nh->nh_info); in fib_check_nexthop()
1528 old_nhge->nh, in nh_res_bucket_migrate()
1529 new_nhge->nh, &extack); in nh_res_bucket_migrate()
1664 * the right NH ID. Set those buckets that do not have a corresponding NHGE
1674 u32 id = rtnl_dereference(bucket->nh_entry)->nh->id; in nh_res_table_migrate_buckets()
1681 if (nhge->nh->id == id) { in nh_res_table_migrate_buckets()
1696 /* For NH group replacement, the new NHG might only have a stub in replace_nexthop_grp_res()
1698 * specified. For NH removal, oldg and newg both reference the same in replace_nexthop_grp_res()
1739 struct nexthop *nh = nhge->nh; in remove_nh_grp_entry() local
1743 WARN_ON(!nh); in remove_nh_grp_entry()
1768 if (nhg->nh_entries[i].nh == nh) { in remove_nh_grp_entry()
1773 nhi = rtnl_dereference(nhges[i].nh->nh_info); in remove_nh_grp_entry()
1779 new_nhges[j].nh = nhges[i].nh; in remove_nh_grp_entry()
1781 list_add(&new_nhges[j].nh_list, &new_nhges[j].nh->grp_list); in remove_nh_grp_entry()
1793 nexthop_put(nhge->nh); in remove_nh_grp_entry()
1795 /* Removal of a NH from a resilient group is notified through in remove_nh_grp_entry()
1809 static void remove_nexthop_from_groups(struct net *net, struct nexthop *nh, in remove_nexthop_from_groups() argument
1814 list_for_each_entry_safe(nhge, tmp, &nh->grp_list, nh_list) in remove_nexthop_from_groups()
1821 static void remove_nexthop_group(struct nexthop *nh, struct nl_info *nlinfo) in remove_nexthop_group() argument
1823 struct nh_group *nhg = rcu_dereference_rtnl(nh->nh_grp); in remove_nexthop_group()
1830 if (WARN_ON(!nhge->nh)) in remove_nexthop_group()
1843 static void __remove_nexthop_fib(struct net *net, struct nexthop *nh) in __remove_nexthop_fib() argument
1849 list_for_each_entry(fi, &nh->fi_list, nh_list) { in __remove_nexthop_fib()
1857 list_for_each_entry_safe(f6i, tmp, &nh->f6i_list, nh_list) { in __remove_nexthop_fib()
1865 static void __remove_nexthop(struct net *net, struct nexthop *nh, in __remove_nexthop() argument
1868 __remove_nexthop_fib(net, nh); in __remove_nexthop()
1870 if (nh->is_group) { in __remove_nexthop()
1871 remove_nexthop_group(nh, nlinfo); in __remove_nexthop()
1875 nhi = rtnl_dereference(nh->nh_info); in __remove_nexthop()
1879 remove_nexthop_from_groups(net, nh, nlinfo); in __remove_nexthop()
1883 static void remove_nexthop(struct net *net, struct nexthop *nh, in remove_nexthop() argument
1886 call_nexthop_notifiers(net, NEXTHOP_EVENT_DEL, nh, NULL); in remove_nexthop()
1889 rb_erase(&nh->rb_node, &net->nexthop.rb_root); in remove_nexthop()
1892 nexthop_notify(RTM_DELNEXTHOP, nh, nlinfo); in remove_nexthop()
1894 __remove_nexthop(net, nh, nlinfo); in remove_nexthop()
1897 nexthop_put(nh); in remove_nexthop()
1903 static void nh_rt_cache_flush(struct net *net, struct nexthop *nh, in nh_rt_cache_flush() argument
1910 if (!list_empty(&nh->fi_list)) in nh_rt_cache_flush()
1913 list_for_each_entry(f6i, &nh->f6i_list, nh_list) in nh_rt_cache_flush()
1925 struct nh_info *nhi = rtnl_dereference(nhge->nh->nh_info); in nh_rt_cache_flush()
2029 nhi = rtnl_dereference(nhges[i].nh->nh_info); in nh_group_v4_update()
2052 if (nhge->nh == old) { in replace_nexthop_single_notify_res()
2070 if (nhge->nh == old) in replace_nexthop_single_notify_res()
2180 static void __nexthop_replace_notify(struct net *net, struct nexthop *nh, in __nexthop_replace_notify() argument
2185 if (!list_empty(&nh->fi_list)) { in __nexthop_replace_notify()
2192 list_for_each_entry(fi, &nh->fi_list, nh_list) in __nexthop_replace_notify()
2197 list_for_each_entry(fi, &nh->fi_list, nh_list) in __nexthop_replace_notify()
2201 list_for_each_entry(f6i, &nh->f6i_list, nh_list) in __nexthop_replace_notify()
2209 static void nexthop_replace_notify(struct net *net, struct nexthop *nh, in nexthop_replace_notify() argument
2214 __nexthop_replace_notify(net, nh, info); in nexthop_replace_notify()
2216 list_for_each_entry(nhge, &nh->grp_list, nh_list) in nexthop_replace_notify()
2293 struct nexthop *nh; in insert_nexthop() local
2301 nh = rb_entry(parent, struct nexthop, rb_node); in insert_nexthop()
2302 if (new_id < nh->id) { in insert_nexthop()
2304 } else if (new_id > nh->id) { in insert_nexthop()
2307 rc = replace_nexthop(net, nh, new_nh, cfg, extack); in insert_nexthop()
2309 new_nh = nh; /* send notification with old nh */ in insert_nexthop()
2399 struct nexthop *nh; in flush_all_nexthops() local
2402 nh = rb_entry(node, struct nexthop, rb_node); in flush_all_nexthops()
2403 remove_nexthop(net, nh, NULL); in flush_all_nexthops()
2415 struct nexthop *nh; in nexthop_create_group() local
2422 nh = nexthop_alloc(); in nexthop_create_group()
2423 if (!nh) in nexthop_create_group()
2426 nh->is_group = 1; in nexthop_create_group()
2430 kfree(nh); in nexthop_create_group()
2438 kfree(nh); in nexthop_create_group()
2457 nhg->nh_entries[i].nh = nhe; in nexthop_create_group()
2460 nhg->nh_entries[i].nh_parent = nh; in nexthop_create_group()
2489 rcu_assign_pointer(nh->nh_grp, nhg); in nexthop_create_group()
2491 return nh; in nexthop_create_group()
2496 nexthop_put(nhg->nh_entries[i].nh); in nexthop_create_group()
2501 kfree(nh); in nexthop_create_group()
2506 static int nh_create_ipv4(struct net *net, struct nexthop *nh, in nh_create_ipv4() argument
2535 nh->nh_flags = fib_nh->fib_nh_flags; in nh_create_ipv4()
2545 static int nh_create_ipv6(struct net *net, struct nexthop *nh, in nh_create_ipv6() argument
2574 nh->nh_flags = fib6_nh->fib_nh_flags; in nh_create_ipv6()
2584 struct nexthop *nh; in nexthop_create() local
2587 nh = nexthop_alloc(); in nexthop_create()
2588 if (!nh) in nexthop_create()
2593 kfree(nh); in nexthop_create()
2597 nh->nh_flags = cfg->nh_flags; in nexthop_create()
2598 nh->net = net; in nexthop_create()
2600 nhi->nh_parent = nh; in nexthop_create()
2614 err = nh_create_ipv4(net, nh, nhi, cfg, extack); in nexthop_create()
2617 err = nh_create_ipv6(net, nh, nhi, cfg, extack); in nexthop_create()
2623 kfree(nh); in nexthop_create()
2631 rcu_assign_pointer(nh->nh_info, nhi); in nexthop_create()
2633 return nh; in nexthop_create()
2640 struct nexthop *nh; in nexthop_add() local
2657 nh = nexthop_create_group(net, cfg); in nexthop_add()
2659 nh = nexthop_create(net, cfg, extack); in nexthop_add()
2661 if (IS_ERR(nh)) in nexthop_add()
2662 return nh; in nexthop_add()
2664 refcount_set(&nh->refcnt, 1); in nexthop_add()
2665 nh->id = cfg->nh_id; in nexthop_add()
2666 nh->protocol = cfg->nh_protocol; in nexthop_add()
2667 nh->net = net; in nexthop_add()
2669 err = insert_nexthop(net, nh, cfg, extack); in nexthop_add()
2671 __remove_nexthop(net, nh, NULL); in nexthop_add()
2672 nexthop_put(nh); in nexthop_add()
2673 nh = ERR_PTR(err); in nexthop_add()
2676 return nh; in nexthop_add()
2933 struct nexthop *nh; in rtm_new_nexthop() local
2938 nh = nexthop_add(net, &cfg, extack); in rtm_new_nexthop()
2939 if (IS_ERR(nh)) in rtm_new_nexthop()
2940 err = PTR_ERR(nh); in rtm_new_nexthop()
2996 struct nexthop *nh; in rtm_del_nexthop() local
3004 nh = nexthop_find_by_id(net, id); in rtm_del_nexthop()
3005 if (!nh) in rtm_del_nexthop()
3008 remove_nexthop(net, nh, &nlinfo); in rtm_del_nexthop()
3019 struct nexthop *nh; in rtm_get_nexthop() local
3033 nh = nexthop_find_by_id(net, id); in rtm_get_nexthop()
3034 if (!nh) in rtm_get_nexthop()
3037 err = nh_fill_node(skb, nh, RTM_NEWNEXTHOP, NETLINK_CB(in_skb).portid, in rtm_get_nexthop()
3061 static bool nh_dump_filtered(struct nexthop *nh, in nh_dump_filtered() argument
3067 if (filter->group_filter && !nh->is_group) in nh_dump_filtered()
3073 if (nh->is_group) in nh_dump_filtered()
3076 nhi = rtnl_dereference(nh->nh_info); in nh_dump_filtered()
3168 struct nexthop *nh, void *data), in rtm_dump_walk_nexthops() argument
3177 struct nexthop *nh; in rtm_dump_walk_nexthops() local
3179 nh = rb_entry(node, struct nexthop, rb_node); in rtm_dump_walk_nexthops()
3180 if (nh->id < s_idx) in rtm_dump_walk_nexthops()
3183 ctx->idx = nh->id; in rtm_dump_walk_nexthops()
3184 err = nh_cb(skb, cb, nh, data); in rtm_dump_walk_nexthops()
3194 struct nexthop *nh, void *data) in rtm_dump_nexthop_cb() argument
3199 if (nh_dump_filtered(nh, filter, nhm->nh_family)) in rtm_dump_nexthop_cb()
3202 return nh_fill_node(skb, nh, RTM_NEWNEXTHOP, in rtm_dump_nexthop_cb()
3241 struct nexthop *nh; in nexthop_find_group_resilient() local
3243 nh = nexthop_find_by_id(net, id); in nexthop_find_group_resilient()
3244 if (!nh) in nexthop_find_group_resilient()
3247 if (!nh->is_group) { in nexthop_find_group_resilient()
3252 nhg = rtnl_dereference(nh->nh_grp); in nexthop_find_group_resilient()
3258 return nh; in nexthop_find_group_resilient()
3319 struct rtm_dump_nh_ctx nh; member
3321 u32 done_nh_idx; /* 1 + the index of the last fully processed NH. */
3340 struct nexthop *nh, in rtm_dump_nexthop_bucket_nh() argument
3350 if (dd->ctx->nh.idx < dd->ctx->done_nh_idx) in rtm_dump_nexthop_bucket_nh()
3353 nhg = rtnl_dereference(nh->nh_grp); in rtm_dump_nexthop_bucket_nh()
3363 if (nh_dump_filtered(nhge->nh, &dd->filter, nhm->nh_family)) in rtm_dump_nexthop_bucket_nh()
3367 dd->filter.res_bucket_nh_id != nhge->nh->id) in rtm_dump_nexthop_bucket_nh()
3370 err = nh_fill_res_bucket(skb, nh, bucket, bucket_index, in rtm_dump_nexthop_bucket_nh()
3381 dd->ctx->done_nh_idx = dd->ctx->nh.idx + 1; in rtm_dump_nexthop_bucket_nh()
3393 struct nexthop *nh, void *data) in rtm_dump_nexthop_bucket_cb() argument
3398 if (!nh->is_group) in rtm_dump_nexthop_bucket_cb()
3401 nhg = rtnl_dereference(nh->nh_grp); in rtm_dump_nexthop_bucket_cb()
3405 return rtm_dump_nexthop_bucket_nh(skb, cb, nh, dd); in rtm_dump_nexthop_bucket_cb()
3415 struct nexthop *nh; in rtm_dump_nexthop_bucket() local
3423 nh = nexthop_find_group_resilient(net, dd.filter.nh_id, in rtm_dump_nexthop_bucket()
3425 if (IS_ERR(nh)) in rtm_dump_nexthop_bucket()
3426 return PTR_ERR(nh); in rtm_dump_nexthop_bucket()
3427 err = rtm_dump_nexthop_bucket_nh(skb, cb, nh, &dd); in rtm_dump_nexthop_bucket()
3431 err = rtm_dump_walk_nexthops(skb, cb, root, &ctx->nh, in rtm_dump_nexthop_bucket()
3508 struct nexthop *nh; in rtm_get_nexthop_bucket() local
3517 nh = nexthop_find_group_resilient(net, id, extack); in rtm_get_nexthop_bucket()
3518 if (IS_ERR(nh)) in rtm_get_nexthop_bucket()
3519 return PTR_ERR(nh); in rtm_get_nexthop_bucket()
3521 nhg = rtnl_dereference(nh->nh_grp); in rtm_get_nexthop_bucket()
3532 err = nh_fill_res_bucket(skb, nh, &res_table->nh_buckets[bucket_index], in rtm_get_nexthop_bucket()
3603 struct nexthop *nh; in nexthops_dump() local
3605 nh = rb_entry(node, struct nexthop, rb_node); in nexthops_dump()
3606 err = call_nexthop_notifier(nb, net, event_type, nh, extack); in nexthops_dump()