Searched refs:gw_node (Results 1 – 4 of 4) sorted by relevance
/linux/net/batman-adv/ |
H A D | gateway_client.c | 58 * batadv_gw_node_release() - release gw_node from lists and queue for free 60 * @ref: kref pointer of the gw_node 64 struct batadv_gw_node *gw_node; in batadv_gw_node_release() local 66 gw_node = container_of(ref, struct batadv_gw_node, refcount); in batadv_gw_node_release() 68 batadv_orig_node_put(gw_node->orig_node); in batadv_gw_node_release() 69 kfree_rcu(gw_node, rcu); in batadv_gw_node_release() 81 struct batadv_gw_node *gw_node; in batadv_gw_get_selected_gw_node() local 84 gw_node = rcu_dereference(bat_priv->gw.curr_gw); in batadv_gw_get_selected_gw_node() 85 if (!gw_node) in batadv_gw_get_selected_gw_node() 88 if (!kref_get_unless_zero(&gw_node in batadv_gw_get_selected_gw_node() 105 struct batadv_gw_node *gw_node; batadv_gw_get_selected_orig() local 328 struct batadv_gw_node *gw_node; batadv_gw_node_add() local 372 struct batadv_gw_node *gw_node_tmp, *gw_node = NULL; batadv_gw_node_get() local 402 struct batadv_gw_node *gw_node, *curr_gw = NULL; batadv_gw_node_update() local 481 struct batadv_gw_node *gw_node; batadv_gw_node_free() local 679 struct batadv_gw_node *gw_node = NULL; batadv_gw_out_of_range() local [all...] |
H A D | bat_v.c | 513 * @gw_node: the GW to retrieve the metric for 520 static int batadv_v_gw_throughput_get(struct batadv_gw_node *gw_node, u32 *bw) in batadv_v_gw_throughput_get() argument 527 orig_node = gw_node->orig_node; in batadv_v_gw_throughput_get() 542 *bw = min_t(u32, *bw, gw_node->bandwidth_down); in batadv_v_gw_throughput_get() 561 struct batadv_gw_node *gw_node, *curr_gw = NULL; in batadv_v_gw_get_best_gw_node() local 565 hlist_for_each_entry_rcu(gw_node, &bat_priv->gw.gateway_list, list) { in batadv_v_gw_get_best_gw_node() 566 if (!kref_get_unless_zero(&gw_node->refcount)) in batadv_v_gw_get_best_gw_node() 569 if (batadv_v_gw_throughput_get(gw_node, &bw) < 0) in batadv_v_gw_get_best_gw_node() 577 curr_gw = gw_node; in batadv_v_gw_get_best_gw_node() 582 batadv_gw_node_put(gw_node); in batadv_v_gw_get_best_gw_node() 656 batadv_v_gw_dump_entry(struct sk_buff * msg,u32 portid,struct netlink_callback * cb,struct batadv_priv * bat_priv,struct batadv_gw_node * gw_node) batadv_v_gw_dump_entry() argument 753 struct batadv_gw_node *gw_node; batadv_v_gw_dump() local [all...] |
H A D | gateway_client.h | 43 * batadv_gw_node_put() - decrement the gw_node refcounter and possibly release 45 * @gw_node: gateway node to free 47 static inline void batadv_gw_node_put(struct batadv_gw_node *gw_node) in batadv_gw_node_put() argument 49 if (!gw_node) in batadv_gw_node_put() 52 kref_put(&gw_node->refcount, batadv_gw_node_release); in batadv_gw_node_put()
|
H A D | bat_iv_ogm.c | 2251 struct batadv_gw_node *gw_node, *curr_gw = NULL; in batadv_iv_gw_get_best_gw_node() local 2259 hlist_for_each_entry_rcu(gw_node, &bat_priv->gw.gateway_list, list) { in batadv_iv_gw_get_best_gw_node() 2260 orig_node = gw_node->orig_node; in batadv_iv_gw_get_best_gw_node() 2270 if (!kref_get_unless_zero(&gw_node->refcount)) in batadv_iv_gw_get_best_gw_node() 2278 tmp_gw_factor *= gw_node->bandwidth_down; in batadv_iv_gw_get_best_gw_node() 2286 curr_gw = gw_node; in batadv_iv_gw_get_best_gw_node() 2300 curr_gw = gw_node; in batadv_iv_gw_get_best_gw_node() 2312 batadv_gw_node_put(gw_node); in batadv_iv_gw_get_best_gw_node() 2394 * @gw_node: Gateway to be dumped 2401 struct batadv_gw_node *gw_node) in batadv_iv_gw_dump_entry() argument 2474 struct batadv_gw_node *gw_node; batadv_iv_gw_dump() local [all...] |