diff options
author | Sven Eckelmann <sven@narfation.org> | 2012-05-12 07:48:58 -0400 |
---|---|---|
committer | Antonio Quartulli <ordex@autistici.org> | 2012-06-25 02:21:30 -0400 |
commit | 1eda58bfc56c43e73a0cf2bfb6e4d620ab866109 (patch) | |
tree | d71ba63d988193126831e49bdce03a1131d28ea4 /net/batman-adv/translation-table.c | |
parent | f0530ee5fb9e73465ac844ada2c96a2bea85a18f (diff) |
batman-adv: Prefix main static inline functions with batadv_
All non-static symbols of batman-adv were prefixed with batadv_ to avoid
collisions with other symbols of the kernel. Other symbols of batman-adv
should use the same prefix to keep the naming scheme consistent.
Signed-off-by: Sven Eckelmann <sven@narfation.org>
Diffstat (limited to 'net/batman-adv/translation-table.c')
-rw-r--r-- | net/batman-adv/translation-table.c | 149 |
1 files changed, 75 insertions, 74 deletions
diff --git a/net/batman-adv/translation-table.c b/net/batman-adv/translation-table.c index 1dfa2311bb1b..2eff22f9fdaa 100644 --- a/net/batman-adv/translation-table.c +++ b/net/batman-adv/translation-table.c | |||
@@ -66,7 +66,7 @@ static struct tt_common_entry *tt_hash_find(struct hashtable_t *hash, | |||
66 | 66 | ||
67 | rcu_read_lock(); | 67 | rcu_read_lock(); |
68 | hlist_for_each_entry_rcu(tt_common_entry, node, head, hash_entry) { | 68 | hlist_for_each_entry_rcu(tt_common_entry, node, head, hash_entry) { |
69 | if (!compare_eth(tt_common_entry, data)) | 69 | if (!batadv_compare_eth(tt_common_entry, data)) |
70 | continue; | 70 | continue; |
71 | 71 | ||
72 | if (!atomic_inc_not_zero(&tt_common_entry->refcount)) | 72 | if (!atomic_inc_not_zero(&tt_common_entry->refcount)) |
@@ -213,9 +213,9 @@ void batadv_tt_local_add(struct net_device *soft_iface, const uint8_t *addr, | |||
213 | if (!tt_local_entry) | 213 | if (!tt_local_entry) |
214 | goto out; | 214 | goto out; |
215 | 215 | ||
216 | bat_dbg(DBG_TT, bat_priv, | 216 | batadv_dbg(DBG_TT, bat_priv, |
217 | "Creating new local tt entry: %pM (ttvn: %d)\n", addr, | 217 | "Creating new local tt entry: %pM (ttvn: %d)\n", addr, |
218 | (uint8_t)atomic_read(&bat_priv->ttvn)); | 218 | (uint8_t)atomic_read(&bat_priv->ttvn)); |
219 | 219 | ||
220 | memcpy(tt_local_entry->common.addr, addr, ETH_ALEN); | 220 | memcpy(tt_local_entry->common.addr, addr, ETH_ALEN); |
221 | tt_local_entry->common.flags = NO_FLAGS; | 221 | tt_local_entry->common.flags = NO_FLAGS; |
@@ -225,7 +225,7 @@ void batadv_tt_local_add(struct net_device *soft_iface, const uint8_t *addr, | |||
225 | tt_local_entry->last_seen = jiffies; | 225 | tt_local_entry->last_seen = jiffies; |
226 | 226 | ||
227 | /* the batman interface mac address should never be purged */ | 227 | /* the batman interface mac address should never be purged */ |
228 | if (compare_eth(addr, soft_iface->dev_addr)) | 228 | if (batadv_compare_eth(addr, soft_iface->dev_addr)) |
229 | tt_local_entry->common.flags |= TT_CLIENT_NOPURGE; | 229 | tt_local_entry->common.flags |= TT_CLIENT_NOPURGE; |
230 | 230 | ||
231 | /* The local entry has to be marked as NEW to avoid to send it in | 231 | /* The local entry has to be marked as NEW to avoid to send it in |
@@ -441,9 +441,9 @@ static void tt_local_set_pending(struct bat_priv *bat_priv, | |||
441 | */ | 441 | */ |
442 | tt_local_entry->common.flags |= TT_CLIENT_PENDING; | 442 | tt_local_entry->common.flags |= TT_CLIENT_PENDING; |
443 | 443 | ||
444 | bat_dbg(DBG_TT, bat_priv, | 444 | batadv_dbg(DBG_TT, bat_priv, |
445 | "Local tt entry (%pM) pending to be removed: %s\n", | 445 | "Local tt entry (%pM) pending to be removed: %s\n", |
446 | tt_local_entry->common.addr, message); | 446 | tt_local_entry->common.addr, message); |
447 | } | 447 | } |
448 | 448 | ||
449 | void batadv_tt_local_remove(struct bat_priv *bat_priv, const uint8_t *addr, | 449 | void batadv_tt_local_remove(struct bat_priv *bat_priv, const uint8_t *addr, |
@@ -489,8 +489,8 @@ static void tt_local_purge(struct bat_priv *bat_priv) | |||
489 | if (tt_local_entry->common.flags & TT_CLIENT_PENDING) | 489 | if (tt_local_entry->common.flags & TT_CLIENT_PENDING) |
490 | continue; | 490 | continue; |
491 | 491 | ||
492 | if (!has_timed_out(tt_local_entry->last_seen, | 492 | if (!batadv_has_timed_out(tt_local_entry->last_seen, |
493 | TT_LOCAL_TIMEOUT)) | 493 | TT_LOCAL_TIMEOUT)) |
494 | continue; | 494 | continue; |
495 | 495 | ||
496 | tt_local_set_pending(bat_priv, tt_local_entry, | 496 | tt_local_set_pending(bat_priv, tt_local_entry, |
@@ -674,9 +674,9 @@ int batadv_tt_global_add(struct bat_priv *bat_priv, struct orig_node *orig_node, | |||
674 | if (wifi) | 674 | if (wifi) |
675 | tt_global_entry->common.flags |= TT_CLIENT_WIFI; | 675 | tt_global_entry->common.flags |= TT_CLIENT_WIFI; |
676 | 676 | ||
677 | bat_dbg(DBG_TT, bat_priv, | 677 | batadv_dbg(DBG_TT, bat_priv, |
678 | "Creating new global tt entry: %pM (via %pM)\n", | 678 | "Creating new global tt entry: %pM (via %pM)\n", |
679 | tt_global_entry->common.addr, orig_node->orig); | 679 | tt_global_entry->common.addr, orig_node->orig); |
680 | 680 | ||
681 | out_remove: | 681 | out_remove: |
682 | /* remove address from local hash if present */ | 682 | /* remove address from local hash if present */ |
@@ -800,10 +800,10 @@ static void tt_global_del_orig_entry(struct bat_priv *bat_priv, | |||
800 | head = &tt_global_entry->orig_list; | 800 | head = &tt_global_entry->orig_list; |
801 | hlist_for_each_entry_safe(orig_entry, node, safe, head, list) { | 801 | hlist_for_each_entry_safe(orig_entry, node, safe, head, list) { |
802 | if (orig_entry->orig_node == orig_node) { | 802 | if (orig_entry->orig_node == orig_node) { |
803 | bat_dbg(DBG_TT, bat_priv, | 803 | batadv_dbg(DBG_TT, bat_priv, |
804 | "Deleting %pM from global tt entry %pM: %s\n", | 804 | "Deleting %pM from global tt entry %pM: %s\n", |
805 | orig_node->orig, tt_global_entry->common.addr, | 805 | orig_node->orig, |
806 | message); | 806 | tt_global_entry->common.addr, message); |
807 | hlist_del_rcu(node); | 807 | hlist_del_rcu(node); |
808 | tt_orig_list_entry_free_ref(orig_entry); | 808 | tt_orig_list_entry_free_ref(orig_entry); |
809 | } | 809 | } |
@@ -815,9 +815,8 @@ static void tt_global_del_struct(struct bat_priv *bat_priv, | |||
815 | struct tt_global_entry *tt_global_entry, | 815 | struct tt_global_entry *tt_global_entry, |
816 | const char *message) | 816 | const char *message) |
817 | { | 817 | { |
818 | bat_dbg(DBG_TT, bat_priv, | 818 | batadv_dbg(DBG_TT, bat_priv, "Deleting global tt entry %pM: %s\n", |
819 | "Deleting global tt entry %pM: %s\n", | 819 | tt_global_entry->common.addr, message); |
820 | tt_global_entry->common.addr, message); | ||
821 | 820 | ||
822 | batadv_hash_remove(bat_priv->tt_global_hash, compare_tt, | 821 | batadv_hash_remove(bat_priv->tt_global_hash, compare_tt, |
823 | batadv_choose_orig, tt_global_entry->common.addr); | 822 | batadv_choose_orig, tt_global_entry->common.addr); |
@@ -951,10 +950,10 @@ void batadv_tt_global_del_orig(struct bat_priv *bat_priv, | |||
951 | orig_node, message); | 950 | orig_node, message); |
952 | 951 | ||
953 | if (hlist_empty(&tt_global_entry->orig_list)) { | 952 | if (hlist_empty(&tt_global_entry->orig_list)) { |
954 | bat_dbg(DBG_TT, bat_priv, | 953 | batadv_dbg(DBG_TT, bat_priv, |
955 | "Deleting global tt entry %pM: %s\n", | 954 | "Deleting global tt entry %pM: %s\n", |
956 | tt_global_entry->common.addr, | 955 | tt_global_entry->common.addr, |
957 | message); | 956 | message); |
958 | hlist_del_rcu(node); | 957 | hlist_del_rcu(node); |
959 | tt_global_entry_free_ref(tt_global_entry); | 958 | tt_global_entry_free_ref(tt_global_entry); |
960 | } | 959 | } |
@@ -987,13 +986,13 @@ static void tt_global_roam_purge(struct bat_priv *bat_priv) | |||
987 | common); | 986 | common); |
988 | if (!(tt_global_entry->common.flags & TT_CLIENT_ROAM)) | 987 | if (!(tt_global_entry->common.flags & TT_CLIENT_ROAM)) |
989 | continue; | 988 | continue; |
990 | if (!has_timed_out(tt_global_entry->roam_at, | 989 | if (!batadv_has_timed_out(tt_global_entry->roam_at, |
991 | TT_CLIENT_ROAM_TIMEOUT)) | 990 | TT_CLIENT_ROAM_TIMEOUT)) |
992 | continue; | 991 | continue; |
993 | 992 | ||
994 | bat_dbg(DBG_TT, bat_priv, | 993 | batadv_dbg(DBG_TT, bat_priv, |
995 | "Deleting global tt entry (%pM): Roaming timeout\n", | 994 | "Deleting global tt entry (%pM): Roaming timeout\n", |
996 | tt_global_entry->common.addr); | 995 | tt_global_entry->common.addr); |
997 | 996 | ||
998 | hlist_del_rcu(node); | 997 | hlist_del_rcu(node); |
999 | tt_global_entry_free_ref(tt_global_entry); | 998 | tt_global_entry_free_ref(tt_global_entry); |
@@ -1234,7 +1233,7 @@ static void tt_req_purge(struct bat_priv *bat_priv) | |||
1234 | 1233 | ||
1235 | spin_lock_bh(&bat_priv->tt_req_list_lock); | 1234 | spin_lock_bh(&bat_priv->tt_req_list_lock); |
1236 | list_for_each_entry_safe(node, safe, &bat_priv->tt_req_list, list) { | 1235 | list_for_each_entry_safe(node, safe, &bat_priv->tt_req_list, list) { |
1237 | if (has_timed_out(node->issued_at, TT_REQUEST_TIMEOUT)) { | 1236 | if (batadv_has_timed_out(node->issued_at, TT_REQUEST_TIMEOUT)) { |
1238 | list_del(&node->list); | 1237 | list_del(&node->list); |
1239 | kfree(node); | 1238 | kfree(node); |
1240 | } | 1239 | } |
@@ -1252,9 +1251,9 @@ static struct tt_req_node *new_tt_req_node(struct bat_priv *bat_priv, | |||
1252 | 1251 | ||
1253 | spin_lock_bh(&bat_priv->tt_req_list_lock); | 1252 | spin_lock_bh(&bat_priv->tt_req_list_lock); |
1254 | list_for_each_entry(tt_req_node_tmp, &bat_priv->tt_req_list, list) { | 1253 | list_for_each_entry(tt_req_node_tmp, &bat_priv->tt_req_list, list) { |
1255 | if (compare_eth(tt_req_node_tmp, orig_node) && | 1254 | if (batadv_compare_eth(tt_req_node_tmp, orig_node) && |
1256 | !has_timed_out(tt_req_node_tmp->issued_at, | 1255 | !batadv_has_timed_out(tt_req_node_tmp->issued_at, |
1257 | TT_REQUEST_TIMEOUT)) | 1256 | TT_REQUEST_TIMEOUT)) |
1258 | goto unlock; | 1257 | goto unlock; |
1259 | } | 1258 | } |
1260 | 1259 | ||
@@ -1409,10 +1408,10 @@ static int send_tt_request(struct bat_priv *bat_priv, | |||
1409 | if (!neigh_node) | 1408 | if (!neigh_node) |
1410 | goto out; | 1409 | goto out; |
1411 | 1410 | ||
1412 | bat_dbg(DBG_TT, bat_priv, | 1411 | batadv_dbg(DBG_TT, bat_priv, |
1413 | "Sending TT_REQUEST to %pM via %pM [%c]\n", | 1412 | "Sending TT_REQUEST to %pM via %pM [%c]\n", |
1414 | dst_orig_node->orig, neigh_node->addr, | 1413 | dst_orig_node->orig, neigh_node->addr, |
1415 | (full_table ? 'F' : '.')); | 1414 | (full_table ? 'F' : '.')); |
1416 | 1415 | ||
1417 | batadv_inc_counter(bat_priv, BAT_CNT_TT_REQUEST_TX); | 1416 | batadv_inc_counter(bat_priv, BAT_CNT_TT_REQUEST_TX); |
1418 | 1417 | ||
@@ -1449,10 +1448,10 @@ static bool send_other_tt_response(struct bat_priv *bat_priv, | |||
1449 | struct sk_buff *skb = NULL; | 1448 | struct sk_buff *skb = NULL; |
1450 | struct tt_query_packet *tt_response; | 1449 | struct tt_query_packet *tt_response; |
1451 | 1450 | ||
1452 | bat_dbg(DBG_TT, bat_priv, | 1451 | batadv_dbg(DBG_TT, bat_priv, |
1453 | "Received TT_REQUEST from %pM for ttvn: %u (%pM) [%c]\n", | 1452 | "Received TT_REQUEST from %pM for ttvn: %u (%pM) [%c]\n", |
1454 | tt_request->src, tt_request->ttvn, tt_request->dst, | 1453 | tt_request->src, tt_request->ttvn, tt_request->dst, |
1455 | (tt_request->flags & TT_FULL_TABLE ? 'F' : '.')); | 1454 | (tt_request->flags & TT_FULL_TABLE ? 'F' : '.')); |
1456 | 1455 | ||
1457 | /* Let's get the orig node of the REAL destination */ | 1456 | /* Let's get the orig node of the REAL destination */ |
1458 | req_dst_orig_node = batadv_orig_hash_find(bat_priv, tt_request->dst); | 1457 | req_dst_orig_node = batadv_orig_hash_find(bat_priv, tt_request->dst); |
@@ -1536,10 +1535,10 @@ static bool send_other_tt_response(struct bat_priv *bat_priv, | |||
1536 | if (full_table) | 1535 | if (full_table) |
1537 | tt_response->flags |= TT_FULL_TABLE; | 1536 | tt_response->flags |= TT_FULL_TABLE; |
1538 | 1537 | ||
1539 | bat_dbg(DBG_TT, bat_priv, | 1538 | batadv_dbg(DBG_TT, bat_priv, |
1540 | "Sending TT_RESPONSE %pM via %pM for %pM (ttvn: %u)\n", | 1539 | "Sending TT_RESPONSE %pM via %pM for %pM (ttvn: %u)\n", |
1541 | res_dst_orig_node->orig, neigh_node->addr, | 1540 | res_dst_orig_node->orig, neigh_node->addr, |
1542 | req_dst_orig_node->orig, req_ttvn); | 1541 | req_dst_orig_node->orig, req_ttvn); |
1543 | 1542 | ||
1544 | batadv_inc_counter(bat_priv, BAT_CNT_TT_RESPONSE_TX); | 1543 | batadv_inc_counter(bat_priv, BAT_CNT_TT_RESPONSE_TX); |
1545 | 1544 | ||
@@ -1578,10 +1577,10 @@ static bool send_my_tt_response(struct bat_priv *bat_priv, | |||
1578 | struct sk_buff *skb = NULL; | 1577 | struct sk_buff *skb = NULL; |
1579 | struct tt_query_packet *tt_response; | 1578 | struct tt_query_packet *tt_response; |
1580 | 1579 | ||
1581 | bat_dbg(DBG_TT, bat_priv, | 1580 | batadv_dbg(DBG_TT, bat_priv, |
1582 | "Received TT_REQUEST from %pM for ttvn: %u (me) [%c]\n", | 1581 | "Received TT_REQUEST from %pM for ttvn: %u (me) [%c]\n", |
1583 | tt_request->src, tt_request->ttvn, | 1582 | tt_request->src, tt_request->ttvn, |
1584 | (tt_request->flags & TT_FULL_TABLE ? 'F' : '.')); | 1583 | (tt_request->flags & TT_FULL_TABLE ? 'F' : '.')); |
1585 | 1584 | ||
1586 | 1585 | ||
1587 | my_ttvn = (uint8_t)atomic_read(&bat_priv->ttvn); | 1586 | my_ttvn = (uint8_t)atomic_read(&bat_priv->ttvn); |
@@ -1656,10 +1655,10 @@ static bool send_my_tt_response(struct bat_priv *bat_priv, | |||
1656 | if (full_table) | 1655 | if (full_table) |
1657 | tt_response->flags |= TT_FULL_TABLE; | 1656 | tt_response->flags |= TT_FULL_TABLE; |
1658 | 1657 | ||
1659 | bat_dbg(DBG_TT, bat_priv, | 1658 | batadv_dbg(DBG_TT, bat_priv, |
1660 | "Sending TT_RESPONSE to %pM via %pM [%c]\n", | 1659 | "Sending TT_RESPONSE to %pM via %pM [%c]\n", |
1661 | orig_node->orig, neigh_node->addr, | 1660 | orig_node->orig, neigh_node->addr, |
1662 | (tt_response->flags & TT_FULL_TABLE ? 'F' : '.')); | 1661 | (tt_response->flags & TT_FULL_TABLE ? 'F' : '.')); |
1663 | 1662 | ||
1664 | batadv_inc_counter(bat_priv, BAT_CNT_TT_RESPONSE_TX); | 1663 | batadv_inc_counter(bat_priv, BAT_CNT_TT_RESPONSE_TX); |
1665 | 1664 | ||
@@ -1795,11 +1794,11 @@ void batadv_handle_tt_response(struct bat_priv *bat_priv, | |||
1795 | struct tt_req_node *node, *safe; | 1794 | struct tt_req_node *node, *safe; |
1796 | struct orig_node *orig_node = NULL; | 1795 | struct orig_node *orig_node = NULL; |
1797 | 1796 | ||
1798 | bat_dbg(DBG_TT, bat_priv, | 1797 | batadv_dbg(DBG_TT, bat_priv, |
1799 | "Received TT_RESPONSE from %pM for ttvn %d t_size: %d [%c]\n", | 1798 | "Received TT_RESPONSE from %pM for ttvn %d t_size: %d [%c]\n", |
1800 | tt_response->src, tt_response->ttvn, | 1799 | tt_response->src, tt_response->ttvn, |
1801 | ntohs(tt_response->tt_data), | 1800 | ntohs(tt_response->tt_data), |
1802 | (tt_response->flags & TT_FULL_TABLE ? 'F' : '.')); | 1801 | (tt_response->flags & TT_FULL_TABLE ? 'F' : '.')); |
1803 | 1802 | ||
1804 | /* we should have never asked a backbone gw */ | 1803 | /* we should have never asked a backbone gw */ |
1805 | if (batadv_bla_is_backbone_gw_orig(bat_priv, tt_response->src)) | 1804 | if (batadv_bla_is_backbone_gw_orig(bat_priv, tt_response->src)) |
@@ -1820,7 +1819,7 @@ void batadv_handle_tt_response(struct bat_priv *bat_priv, | |||
1820 | /* Delete the tt_req_node from pending tt_requests list */ | 1819 | /* Delete the tt_req_node from pending tt_requests list */ |
1821 | spin_lock_bh(&bat_priv->tt_req_list_lock); | 1820 | spin_lock_bh(&bat_priv->tt_req_list_lock); |
1822 | list_for_each_entry_safe(node, safe, &bat_priv->tt_req_list, list) { | 1821 | list_for_each_entry_safe(node, safe, &bat_priv->tt_req_list, list) { |
1823 | if (!compare_eth(node->addr, tt_response->src)) | 1822 | if (!batadv_compare_eth(node->addr, tt_response->src)) |
1824 | continue; | 1823 | continue; |
1825 | list_del(&node->list); | 1824 | list_del(&node->list); |
1826 | kfree(node); | 1825 | kfree(node); |
@@ -1875,7 +1874,7 @@ static void tt_roam_purge(struct bat_priv *bat_priv) | |||
1875 | 1874 | ||
1876 | spin_lock_bh(&bat_priv->tt_roam_list_lock); | 1875 | spin_lock_bh(&bat_priv->tt_roam_list_lock); |
1877 | list_for_each_entry_safe(node, safe, &bat_priv->tt_roam_list, list) { | 1876 | list_for_each_entry_safe(node, safe, &bat_priv->tt_roam_list, list) { |
1878 | if (!has_timed_out(node->first_time, ROAMING_MAX_TIME)) | 1877 | if (!batadv_has_timed_out(node->first_time, ROAMING_MAX_TIME)) |
1879 | continue; | 1878 | continue; |
1880 | 1879 | ||
1881 | list_del(&node->list); | 1880 | list_del(&node->list); |
@@ -1901,10 +1900,11 @@ static bool tt_check_roam_count(struct bat_priv *bat_priv, | |||
1901 | * reply from the same orig_node yet | 1900 | * reply from the same orig_node yet |
1902 | */ | 1901 | */ |
1903 | list_for_each_entry(tt_roam_node, &bat_priv->tt_roam_list, list) { | 1902 | list_for_each_entry(tt_roam_node, &bat_priv->tt_roam_list, list) { |
1904 | if (!compare_eth(tt_roam_node->addr, client)) | 1903 | if (!batadv_compare_eth(tt_roam_node->addr, client)) |
1905 | continue; | 1904 | continue; |
1906 | 1905 | ||
1907 | if (has_timed_out(tt_roam_node->first_time, ROAMING_MAX_TIME)) | 1906 | if (batadv_has_timed_out(tt_roam_node->first_time, |
1907 | ROAMING_MAX_TIME)) | ||
1908 | continue; | 1908 | continue; |
1909 | 1909 | ||
1910 | if (!atomic_dec_not_zero(&tt_roam_node->counter)) | 1910 | if (!atomic_dec_not_zero(&tt_roam_node->counter)) |
@@ -1971,9 +1971,9 @@ static void send_roam_adv(struct bat_priv *bat_priv, uint8_t *client, | |||
1971 | if (!neigh_node) | 1971 | if (!neigh_node) |
1972 | goto out; | 1972 | goto out; |
1973 | 1973 | ||
1974 | bat_dbg(DBG_TT, bat_priv, | 1974 | batadv_dbg(DBG_TT, bat_priv, |
1975 | "Sending ROAMING_ADV to %pM (client %pM) via %pM\n", | 1975 | "Sending ROAMING_ADV to %pM (client %pM) via %pM\n", |
1976 | orig_node->orig, client, neigh_node->addr); | 1976 | orig_node->orig, client, neigh_node->addr); |
1977 | 1977 | ||
1978 | batadv_inc_counter(bat_priv, BAT_CNT_TT_ROAM_ADV_TX); | 1978 | batadv_inc_counter(bat_priv, BAT_CNT_TT_ROAM_ADV_TX); |
1979 | 1979 | ||
@@ -2078,9 +2078,9 @@ static void tt_local_purge_pending_clients(struct bat_priv *bat_priv) | |||
2078 | if (!(tt_common_entry->flags & TT_CLIENT_PENDING)) | 2078 | if (!(tt_common_entry->flags & TT_CLIENT_PENDING)) |
2079 | continue; | 2079 | continue; |
2080 | 2080 | ||
2081 | bat_dbg(DBG_TT, bat_priv, | 2081 | batadv_dbg(DBG_TT, bat_priv, |
2082 | "Deleting local tt entry (%pM): pending\n", | 2082 | "Deleting local tt entry (%pM): pending\n", |
2083 | tt_common_entry->addr); | 2083 | tt_common_entry->addr); |
2084 | 2084 | ||
2085 | atomic_dec(&bat_priv->num_local_tt); | 2085 | atomic_dec(&bat_priv->num_local_tt); |
2086 | hlist_del_rcu(node); | 2086 | hlist_del_rcu(node); |
@@ -2113,8 +2113,9 @@ static int tt_commit_changes(struct bat_priv *bat_priv, | |||
2113 | 2113 | ||
2114 | /* Increment the TTVN only once per OGM interval */ | 2114 | /* Increment the TTVN only once per OGM interval */ |
2115 | atomic_inc(&bat_priv->ttvn); | 2115 | atomic_inc(&bat_priv->ttvn); |
2116 | bat_dbg(DBG_TT, bat_priv, "Local changes committed, updating to ttvn %u\n", | 2116 | batadv_dbg(DBG_TT, bat_priv, |
2117 | (uint8_t)atomic_read(&bat_priv->ttvn)); | 2117 | "Local changes committed, updating to ttvn %u\n", |
2118 | (uint8_t)atomic_read(&bat_priv->ttvn)); | ||
2118 | bat_priv->tt_poss_change = false; | 2119 | bat_priv->tt_poss_change = false; |
2119 | 2120 | ||
2120 | /* reset the sending counter */ | 2121 | /* reset the sending counter */ |
@@ -2235,10 +2236,10 @@ void batadv_tt_update_orig(struct bat_priv *bat_priv, | |||
2235 | if (!orig_node->tt_initialised || ttvn != orig_ttvn || | 2236 | if (!orig_node->tt_initialised || ttvn != orig_ttvn || |
2236 | orig_node->tt_crc != tt_crc) { | 2237 | orig_node->tt_crc != tt_crc) { |
2237 | request_table: | 2238 | request_table: |
2238 | bat_dbg(DBG_TT, bat_priv, | 2239 | batadv_dbg(DBG_TT, bat_priv, |
2239 | "TT inconsistency for %pM. Need to retrieve the correct information (ttvn: %u last_ttvn: %u crc: %u last_crc: %u num_changes: %u)\n", | 2240 | "TT inconsistency for %pM. Need to retrieve the correct information (ttvn: %u last_ttvn: %u crc: %u last_crc: %u num_changes: %u)\n", |
2240 | orig_node->orig, ttvn, orig_ttvn, tt_crc, | 2241 | orig_node->orig, ttvn, orig_ttvn, tt_crc, |
2241 | orig_node->tt_crc, tt_num_changes); | 2242 | orig_node->tt_crc, tt_num_changes); |
2242 | send_tt_request(bat_priv, orig_node, ttvn, tt_crc, | 2243 | send_tt_request(bat_priv, orig_node, ttvn, tt_crc, |
2243 | full_table); | 2244 | full_table); |
2244 | return; | 2245 | return; |