aboutsummaryrefslogtreecommitdiffstats
path: root/net/batman-adv/gateway_client.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/batman-adv/gateway_client.c')
-rw-r--r--net/batman-adv/gateway_client.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/net/batman-adv/gateway_client.c b/net/batman-adv/gateway_client.c
index a3f944b6ac53..e92055da5074 100644
--- a/net/batman-adv/gateway_client.c
+++ b/net/batman-adv/gateway_client.c
@@ -124,7 +124,7 @@ static struct gw_node *gw_get_best_gw_node(struct bat_priv *bat_priv)
124 continue; 124 continue;
125 125
126 orig_node = gw_node->orig_node; 126 orig_node = gw_node->orig_node;
127 router = orig_node_get_router(orig_node); 127 router = batadv_orig_node_get_router(orig_node);
128 if (!router) 128 if (!router)
129 continue; 129 continue;
130 130
@@ -177,7 +177,7 @@ static struct gw_node *gw_get_best_gw_node(struct bat_priv *bat_priv)
177 gw_node_free_ref(gw_node); 177 gw_node_free_ref(gw_node);
178 178
179next: 179next:
180 neigh_node_free_ref(router); 180 batadv_neigh_node_free_ref(router);
181 } 181 }
182 rcu_read_unlock(); 182 rcu_read_unlock();
183 183
@@ -212,7 +212,7 @@ void batadv_gw_election(struct bat_priv *bat_priv)
212 if (next_gw) { 212 if (next_gw) {
213 sprintf(gw_addr, "%pM", next_gw->orig_node->orig); 213 sprintf(gw_addr, "%pM", next_gw->orig_node->orig);
214 214
215 router = orig_node_get_router(next_gw->orig_node); 215 router = batadv_orig_node_get_router(next_gw->orig_node);
216 if (!router) { 216 if (!router) {
217 batadv_gw_deselect(bat_priv); 217 batadv_gw_deselect(bat_priv);
218 goto out; 218 goto out;
@@ -245,7 +245,7 @@ out:
245 if (next_gw) 245 if (next_gw)
246 gw_node_free_ref(next_gw); 246 gw_node_free_ref(next_gw);
247 if (router) 247 if (router)
248 neigh_node_free_ref(router); 248 batadv_neigh_node_free_ref(router);
249} 249}
250 250
251void batadv_gw_check_election(struct bat_priv *bat_priv, 251void batadv_gw_check_election(struct bat_priv *bat_priv,
@@ -259,7 +259,7 @@ void batadv_gw_check_election(struct bat_priv *bat_priv,
259 if (!curr_gw_orig) 259 if (!curr_gw_orig)
260 goto deselect; 260 goto deselect;
261 261
262 router_gw = orig_node_get_router(curr_gw_orig); 262 router_gw = batadv_orig_node_get_router(curr_gw_orig);
263 if (!router_gw) 263 if (!router_gw)
264 goto deselect; 264 goto deselect;
265 265
@@ -267,7 +267,7 @@ void batadv_gw_check_election(struct bat_priv *bat_priv,
267 if (curr_gw_orig == orig_node) 267 if (curr_gw_orig == orig_node)
268 goto out; 268 goto out;
269 269
270 router_orig = orig_node_get_router(orig_node); 270 router_orig = batadv_orig_node_get_router(orig_node);
271 if (!router_orig) 271 if (!router_orig)
272 goto out; 272 goto out;
273 273
@@ -294,11 +294,11 @@ deselect:
294 batadv_gw_deselect(bat_priv); 294 batadv_gw_deselect(bat_priv);
295out: 295out:
296 if (curr_gw_orig) 296 if (curr_gw_orig)
297 orig_node_free_ref(curr_gw_orig); 297 batadv_orig_node_free_ref(curr_gw_orig);
298 if (router_gw) 298 if (router_gw)
299 neigh_node_free_ref(router_gw); 299 batadv_neigh_node_free_ref(router_gw);
300 if (router_orig) 300 if (router_orig)
301 neigh_node_free_ref(router_orig); 301 batadv_neigh_node_free_ref(router_orig);
302 302
303 return; 303 return;
304} 304}
@@ -438,7 +438,7 @@ static int _write_buffer_text(struct bat_priv *bat_priv, struct seq_file *seq,
438 438
439 batadv_gw_bandwidth_to_kbit(gw_node->orig_node->gw_flags, &down, &up); 439 batadv_gw_bandwidth_to_kbit(gw_node->orig_node->gw_flags, &down, &up);
440 440
441 router = orig_node_get_router(gw_node->orig_node); 441 router = batadv_orig_node_get_router(gw_node->orig_node);
442 if (!router) 442 if (!router)
443 goto out; 443 goto out;
444 444
@@ -455,7 +455,7 @@ static int _write_buffer_text(struct bat_priv *bat_priv, struct seq_file *seq,
455 (up > 2048 ? up / 1024 : up), 455 (up > 2048 ? up / 1024 : up),
456 (up > 2048 ? "MBit" : "KBit")); 456 (up > 2048 ? "MBit" : "KBit"));
457 457
458 neigh_node_free_ref(router); 458 batadv_neigh_node_free_ref(router);
459 if (curr_gw) 459 if (curr_gw)
460 gw_node_free_ref(curr_gw); 460 gw_node_free_ref(curr_gw);
461out: 461out:
@@ -702,12 +702,12 @@ bool batadv_gw_out_of_range(struct bat_priv *bat_priv,
702 702
703out: 703out:
704 if (orig_dst_node) 704 if (orig_dst_node)
705 orig_node_free_ref(orig_dst_node); 705 batadv_orig_node_free_ref(orig_dst_node);
706 if (curr_gw) 706 if (curr_gw)
707 gw_node_free_ref(curr_gw); 707 gw_node_free_ref(curr_gw);
708 if (neigh_old) 708 if (neigh_old)
709 neigh_node_free_ref(neigh_old); 709 batadv_neigh_node_free_ref(neigh_old);
710 if (neigh_curr) 710 if (neigh_curr)
711 neigh_node_free_ref(neigh_curr); 711 batadv_neigh_node_free_ref(neigh_curr);
712 return out_of_range; 712 return out_of_range;
713} 713}