aboutsummaryrefslogtreecommitdiff
path: root/net/batman-adv/hard-interface.h
AgeCommit message (Collapse)Author
2013-03-27batman-adv: Don't always delete softif when last slave was removedSven Eckelmann
batman-adv has an unusual way to manage softinterfaces. These will be created automatically when a user writes to the batman-adv/mesh_iface file in sysfs and removed when no slave device exists anymore. This behaviour cannot be changed without breaking compatibility with existing code. Instead other interfaces should be able to slightly reduce this behaviour and provide a more common reaction to a removal of a slave interface. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <lindner_marek@yahoo.de> Acked-by: Antonio Quartulli <ordex@autistici.org> Signed-off-by: Antonio Quartulli <ordex@autistici.org>
2013-01-19batman-adv: update copyright yearsAntonio Quartulli
Signed-off-by: Antonio Quartulli <ordex@autistici.org> Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
2012-07-01batman-adv: Prefix types structs with batadv_Sven Eckelmann
Reported-by: Martin Hundebøll <martin@hundeboll.net> Signed-off-by: Sven Eckelmann <sven@narfation.org>
2012-07-01batman-adv: Prefix hard-interface enum with BATADV_Sven Eckelmann
Reported-by: Martin Hundebøll <martin@hundeboll.net> Signed-off-by: Sven Eckelmann <sven@narfation.org>
2012-06-24batman-adv: Prefix hard-interface static inline functions with batadv_Sven Eckelmann
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>
2012-06-20batman-adv: Reformat multiline comments to consistent styleSven Eckelmann
batman-adv doesn't follow the style for multiline comments that David S. Miller prefers. All comments should be reformatted to follow this consistent style to make the code slightly more readable. Signed-off-by: Sven Eckelmann <sven@narfation.org>
2012-06-20batman-adv: Prefix hard-interface non-static functions with batadv_Sven Eckelmann
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>
2012-02-17batman-adv: Update copyright yearsSven Eckelmann
Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
2011-08-22batman-adv: detect clients connected through a 802.11 deviceAntonio Quartulli
Clients connected through a 802.11 device are now marked with the TT_CLIENT_WIFI flag. This flag is also advertised with the tt announcement. Signed-off-by: Antonio Quartulli <ordex@autistici.org> Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
2011-06-09batman-adv: Use enums for related constantsSven Eckelmann
CodingStyle "Chapter 12: Macros, Enums and RTL" recommends to use enums for several related constants. Internal states can be used without defining the actual value, but all values which are visible to the outside must be defined as before. Normal values are assigned as usual and flags are defined by shifts of a bit. Signed-off-by: Sven Eckelmann <sven@narfation.org>
2011-05-30batman-adv: Add const type qualifier for pointersSven Eckelmann
batman-adv uses pointers which are marked as const and should not violate that type qualifier by passing it to functions which force a cast to the non-const version. Signed-off-by: Sven Eckelmann <sven@narfation.org>
2011-05-01batman-adv: Make bat_priv->primary_if an rcu protected pointerMarek Lindner
The rcu protected macros rcu_dereference() and rcu_assign_pointer() for the bat_priv->primary_if need to be used, as well as spin/rcu locking. Otherwise we might end up using a primary_if pointer pointing to already freed memory. Signed-off-by: Marek Lindner <lindner_marek@yahoo.de> Signed-off-by: Sven Eckelmann <sven@narfation.org>
2011-03-05batman-adv: rename batman_if struct to hard_ifaceMarek Lindner
Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
2011-03-05batman-adv: Correct rcu refcounting for batman_ifMarek Lindner
It might be possible that 2 threads access the same data in the same rcu grace period. The first thread calls call_rcu() to decrement the refcount and free the data while the second thread increases the refcount to use the data. To avoid this race condition all refcount operations have to be atomic. Reported-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
2011-01-31batman-adv: Update copyright yearsSven Eckelmann
Signed-off-by: Sven Eckelmann <sven@narfation.org>
2011-01-31batman-adv: Remove declaration of batman_skb_recvSven Eckelmann
batman_skb_recv can be defined in hard-interface.c as static because it is never used outside of that file. Signed-off-by: Sven Eckelmann <sven@narfation.org>
2010-12-16net: Add batman-adv meshing protocolSven Eckelmann
B.A.T.M.A.N. (better approach to mobile ad-hoc networking) is a routing protocol for multi-hop ad-hoc mesh networks. The networks may be wired or wireless. See http://www.open-mesh.org/ for more information and user space tools. Signed-off-by: Sven Eckelmann <sven@narfation.org> Signed-off-by: David S. Miller <davem@davemloft.net>