Lines Matching refs:curr_gw
85 gw_node = rcu_dereference(bat_priv->gw.curr_gw); in batadv_gw_get_selected_gw_node()
139 curr_gw_node = rcu_replace_pointer(bat_priv->gw.curr_gw, new_gw_node, in batadv_gw_select()
174 struct batadv_gw_node *curr_gw; in batadv_gw_check_client_stop() local
179 curr_gw = batadv_gw_get_selected_gw_node(bat_priv); in batadv_gw_check_client_stop()
180 if (!curr_gw) in batadv_gw_check_client_stop()
193 batadv_gw_node_put(curr_gw); in batadv_gw_check_client_stop()
202 struct batadv_gw_node *curr_gw = NULL; in batadv_gw_election() local
214 curr_gw = batadv_gw_get_selected_gw_node(bat_priv); in batadv_gw_election()
216 if (!batadv_atomic_dec_not_zero(&bat_priv->gw.reselect) && curr_gw) in batadv_gw_election()
225 if (curr_gw == next_gw) in batadv_gw_election()
246 if (curr_gw && !next_gw) { in batadv_gw_election()
251 } else if (!curr_gw && next_gw) { in batadv_gw_election()
278 if (curr_gw) in batadv_gw_election()
279 batadv_gw_node_put(curr_gw); in batadv_gw_election()
410 struct batadv_gw_node *gw_node, *curr_gw = NULL; in batadv_gw_node_update() local
456 curr_gw = batadv_gw_get_selected_gw_node(bat_priv); in batadv_gw_node_update()
457 if (gw_node == curr_gw) in batadv_gw_node_update()
460 if (curr_gw) in batadv_gw_node_update()
461 batadv_gw_node_put(curr_gw); in batadv_gw_node_update()
739 struct batadv_gw_node *curr_gw = NULL; in batadv_gw_out_of_range() local
768 curr_gw = batadv_gw_get_selected_gw_node(bat_priv); in batadv_gw_out_of_range()
769 if (!curr_gw) in batadv_gw_out_of_range()
773 if (curr_gw->orig_node == orig_dst_node) in batadv_gw_out_of_range()
780 neigh_curr = batadv_find_router(bat_priv, curr_gw->orig_node, in batadv_gw_out_of_range()
814 if (curr_gw) in batadv_gw_out_of_range()
815 batadv_gw_node_put(curr_gw); in batadv_gw_out_of_range()