]> git.baikalelectronics.ru Git - kernel.git/commitdiff
batman-adv: don't compile the BLA switch if not requested
authorAntonio Quartulli <ordex@autistici.org>
Mon, 26 Nov 2012 00:27:29 +0000 (01:27 +0100)
committerAntonio Quartulli <ordex@autistici.org>
Sat, 12 Jan 2013 10:58:22 +0000 (20:58 +1000)
When the Bridge Loop Avoidance component is not compiled-in, its boolean switch
should be not compiled as well. This patch surrounds the switch with a proper
ifdef.

This behaviour was introduced by 9fd6b0615b5499b270d39a92b8790e206cf75833
("batman-adv: add bridge loop avoidance compile option")

Signed-off-by: Antonio Quartulli <ordex@autistici.org>
Acked-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de>
Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
net/batman-adv/soft-interface.c
net/batman-adv/types.h

index f8cc1429942fad671a3cdba36016f8c76422eca6..57714f83ede4231a7e9826a1978644f37348a694 100644 (file)
@@ -480,7 +480,9 @@ struct net_device *batadv_softif_create(const char *name)
 
        atomic_set(&bat_priv->aggregated_ogms, 1);
        atomic_set(&bat_priv->bonding, 0);
+#ifdef CONFIG_BATMAN_ADV_BLA
        atomic_set(&bat_priv->bridge_loop_avoidance, 0);
+#endif
 #ifdef CONFIG_BATMAN_ADV_DAT
        atomic_set(&bat_priv->distributed_arp_table, 1);
 #endif
index ae9ac9aca8c53d5ffd93b015cb6ff779f55c86fe..030ce412227eb5601e0e7d9a3e58feb8cecbc932 100644 (file)
@@ -273,7 +273,9 @@ struct batadv_priv {
        atomic_t bonding;               /* boolean */
        atomic_t fragmentation;         /* boolean */
        atomic_t ap_isolation;          /* boolean */
+#ifdef CONFIG_BATMAN_ADV_BLA
        atomic_t bridge_loop_avoidance; /* boolean */
+#endif
 #ifdef CONFIG_BATMAN_ADV_DAT
        atomic_t distributed_arp_table; /* boolean */
 #endif