aboutsummaryrefslogtreecommitdiffstats
path: root/net/batman-adv/bridge_loop_avoidance.c
diff options
context:
space:
mode:
authorSven Eckelmann <sven@narfation.org>2012-05-12 07:38:47 -0400
committerAntonio Quartulli <ordex@autistici.org>2012-06-20 16:15:17 -0400
commit08adf1512298201a53b88bb0a3d67e0dbbe0ed9b (patch)
treec0300fbf9717978726becbbdf14f1332178e78cd /net/batman-adv/bridge_loop_avoidance.c
parent0f5f9322681887ca221707afafe4216b6db5d22f (diff)
batman-adv: Prefix bridge_loop_avoidance non-static functions with batadv_
batman-adv can be compiled as part of the kernel instead of an module. In that case the linker will see all non-static symbols of batman-adv and all other non-static symbols of the kernel. This could lead to symbol collisions. A prefix for the batman-adv symbols that defines their private namespace avoids such a problem. Reported-by: David Miller <davem@davemloft.net> Signed-off-by: Sven Eckelmann <sven@narfation.org>
Diffstat (limited to 'net/batman-adv/bridge_loop_avoidance.c')
-rw-r--r--net/batman-adv/bridge_loop_avoidance.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/net/batman-adv/bridge_loop_avoidance.c b/net/batman-adv/bridge_loop_avoidance.c
index 314e37b272a7..b0561e338ae5 100644
--- a/net/batman-adv/bridge_loop_avoidance.c
+++ b/net/batman-adv/bridge_loop_avoidance.c
@@ -1019,9 +1019,9 @@ purge_now:
1019 * Update the backbone gateways when the own orig address changes. 1019 * Update the backbone gateways when the own orig address changes.
1020 * 1020 *
1021 */ 1021 */
1022void bla_update_orig_address(struct bat_priv *bat_priv, 1022void batadv_bla_update_orig_address(struct bat_priv *bat_priv,
1023 struct hard_iface *primary_if, 1023 struct hard_iface *primary_if,
1024 struct hard_iface *oldif) 1024 struct hard_iface *oldif)
1025{ 1025{
1026 struct backbone_gw *backbone_gw; 1026 struct backbone_gw *backbone_gw;
1027 struct hlist_node *node; 1027 struct hlist_node *node;
@@ -1136,7 +1136,7 @@ static struct lock_class_key claim_hash_lock_class_key;
1136static struct lock_class_key backbone_hash_lock_class_key; 1136static struct lock_class_key backbone_hash_lock_class_key;
1137 1137
1138/* initialize all bla structures */ 1138/* initialize all bla structures */
1139int bla_init(struct bat_priv *bat_priv) 1139int batadv_bla_init(struct bat_priv *bat_priv)
1140{ 1140{
1141 int i; 1141 int i;
1142 uint8_t claim_dest[ETH_ALEN] = {0xff, 0x43, 0x05, 0x00, 0x00, 0x00}; 1142 uint8_t claim_dest[ETH_ALEN] = {0xff, 0x43, 0x05, 0x00, 0x00, 0x00};
@@ -1199,9 +1199,9 @@ int bla_init(struct bat_priv *bat_priv)
1199 * 1199 *
1200 **/ 1200 **/
1201 1201
1202int bla_check_bcast_duplist(struct bat_priv *bat_priv, 1202int batadv_bla_check_bcast_duplist(struct bat_priv *bat_priv,
1203 struct bcast_packet *bcast_packet, 1203 struct bcast_packet *bcast_packet,
1204 int hdr_size) 1204 int hdr_size)
1205{ 1205{
1206 int i, length, curr; 1206 int i, length, curr;
1207 uint8_t *content; 1207 uint8_t *content;
@@ -1260,7 +1260,7 @@ int bla_check_bcast_duplist(struct bat_priv *bat_priv,
1260 * 1260 *
1261 */ 1261 */
1262 1262
1263int bla_is_backbone_gw_orig(struct bat_priv *bat_priv, uint8_t *orig) 1263int batadv_bla_is_backbone_gw_orig(struct bat_priv *bat_priv, uint8_t *orig)
1264{ 1264{
1265 struct hashtable_t *hash = bat_priv->backbone_hash; 1265 struct hashtable_t *hash = bat_priv->backbone_hash;
1266 struct hlist_head *head; 1266 struct hlist_head *head;
@@ -1301,8 +1301,8 @@ int bla_is_backbone_gw_orig(struct bat_priv *bat_priv, uint8_t *orig)
1301 * returns 0. 1301 * returns 0.
1302 * 1302 *
1303 */ 1303 */
1304int bla_is_backbone_gw(struct sk_buff *skb, 1304int batadv_bla_is_backbone_gw(struct sk_buff *skb,
1305 struct orig_node *orig_node, int hdr_size) 1305 struct orig_node *orig_node, int hdr_size)
1306{ 1306{
1307 struct ethhdr *ethhdr; 1307 struct ethhdr *ethhdr;
1308 struct vlan_ethhdr *vhdr; 1308 struct vlan_ethhdr *vhdr;
@@ -1339,7 +1339,7 @@ int bla_is_backbone_gw(struct sk_buff *skb,
1339} 1339}
1340 1340
1341/* free all bla structures (for softinterface free or module unload) */ 1341/* free all bla structures (for softinterface free or module unload) */
1342void bla_free(struct bat_priv *bat_priv) 1342void batadv_bla_free(struct bat_priv *bat_priv)
1343{ 1343{
1344 struct hard_iface *primary_if; 1344 struct hard_iface *primary_if;
1345 1345
@@ -1374,7 +1374,7 @@ void bla_free(struct bat_priv *bat_priv)
1374 * process the skb. 1374 * process the skb.
1375 * 1375 *
1376 */ 1376 */
1377int bla_rx(struct bat_priv *bat_priv, struct sk_buff *skb, short vid) 1377int batadv_bla_rx(struct bat_priv *bat_priv, struct sk_buff *skb, short vid)
1378{ 1378{
1379 struct ethhdr *ethhdr; 1379 struct ethhdr *ethhdr;
1380 struct claim search_claim, *claim = NULL; 1380 struct claim search_claim, *claim = NULL;
@@ -1463,7 +1463,7 @@ out:
1463 * process the skb. 1463 * process the skb.
1464 * 1464 *
1465 */ 1465 */
1466int bla_tx(struct bat_priv *bat_priv, struct sk_buff *skb, short vid) 1466int batadv_bla_tx(struct bat_priv *bat_priv, struct sk_buff *skb, short vid)
1467{ 1467{
1468 struct ethhdr *ethhdr; 1468 struct ethhdr *ethhdr;
1469 struct claim search_claim, *claim = NULL; 1469 struct claim search_claim, *claim = NULL;
@@ -1537,7 +1537,7 @@ out:
1537 return ret; 1537 return ret;
1538} 1538}
1539 1539
1540int bla_claim_table_seq_print_text(struct seq_file *seq, void *offset) 1540int batadv_bla_claim_table_seq_print_text(struct seq_file *seq, void *offset)
1541{ 1541{
1542 struct net_device *net_dev = (struct net_device *)seq->private; 1542 struct net_device *net_dev = (struct net_device *)seq->private;
1543 struct bat_priv *bat_priv = netdev_priv(net_dev); 1543 struct bat_priv *bat_priv = netdev_priv(net_dev);