All of lore.kernel.org
 help / color / mirror / Atom feed
* [B.A.T.M.A.N.] [PATCHv4 next 01/11] batman-adv: remove useless goto
@ 2014-03-19 17:55 Antonio Quartulli
  2014-03-19 17:55 ` [B.A.T.M.A.N.] [PATCHv4 next 02/11] batman-adv: don't mess up with the netdev refcounting if not needed Antonio Quartulli
                   ` (4 more replies)
  0 siblings, 5 replies; 22+ messages in thread
From: Antonio Quartulli @ 2014-03-19 17:55 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

There is no need to use a label and a goto for code that is
used once only.
Moreover having a goto for a single return statement should
always be avoided.

Introduced by e368857f66620b8483166e8e6556d9c87f9b3e71
("batman-adv: Multicast Listener Announcements via Translation Table")

Cc: Linus Lüssing <linus.luessing@web.de>
Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
---

Changes from v3:
- simply has_bridge() function even more

Changes from v2:
- added compat code change to 2/11 to accommodate new use of
  netdev_master_upper_dev_get_rcu()

Changes from v1:
- change "we are out of memory" to "in case of memory allocation failure" in
  3/11
- fix commit message in 10/11


 multicast.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/multicast.c b/multicast.c
index 998b429..d92de1e 100644
--- a/multicast.c
+++ b/multicast.c
@@ -194,12 +194,10 @@ static bool batadv_mcast_has_bridge(struct batadv_priv *bat_priv)
 
 	bridge = batadv_mcast_get_bridge(bat_priv);
 	if (!bridge)
-		goto out;
+		return false;
 
 	dev_put(bridge);
 	return true;
-out:
-	return false;
 }
 
 /**
-- 
1.8.3.2


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [B.A.T.M.A.N.] [PATCHv4 next 02/11] batman-adv: don't mess up with the netdev refcounting if not needed
  2014-03-19 17:55 [B.A.T.M.A.N.] [PATCHv4 next 01/11] batman-adv: remove useless goto Antonio Quartulli
@ 2014-03-19 17:55 ` Antonio Quartulli
  2014-03-21  8:29   ` Marek Lindner
  2014-03-19 17:55 ` [B.A.T.M.A.N.] [PATCHv4 next 03/11] batman-adv: fix multicast kerneldoc Antonio Quartulli
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 22+ messages in thread
From: Antonio Quartulli @ 2014-03-19 17:55 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

Looking for an interface and increasing its refcounter only
to check if it really exists is not really useful and makes
the code look more complex without a real gain.

Change batadv_mcast_has_bridge() accordingly and avoid to
use the pointer to the interface outside of the
rcu_read_lock/unlock context.

Introduced by e368857f66620b8483166e8e6556d9c87f9b3e71
("batman-adv: Multicast Listener Announcements via Translation Table")

Cc: Linus Lüssing <linus.luessing@web.de>
Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
---
 compat.h    | 19 ++++---------------
 multicast.c | 33 ++++-----------------------------
 2 files changed, 8 insertions(+), 44 deletions(-)

diff --git a/compat.h b/compat.h
index e14c6bb..5eb5fe6 100644
--- a/compat.h
+++ b/compat.h
@@ -164,14 +164,8 @@ static inline int batadv_param_set_copystring(const char *val,
 #define NET_ADDR_RANDOM 0
 
 #define netdev_master_upper_dev_get_rcu(dev) \
-	upper; \
-	if (dev->br_port ? 1 : 0) { \
-		rcu_read_unlock(); \
-		dev_hold(dev); \
-		return dev; \
-	} else {\
-		dev = NULL; \
-	}
+	(dev->br_port ? dev : NULL); \
+	break;
 
 #endif /* < KERNEL_VERSION(2, 6, 36) */
 
@@ -375,13 +369,8 @@ static int __batadv_interface_tx(struct sk_buff *skb, \
 
 #ifndef netdev_master_upper_dev_get_rcu
 #define netdev_master_upper_dev_get_rcu(dev) \
-	upper; \
-	if (dev->priv_flags & IFF_BRIDGE_PORT) { \
-		rcu_read_unlock(); \
-		dev_hold(dev); \
-		return dev; \
-	} else \
-		dev = NULL;
+	(dev->priv_flags & IFF_BRIDGE_PORT ? dev : NULL); \
+	break;
 
 #endif /* netdev_master_upper_dev_get_rcu */
 
diff --git a/multicast.c b/multicast.c
index d92de1e..edce295 100644
--- a/multicast.c
+++ b/multicast.c
@@ -156,51 +156,26 @@ static void batadv_mcast_mla_tt_add(struct batadv_priv *bat_priv,
 }
 
 /**
- * batadv_mcast_get_bridge - get the bridge interface on our soft interface
+ * batadv_mcast_has_bridge - check whether the soft-iface is bridged
  * @bat_priv: the bat priv with all the soft interface information
  *
- * Return the next bridge interface on top of our soft interface and increase
- * its refcount. If no such bridge interface exists, then return NULL.
+ * Check whether there is a bridge on top of our soft interface. Return
+ * true if so, false otherwise.
  */
-static struct net_device *
-batadv_mcast_get_bridge(struct batadv_priv *bat_priv)
+static bool batadv_mcast_has_bridge(struct batadv_priv *bat_priv)
 {
 	struct net_device *upper = bat_priv->soft_iface;
 
 	rcu_read_lock();
-
 	do {
 		upper = netdev_master_upper_dev_get_rcu(upper);
 	} while (upper && !(upper->priv_flags & IFF_EBRIDGE));
-
-	if (upper)
-		dev_hold(upper);
-
 	rcu_read_unlock();
 
 	return upper;
 }
 
 /**
- * batadv_mcast_has_bridge - check whether the soft-iface is bridged
- * @bat_priv: the bat priv with all the soft interface information
- *
- * Check whether there is a bridge on top of our soft interface. Return
- * true if so, false otherwise.
- */
-static bool batadv_mcast_has_bridge(struct batadv_priv *bat_priv)
-{
-	struct net_device *bridge;
-
-	bridge = batadv_mcast_get_bridge(bat_priv);
-	if (!bridge)
-		return false;
-
-	dev_put(bridge);
-	return true;
-}
-
-/**
  * batadv_mcast_mla_tvlv_update - update multicast tvlv
  * @bat_priv: the bat priv with all the soft interface information
  *
-- 
1.8.3.2


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [B.A.T.M.A.N.] [PATCHv4 next 03/11] batman-adv: fix multicast kerneldoc
  2014-03-19 17:55 [B.A.T.M.A.N.] [PATCHv4 next 01/11] batman-adv: remove useless goto Antonio Quartulli
  2014-03-19 17:55 ` [B.A.T.M.A.N.] [PATCHv4 next 02/11] batman-adv: don't mess up with the netdev refcounting if not needed Antonio Quartulli
@ 2014-03-19 17:55 ` Antonio Quartulli
  2014-03-21  8:30   ` Marek Lindner
  2014-03-19 17:55 ` [B.A.T.M.A.N.] [PATCHv4 next 04/11] " Antonio Quartulli
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 22+ messages in thread
From: Antonio Quartulli @ 2014-03-19 17:55 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

The kerneldoc should always use the third person singular in
the long function description.
Moreover it should always try use up to 80 chars per line.

Introduced by 86cb16e5ec1e2d75821006e8f4abbec66fb741ac
("batman-adv: Add IPv4 link-local/IPv6-ll-all-nodes multicast support")

Cc: Linus Lüssing <linus.luessing@web.de>
Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
---
 multicast.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/multicast.c b/multicast.c
index edce295..e2ad525 100644
--- a/multicast.c
+++ b/multicast.c
@@ -250,11 +250,11 @@ out:
  * @skb: the IPv4 packet to check
  * @is_unsnoopable: stores whether the destination is snoopable
  *
- * Check whether the given IPv4 packet has the potential to
- * be forwarded with a mode more optimal than classic flooding.
+ * Checks whether the given IPv4 packet has the potential to be forwarded with a
+ * mode more optimal than classic flooding.
  *
- * If so then return 0. Otherwise -EINVAL is returned or -ENOMEM if we are
- * out of memory.
+ * If so then returns 0. Otherwise -EINVAL is returned or -ENOMEM in case of
+ * memory allocation failure.
  */
 static int batadv_mcast_forw_mode_check_ipv4(struct batadv_priv *bat_priv,
 					     struct sk_buff *skb,
@@ -479,8 +479,8 @@ batadv_mcast_forw_ip_node_get(struct batadv_priv *bat_priv,
  * batadv_mcast_want_forw_unsnoop_node_get - get a node with an unsnoopable flag
  * @bat_priv: the bat priv with all the soft interface information
  *
- * Return an orig_node which has the BATADV_MCAST_WANT_ALL_UNSNOOPABLES flag set
- * and increase its refcount.
+ * Returns an orig_node which has the BATADV_MCAST_WANT_ALL_UNSNOOPABLES flag
+ * set and increases its refcount.
  */
 static struct batadv_orig_node *
 batadv_mcast_forw_unsnoop_node_get(struct batadv_priv *bat_priv)
-- 
1.8.3.2


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [B.A.T.M.A.N.] [PATCHv4 next 04/11] batman-adv: fix multicast kerneldoc
  2014-03-19 17:55 [B.A.T.M.A.N.] [PATCHv4 next 01/11] batman-adv: remove useless goto Antonio Quartulli
  2014-03-19 17:55 ` [B.A.T.M.A.N.] [PATCHv4 next 02/11] batman-adv: don't mess up with the netdev refcounting if not needed Antonio Quartulli
  2014-03-19 17:55 ` [B.A.T.M.A.N.] [PATCHv4 next 03/11] batman-adv: fix multicast kerneldoc Antonio Quartulli
@ 2014-03-19 17:55 ` Antonio Quartulli
  2014-03-21  8:31   ` Marek Lindner
  2014-03-19 17:57 ` [B.A.T.M.A.N.] [PATCHv4 next 05/11] " Antonio Quartulli
  2014-03-21  8:27 ` [B.A.T.M.A.N.] [PATCHv4 next 01/11] batman-adv: remove useless goto Marek Lindner
  4 siblings, 1 reply; 22+ messages in thread
From: Antonio Quartulli @ 2014-03-19 17:55 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

The kerneldoc should always use the third person singular in
the long function description.
Moreover it should always try use up to 80 chars per line.

Introduced by commit 01d665e054254618353ec8d9ea43d1a138de6e6d
("batman-adv: Multicast Listener Announcements via Translation Table")

Cc: Linus Lüssing <linus.luessing@web.de>
Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
---
 multicast.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/multicast.c b/multicast.c
index e2ad525..ae2cb48 100644
--- a/multicast.c
+++ b/multicast.c
@@ -27,7 +27,7 @@
  * Collect multicast addresses of the local multicast listeners
  * on the given soft interface, dev, in the given mcast_list.
  *
- * Return -ENOMEM on memory allocation error or the number of
+ * Returns -ENOMEM on memory allocation error or the number of
  * items added to the mcast_list otherwise.
  */
 static int batadv_mcast_mla_softif_get(struct net_device *dev,
@@ -59,7 +59,7 @@ static int batadv_mcast_mla_softif_get(struct net_device *dev,
  * @mcast_addr: the multicast address to check
  * @mcast_list: the list with multicast addresses to search in
  *
- * Return true if the given address is already in the given list.
+ * Returns true if the given address is already in the given list.
  * Otherwise returns false.
  */
 static bool batadv_mcast_mla_is_duplicate(uint8_t *mcast_addr,
@@ -78,7 +78,7 @@ static bool batadv_mcast_mla_is_duplicate(uint8_t *mcast_addr,
  * batadv_mcast_mla_list_free - free a list of multicast addresses
  * @mcast_list: the list to free
  *
- * Remove and free all items in the given mcast_list.
+ * Removes and frees all items in the given mcast_list.
  */
 static void batadv_mcast_mla_list_free(struct hlist_head *mcast_list)
 {
@@ -96,7 +96,7 @@ static void batadv_mcast_mla_list_free(struct hlist_head *mcast_list)
  * @bat_priv: the bat priv with all the soft interface information
  * @mcast_list: a list of addresses which should _not_ be removed
  *
- * Retract the announcement of any multicast listener from the
+ * Retracts the announcement of any multicast listener from the
  * translation table except the ones listed in the given mcast_list.
  *
  * If mcast_list is NULL then all are retracted.
@@ -128,7 +128,7 @@ static void batadv_mcast_mla_tt_retract(struct batadv_priv *bat_priv,
  * @bat_priv: the bat priv with all the soft interface information
  * @mcast_list: a list of addresses which are going to get added
  *
- * Add multicast listener announcements from the given mcast_list to the
+ * Adds multicast listener announcements from the given mcast_list to the
  * translation table if they have not been added yet.
  */
 static void batadv_mcast_mla_tt_add(struct batadv_priv *bat_priv,
@@ -159,7 +159,7 @@ static void batadv_mcast_mla_tt_add(struct batadv_priv *bat_priv,
  * batadv_mcast_has_bridge - check whether the soft-iface is bridged
  * @bat_priv: the bat priv with all the soft interface information
  *
- * Check whether there is a bridge on top of our soft interface. Return
+ * Checks whether there is a bridge on top of our soft interface. Returns
  * true if so, false otherwise.
  */
 static bool batadv_mcast_has_bridge(struct batadv_priv *bat_priv)
-- 
1.8.3.2


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [B.A.T.M.A.N.] [PATCHv4 next 05/11] batman-adv: fix multicast kerneldoc
  2014-03-19 17:55 [B.A.T.M.A.N.] [PATCHv4 next 01/11] batman-adv: remove useless goto Antonio Quartulli
                   ` (2 preceding siblings ...)
  2014-03-19 17:55 ` [B.A.T.M.A.N.] [PATCHv4 next 04/11] " Antonio Quartulli
@ 2014-03-19 17:57 ` Antonio Quartulli
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 06/11] " Antonio Quartulli
                     ` (6 more replies)
  2014-03-21  8:27 ` [B.A.T.M.A.N.] [PATCHv4 next 01/11] batman-adv: remove useless goto Marek Lindner
  4 siblings, 7 replies; 22+ messages in thread
From: Antonio Quartulli @ 2014-03-19 17:57 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

The kerneldoc should always use the third person singular in
the long function description.
Moreover it should always try use up to 80 chars per line.

Introduced by f70c60d236cddb28d9e576de774ad97f9b0fd1b7
("batman-adv: Announce new capability via multicast TVLV")

Cc: Linus Lüssing <linus.luessing@web.de>
Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
---
 multicast.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/multicast.c b/multicast.c
index ae2cb48..5bc0703 100644
--- a/multicast.c
+++ b/multicast.c
@@ -179,11 +179,11 @@ static bool batadv_mcast_has_bridge(struct batadv_priv *bat_priv)
  * batadv_mcast_mla_tvlv_update - update multicast tvlv
  * @bat_priv: the bat priv with all the soft interface information
  *
- * Update the own multicast tvlv with our current multicast related settings,
+ * Updates the own multicast tvlv with our current multicast related settings,
  * capabilities and inabilities.
  *
- * Return true if the tvlv container is registered afterwards. Otherwise return
- * false.
+ * Returns true if the tvlv container is registered afterwards. Otherwise
+ * returns false.
  */
 static bool batadv_mcast_mla_tvlv_update(struct batadv_priv *bat_priv)
 {
@@ -220,7 +220,7 @@ static bool batadv_mcast_mla_tvlv_update(struct batadv_priv *bat_priv)
  * batadv_mcast_mla_update - update the own MLAs
  * @bat_priv: the bat priv with all the soft interface information
  *
- * Update the own multicast listener announcements in the translation
+ * Updates the own multicast listener announcements in the translation
  * table as well as the own, announced multicast tvlv container.
  */
 void batadv_mcast_mla_update(struct batadv_priv *bat_priv)
-- 
1.8.3.2


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [B.A.T.M.A.N.] [PATCHv4 next 06/11] batman-adv: fix multicast kerneldoc
  2014-03-19 17:57 ` [B.A.T.M.A.N.] [PATCHv4 next 05/11] " Antonio Quartulli
@ 2014-03-19 17:57   ` Antonio Quartulli
  2014-03-21  8:33     ` Marek Lindner
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 07/11] " Antonio Quartulli
                     ` (5 subsequent siblings)
  6 siblings, 1 reply; 22+ messages in thread
From: Antonio Quartulli @ 2014-03-19 17:57 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

The kerneldoc should always use the third person singular in
the long function description.
Moreover it should always try use up to 80 chars per line.

Introduced by 90ad6a40c80323805be1e86504385de2bd861f0a
("batman-adv: Modified forwarding behaviour for multicast packets")

Cc: Linus Lüssing <linus.luessing@web.de>
Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
---
 multicast.c | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/multicast.c b/multicast.c
index 5bc0703..25b2632 100644
--- a/multicast.c
+++ b/multicast.c
@@ -288,11 +288,11 @@ static int batadv_mcast_forw_mode_check_ipv4(struct batadv_priv *bat_priv,
  * @skb: the IPv6 packet to check
  * @is_unsnoopable: stores whether the destination is snoopable
  *
- * Check whether the given IPv6 packet has the potential to
- * be forwarded with a mode more optimal than classic flooding.
+ * Checks whether the given IPv6 packet has the potential to be forwarded with a
+ * mode more optimal than classic flooding.
  *
- * If so then return 0. Otherwise -EINVAL is returned or -ENOMEM if we are
- * out of memory.
+ * If so then returns 0. Otherwise -EINVAL is returned or -ENOMEM if we are out
+ * of memory.
  */
 static int batadv_mcast_forw_mode_check_ipv6(struct batadv_priv *bat_priv,
 					     struct sk_buff *skb,
@@ -328,11 +328,11 @@ static int batadv_mcast_forw_mode_check_ipv6(struct batadv_priv *bat_priv,
  * @skb: the multicast frame to check
  * @is_unsnoopable: stores whether the destination is snoopable
  *
- * Check whether the given multicast ethernet frame has the potential to
- * be forwarded with a mode more optimal than classic flooding.
+ * Checks whether the given multicast ethernet frame has the potential to be
+ * forwarded with a mode more optimal than classic flooding.
  *
- * If so then return 0. Otherwise -EINVAL is returned or -ENOMEM if we are
- * out of memory.
+ * If so then returns 0. Otherwise -EINVAL is returned or -ENOMEM if we are out
+ * of memory.
  */
 static int batadv_mcast_forw_mode_check(struct batadv_priv *bat_priv,
 					struct sk_buff *skb,
@@ -386,7 +386,7 @@ static int batadv_mcast_forw_want_all_ip_count(struct batadv_priv *bat_priv,
  * @bat_priv: the bat priv with all the soft interface information
  * @ethhdr: the ether header containing the multicast destination
  *
- * Return an orig_node matching the multicast address provided by ethhdr
+ * Returns an orig_node matching the multicast address provided by ethhdr
  * via a translation table lookup. This increases the returned nodes refcount.
  */
 static struct batadv_orig_node *
@@ -508,7 +508,7 @@ unlock:
  * @skb: The multicast packet to check
  * @orig: an originator to be set to forward the skb to
  *
- * Return the forwarding mode as enum batadv_forw_mode and in case of
+ * Returns the forwarding mode as enum batadv_forw_mode and in case of
  * BATADV_FORW_SINGLE set the orig to the single originator the skb
  * should be forwarded to.
  */
-- 
1.8.3.2


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [B.A.T.M.A.N.] [PATCHv4 next 07/11] batman-adv: fix multicast kerneldoc
  2014-03-19 17:57 ` [B.A.T.M.A.N.] [PATCHv4 next 05/11] " Antonio Quartulli
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 06/11] " Antonio Quartulli
@ 2014-03-19 17:57   ` Antonio Quartulli
  2014-03-21  8:34     ` Marek Lindner
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 08/11] batman-adv: adjust copyright disclaimer in multicast files Antonio Quartulli
                     ` (4 subsequent siblings)
  6 siblings, 1 reply; 22+ messages in thread
From: Antonio Quartulli @ 2014-03-19 17:57 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

The kerneldoc should always use the third person singular in
the long function description.
Moreover it should always try use up to 80 chars per line.

Introduced by f2ed1502191a37abb39e3e2c80cca07f0f3bb411
("batman-adv: Send multicast packets to nodes with a WANT_ALL flag")

Cc: Linus Lüssing <linus.luessing@web.de>
Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
---
 multicast.c | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/multicast.c b/multicast.c
index 25b2632..53d82e2 100644
--- a/multicast.c
+++ b/multicast.c
@@ -363,9 +363,9 @@ static int batadv_mcast_forw_mode_check(struct batadv_priv *bat_priv,
  * @bat_priv: the bat priv with all the soft interface information
  * @ethhdr: ethernet header of a packet
  *
- * Return the number of nodes which want all IPv4 multicast traffic if
- * the given ethhdr is from an IPv4 packet or the number of nodes which want
- * all IPv6 traffic if it matches an IPv6 packet.
+ * Returns the number of nodes which want all IPv4 multicast traffic if the
+ * given ethhdr is from an IPv4 packet or the number of nodes which want all
+ * IPv6 traffic if it matches an IPv6 packet.
  */
 static int batadv_mcast_forw_want_all_ip_count(struct batadv_priv *bat_priv,
 					       struct ethhdr *ethhdr)
@@ -401,8 +401,8 @@ batadv_mcast_forw_tt_node_get(struct batadv_priv *bat_priv,
  * batadv_mcast_want_forw_ipv4_node_get - get a node with an ipv4 flag
  * @bat_priv: the bat priv with all the soft interface information
  *
- * Return an orig_node which has the BATADV_MCAST_WANT_ALL_IPV4 flag set
- * and increase its refcount.
+ * Returns an orig_node which has the BATADV_MCAST_WANT_ALL_IPV4 flag set and
+ * increases its refcount.
  */
 static struct batadv_orig_node *
 batadv_mcast_forw_ipv4_node_get(struct batadv_priv *bat_priv)
@@ -428,8 +428,8 @@ unlock:
  * batadv_mcast_want_forw_ipv6_node_get - get a node with an ipv6 flag
  * @bat_priv: the bat priv with all the soft interface information
  *
- * Return an orig_node which has the BATADV_MCAST_WANT_ALL_IPV6 flag set
- * and increase its refcount.
+ * Returns an orig_node which has the BATADV_MCAST_WANT_ALL_IPV6 flag set
+ * and increases its refcount.
  */
 static struct batadv_orig_node *
 batadv_mcast_forw_ipv6_node_get(struct batadv_priv *bat_priv)
@@ -456,9 +456,9 @@ unlock:
  * @bat_priv: the bat priv with all the soft interface information
  * @ethhdr: an ethernet header to determine the protocol family from
  *
- * Return an orig_node which has the BATADV_MCAST_WANT_ALL_IPV4 or
- * BATADV_MCAST_WANT_ALL_IPV6 flag, depending on the provided ethhdr, set
- * and increase its refcount.
+ * Returns an orig_node which has the BATADV_MCAST_WANT_ALL_IPV4 or
+ * BATADV_MCAST_WANT_ALL_IPV6 flag, depending on the provided ethhdr, set and
+ * increases its refcount.
  */
 static struct batadv_orig_node *
 batadv_mcast_forw_ip_node_get(struct batadv_priv *bat_priv,
-- 
1.8.3.2


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [B.A.T.M.A.N.] [PATCHv4 next 08/11] batman-adv: adjust copyright disclaimer in multicast files
  2014-03-19 17:57 ` [B.A.T.M.A.N.] [PATCHv4 next 05/11] " Antonio Quartulli
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 06/11] " Antonio Quartulli
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 07/11] " Antonio Quartulli
@ 2014-03-19 17:57   ` Antonio Quartulli
  2014-03-21  8:35     ` Marek Lindner
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 09/11] batman-adv: fix code style Antonio Quartulli
                     ` (3 subsequent siblings)
  6 siblings, 1 reply; 22+ messages in thread
From: Antonio Quartulli @ 2014-03-19 17:57 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

The URL to the FSF address has to be always reported in the
copyright disclaimer.
This is the accepted style in the networking branch.

Introduced by e368857f66620b8483166e8e6556d9c87f9b3e71
("batman-adv: Multicast Listener Announcements via Translation Table")

Cc: Linus Lüssing <linus.luessing@web.de>
Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
---
 multicast.c | 3 +++
 multicast.h | 3 +++
 2 files changed, 6 insertions(+)

diff --git a/multicast.c b/multicast.c
index 53d82e2..9a9e7f4 100644
--- a/multicast.c
+++ b/multicast.c
@@ -10,6 +10,9 @@
  * WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, see <http://www.gnu.org/licenses/>.
  */
 
 #include "main.h"
diff --git a/multicast.h b/multicast.h
index a76bc3a..2861899 100644
--- a/multicast.h
+++ b/multicast.h
@@ -10,6 +10,9 @@
  * WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, see <http://www.gnu.org/licenses/>.
  */
 
 #ifndef _NET_BATMAN_ADV_MULTICAST_H_
-- 
1.8.3.2


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [B.A.T.M.A.N.] [PATCHv4 next 09/11] batman-adv: fix code style
  2014-03-19 17:57 ` [B.A.T.M.A.N.] [PATCHv4 next 05/11] " Antonio Quartulli
                     ` (2 preceding siblings ...)
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 08/11] batman-adv: adjust copyright disclaimer in multicast files Antonio Quartulli
@ 2014-03-19 17:57   ` Antonio Quartulli
  2014-03-21  8:37     ` Marek Lindner
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 10/11] batman-adv: fix more " Antonio Quartulli
                     ` (2 subsequent siblings)
  6 siblings, 1 reply; 22+ messages in thread
From: Antonio Quartulli @ 2014-03-19 17:57 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

- don't split lines if shorter than 80 chars
- don't use goto if there is no cleanup to perform

Introduced by 90ad6a40c80323805be1e86504385de2bd861f0a
("batman-adv: Modified forwarding behaviour for multicast packets")

Cc: Linux Lüssing <linus.luessing@web.de>
Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
---
 multicast.c         | 3 +--
 multicast.h         | 8 ++++----
 translation-table.c | 5 ++---
 3 files changed, 7 insertions(+), 9 deletions(-)

diff --git a/multicast.c b/multicast.c
index 9a9e7f4..d67d75d 100644
--- a/multicast.c
+++ b/multicast.c
@@ -312,8 +312,7 @@ static int batadv_mcast_forw_mode_check_ipv6(struct batadv_priv *bat_priv,
 	/* TODO: Implement Multicast Router Discovery (RFC4286),
 	 * then allow scope > link local, too
 	 */
-	if (IPV6_ADDR_MC_SCOPE(&ip6hdr->daddr) !=
-	    IPV6_ADDR_SCOPE_LINKLOCAL)
+	if (IPV6_ADDR_MC_SCOPE(&ip6hdr->daddr) != IPV6_ADDR_SCOPE_LINKLOCAL)
 		return -EINVAL;
 
 	/* link-local-all-nodes multicast listeners behind a bridge are
diff --git a/multicast.h b/multicast.h
index 2861899..73b5d45 100644
--- a/multicast.h
+++ b/multicast.h
@@ -20,10 +20,10 @@
 
 /**
  * batadv_forw_mode - the way a packet should be forwarded as
- * @BATADV_FORW_ALL: forward the packet to all nodes
- *  (currently via classic flooding)
- * @BATADV_FORW_SINGLE: forward the packet to a single node
- *  (currently via the BATMAN unicast routing protocol)
+ * @BATADV_FORW_ALL: forward the packet to all nodes (currently via classic
+ *  flooding)
+ * @BATADV_FORW_SINGLE: forward the packet to a single node (currently via the
+ *  BATMAN unicast routing protocol)
  * @BATADV_FORW_NONE: don't forward, drop it
  */
 enum batadv_forw_mode {
diff --git a/translation-table.c b/translation-table.c
index dab5c39..d636bde 100644
--- a/translation-table.c
+++ b/translation-table.c
@@ -206,16 +206,15 @@ int batadv_tt_global_hash_count(struct batadv_priv *bat_priv,
 				const uint8_t *addr, unsigned short vid)
 {
 	struct batadv_tt_global_entry *tt_global_entry;
-	int count = 0;
+	int count;
 
 	tt_global_entry = batadv_tt_global_hash_find(bat_priv, addr, vid);
 	if (!tt_global_entry)
-		goto out;
+		return 0;
 
 	count = atomic_read(&tt_global_entry->orig_list_count);
 	batadv_tt_global_entry_free_ref(tt_global_entry);
 
-out:
 	return count;
 }
 
-- 
1.8.3.2


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [B.A.T.M.A.N.] [PATCHv4 next 10/11] batman-adv: fix more code style
  2014-03-19 17:57 ` [B.A.T.M.A.N.] [PATCHv4 next 05/11] " Antonio Quartulli
                     ` (3 preceding siblings ...)
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 09/11] batman-adv: fix code style Antonio Quartulli
@ 2014-03-19 17:57   ` Antonio Quartulli
  2014-03-21  8:39     ` Marek Lindner
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 11/11] " Antonio Quartulli
  2014-03-21  8:32   ` [B.A.T.M.A.N.] [PATCHv4 next 05/11] batman-adv: fix multicast kerneldoc Marek Lindner
  6 siblings, 1 reply; 22+ messages in thread
From: Antonio Quartulli @ 2014-03-19 17:57 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

- keep variable declarations in descending line length order
- use common iteration style pattern when looking up an
  object

Introduced by 86cb16e5ec1e2d75821006e8f4abbec66fb741ac
("batman-adv: Add IPv4 link-local/IPv6-ll-all-nodes multicast support")

Cc: Linux Lüssing <linus.luessing@web.de>
Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
---
 multicast.c | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/multicast.c b/multicast.c
index d67d75d..dfe4cd6 100644
--- a/multicast.c
+++ b/multicast.c
@@ -487,20 +487,20 @@ batadv_mcast_forw_ip_node_get(struct batadv_priv *bat_priv,
 static struct batadv_orig_node *
 batadv_mcast_forw_unsnoop_node_get(struct batadv_priv *bat_priv)
 {
-	struct batadv_orig_node *orig_node;
+	struct batadv_orig_node *tmp_orig_node, *orig_node = NULL;
 
 	rcu_read_lock();
-	hlist_for_each_entry_rcu(orig_node,
+	hlist_for_each_entry_rcu(tmp_orig_node,
 				 &bat_priv->mcast.want_all_unsnoopables_list,
 				 mcast_want_all_unsnoopables_node) {
-		if (atomic_inc_not_zero(&orig_node->refcount))
-			goto unlock;
-	}
-
-	orig_node = NULL;
+		if (!atomic_inc_not_zero(&orig_node->refcount))
+			continue;
 
-unlock:
+		orig_node = tmp_orig_node;
+		break;
+	}
 	rcu_read_unlock();
+
 	return orig_node;
 }
 
@@ -518,9 +518,9 @@ enum batadv_forw_mode
 batadv_mcast_forw_mode(struct batadv_priv *bat_priv, struct sk_buff *skb,
 		       struct batadv_orig_node **orig)
 {
-	struct ethhdr *ethhdr;
-	bool is_unsnoopable = false;
 	int ret, tt_count, ip_count, unsnoop_count, total_count;
+	bool is_unsnoopable = false;
+	struct ethhdr *ethhdr;
 
 	ret = batadv_mcast_forw_mode_check(bat_priv, skb, &is_unsnoopable);
 	if (ret == -ENOMEM)
-- 
1.8.3.2


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [B.A.T.M.A.N.] [PATCHv4 next 11/11] batman-adv: fix more code style
  2014-03-19 17:57 ` [B.A.T.M.A.N.] [PATCHv4 next 05/11] " Antonio Quartulli
                     ` (4 preceding siblings ...)
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 10/11] batman-adv: fix more " Antonio Quartulli
@ 2014-03-19 17:57   ` Antonio Quartulli
  2014-03-21  8:40     ` Marek Lindner
  2014-03-21  8:32   ` [B.A.T.M.A.N.] [PATCHv4 next 05/11] batman-adv: fix multicast kerneldoc Marek Lindner
  6 siblings, 1 reply; 22+ messages in thread
From: Antonio Quartulli @ 2014-03-19 17:57 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

- use common iteration style pattern when looking up an
  object

Introduced by f2ed1502191a37abb39e3e2c80cca07f0f3bb411
("batman-adv: Send multicast packets to nodes with a WANT_ALL flag")

Cc: Linux Lüssing <linus.luessing@web.de>
Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
---
 multicast.c | 32 ++++++++++++++++----------------
 1 file changed, 16 insertions(+), 16 deletions(-)

diff --git a/multicast.c b/multicast.c
index dfe4cd6..8c7ca81 100644
--- a/multicast.c
+++ b/multicast.c
@@ -409,20 +409,20 @@ batadv_mcast_forw_tt_node_get(struct batadv_priv *bat_priv,
 static struct batadv_orig_node *
 batadv_mcast_forw_ipv4_node_get(struct batadv_priv *bat_priv)
 {
-	struct batadv_orig_node *orig_node;
+	struct batadv_orig_node *tmp_orig_node, *orig_node = NULL;
 
 	rcu_read_lock();
-	hlist_for_each_entry_rcu(orig_node,
+	hlist_for_each_entry_rcu(tmp_orig_node,
 				 &bat_priv->mcast.want_all_ipv4_list,
 				 mcast_want_all_ipv4_node) {
-		if (atomic_inc_not_zero(&orig_node->refcount))
-			goto unlock;
-	}
-
-	orig_node = NULL;
+		if (!atomic_inc_not_zero(&orig_node->refcount))
+			continue;
 
-unlock:
+		orig_node = tmp_orig_node;
+		break;
+	}
 	rcu_read_unlock();
+
 	return orig_node;
 }
 
@@ -436,20 +436,20 @@ unlock:
 static struct batadv_orig_node *
 batadv_mcast_forw_ipv6_node_get(struct batadv_priv *bat_priv)
 {
-	struct batadv_orig_node *orig_node;
+	struct batadv_orig_node *tmp_orig_node, *orig_node = NULL;
 
 	rcu_read_lock();
-	hlist_for_each_entry_rcu(orig_node,
+	hlist_for_each_entry_rcu(tmp_orig_node,
 				 &bat_priv->mcast.want_all_ipv6_list,
 				 mcast_want_all_ipv6_node) {
-		if (atomic_inc_not_zero(&orig_node->refcount))
-			goto unlock;
-	}
-
-	orig_node = NULL;
+		if (!atomic_inc_not_zero(&orig_node->refcount))
+			continue;
 
-unlock:
+		orig_node = tmp_orig_node;
+		break;
+	}
 	rcu_read_unlock();
+
 	return orig_node;
 }
 
-- 
1.8.3.2


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCHv4 next 01/11] batman-adv: remove useless goto
  2014-03-19 17:55 [B.A.T.M.A.N.] [PATCHv4 next 01/11] batman-adv: remove useless goto Antonio Quartulli
                   ` (3 preceding siblings ...)
  2014-03-19 17:57 ` [B.A.T.M.A.N.] [PATCHv4 next 05/11] " Antonio Quartulli
@ 2014-03-21  8:27 ` Marek Lindner
  4 siblings, 0 replies; 22+ messages in thread
From: Marek Lindner @ 2014-03-21  8:27 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

[-- Attachment #1: Type: text/plain, Size: 956 bytes --]

On Wednesday 19 March 2014 18:55:37 Antonio Quartulli wrote:
> There is no need to use a label and a goto for code that is
> used once only.
> Moreover having a goto for a single return statement should
> always be avoided.
> 
> Introduced by e368857f66620b8483166e8e6556d9c87f9b3e71
> ("batman-adv: Multicast Listener Announcements via Translation Table")
> 
> Cc: Linus Lüssing <linus.luessing@web.de>
> Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
> ---
> 
> Changes from v3:
> - simply has_bridge() function even more
> 
> Changes from v2:
> - added compat code change to 2/11 to accommodate new use of
>   netdev_master_upper_dev_get_rcu()
> 
> Changes from v1:
> - change "we are out of memory" to "in case of memory allocation failure" in
> 3/11
> - fix commit message in 10/11
> 
> 
>  multicast.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)

Applied in revision 6f54268.

Thanks,
Marek

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCHv4 next 02/11] batman-adv: don't mess up with the netdev refcounting if not needed
  2014-03-19 17:55 ` [B.A.T.M.A.N.] [PATCHv4 next 02/11] batman-adv: don't mess up with the netdev refcounting if not needed Antonio Quartulli
@ 2014-03-21  8:29   ` Marek Lindner
  0 siblings, 0 replies; 22+ messages in thread
From: Marek Lindner @ 2014-03-21  8:29 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

[-- Attachment #1: Type: text/plain, Size: 841 bytes --]

On Wednesday 19 March 2014 18:55:38 Antonio Quartulli wrote:
> Looking for an interface and increasing its refcounter only
> to check if it really exists is not really useful and makes
> the code look more complex without a real gain.
> 
> Change batadv_mcast_has_bridge() accordingly and avoid to
> use the pointer to the interface outside of the
> rcu_read_lock/unlock context.
> 
> Introduced by e368857f66620b8483166e8e6556d9c87f9b3e71
> ("batman-adv: Multicast Listener Announcements via Translation Table")
> 
> Cc: Linus Lüssing <linus.luessing@web.de>
> Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
> ---
>  compat.h    | 19 ++++---------------
>  multicast.c | 33 ++++-----------------------------
>  2 files changed, 8 insertions(+), 44 deletions(-)

Applied in revision 9ef7aad.

Thanks,
Marek

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCHv4 next 03/11] batman-adv: fix multicast kerneldoc
  2014-03-19 17:55 ` [B.A.T.M.A.N.] [PATCHv4 next 03/11] batman-adv: fix multicast kerneldoc Antonio Quartulli
@ 2014-03-21  8:30   ` Marek Lindner
  0 siblings, 0 replies; 22+ messages in thread
From: Marek Lindner @ 2014-03-21  8:30 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

[-- Attachment #1: Type: text/plain, Size: 612 bytes --]

On Wednesday 19 March 2014 18:55:39 Antonio Quartulli wrote:
> The kerneldoc should always use the third person singular in
> the long function description.
> Moreover it should always try use up to 80 chars per line.
> 
> Introduced by 86cb16e5ec1e2d75821006e8f4abbec66fb741ac
> ("batman-adv: Add IPv4 link-local/IPv6-ll-all-nodes multicast support")
> 
> Cc: Linus Lüssing <linus.luessing@web.de>
> Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
> ---
>  multicast.c | 12 ++++++------
>  1 file changed, 6 insertions(+), 6 deletions(-)

Applied in revision a36b345.

Thanks,
Marek

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCHv4 next 04/11] batman-adv: fix multicast kerneldoc
  2014-03-19 17:55 ` [B.A.T.M.A.N.] [PATCHv4 next 04/11] " Antonio Quartulli
@ 2014-03-21  8:31   ` Marek Lindner
  0 siblings, 0 replies; 22+ messages in thread
From: Marek Lindner @ 2014-03-21  8:31 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

[-- Attachment #1: Type: text/plain, Size: 618 bytes --]

On Wednesday 19 March 2014 18:55:40 Antonio Quartulli wrote:
> The kerneldoc should always use the third person singular in
> the long function description.
> Moreover it should always try use up to 80 chars per line.
> 
> Introduced by commit 01d665e054254618353ec8d9ea43d1a138de6e6d
> ("batman-adv: Multicast Listener Announcements via Translation Table")
> 
> Cc: Linus Lüssing <linus.luessing@web.de>
> Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
> ---
>  multicast.c | 12 ++++++------
>  1 file changed, 6 insertions(+), 6 deletions(-)

Applied in revision da22087.

Thanks,
Marek

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCHv4 next 05/11] batman-adv: fix multicast kerneldoc
  2014-03-19 17:57 ` [B.A.T.M.A.N.] [PATCHv4 next 05/11] " Antonio Quartulli
                     ` (5 preceding siblings ...)
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 11/11] " Antonio Quartulli
@ 2014-03-21  8:32   ` Marek Lindner
  6 siblings, 0 replies; 22+ messages in thread
From: Marek Lindner @ 2014-03-21  8:32 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

[-- Attachment #1: Type: text/plain, Size: 594 bytes --]

On Wednesday 19 March 2014 18:57:29 Antonio Quartulli wrote:
> The kerneldoc should always use the third person singular in
> the long function description.
> Moreover it should always try use up to 80 chars per line.
> 
> Introduced by f70c60d236cddb28d9e576de774ad97f9b0fd1b7
> ("batman-adv: Announce new capability via multicast TVLV")
> 
> Cc: Linus Lüssing <linus.luessing@web.de>
> Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
> ---
>  multicast.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)

Applied in revision 3b44ced.

Thanks,
Marek

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCHv4 next 06/11] batman-adv: fix multicast kerneldoc
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 06/11] " Antonio Quartulli
@ 2014-03-21  8:33     ` Marek Lindner
  0 siblings, 0 replies; 22+ messages in thread
From: Marek Lindner @ 2014-03-21  8:33 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

[-- Attachment #1: Type: text/plain, Size: 618 bytes --]

On Wednesday 19 March 2014 18:57:30 Antonio Quartulli wrote:
> The kerneldoc should always use the third person singular in
> the long function description.
> Moreover it should always try use up to 80 chars per line.
> 
> Introduced by 90ad6a40c80323805be1e86504385de2bd861f0a
> ("batman-adv: Modified forwarding behaviour for multicast packets")
> 
> Cc: Linus Lüssing <linus.luessing@web.de>
> Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
> ---
>  multicast.c | 20 ++++++++++----------
>  1 file changed, 10 insertions(+), 10 deletions(-)

Applied in revision 076d6a6.

Thanks,
Marek

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCHv4 next 07/11] batman-adv: fix multicast kerneldoc
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 07/11] " Antonio Quartulli
@ 2014-03-21  8:34     ` Marek Lindner
  0 siblings, 0 replies; 22+ messages in thread
From: Marek Lindner @ 2014-03-21  8:34 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

[-- Attachment #1: Type: text/plain, Size: 619 bytes --]

On Wednesday 19 March 2014 18:57:31 Antonio Quartulli wrote:
> The kerneldoc should always use the third person singular in
> the long function description.
> Moreover it should always try use up to 80 chars per line.
> 
> Introduced by f2ed1502191a37abb39e3e2c80cca07f0f3bb411
> ("batman-adv: Send multicast packets to nodes with a WANT_ALL flag")
> 
> Cc: Linus Lüssing <linus.luessing@web.de>
> Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
> ---
>  multicast.c | 20 ++++++++++----------
>  1 file changed, 10 insertions(+), 10 deletions(-)

Applied in revision 5690930.

Thanks,
Marek

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCHv4 next 08/11] batman-adv: adjust copyright disclaimer in multicast files
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 08/11] batman-adv: adjust copyright disclaimer in multicast files Antonio Quartulli
@ 2014-03-21  8:35     ` Marek Lindner
  0 siblings, 0 replies; 22+ messages in thread
From: Marek Lindner @ 2014-03-21  8:35 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

[-- Attachment #1: Type: text/plain, Size: 594 bytes --]

On Wednesday 19 March 2014 18:57:32 Antonio Quartulli wrote:
> The URL to the FSF address has to be always reported in the
> copyright disclaimer.
> This is the accepted style in the networking branch.
> 
> Introduced by e368857f66620b8483166e8e6556d9c87f9b3e71
> ("batman-adv: Multicast Listener Announcements via Translation Table")
> 
> Cc: Linus Lüssing <linus.luessing@web.de>
> Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
> ---
>  multicast.c | 3 +++
>  multicast.h | 3 +++
>  2 files changed, 6 insertions(+)

Applied in revision 04ff3a0.

Thanks,
Marek

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCHv4 next 09/11] batman-adv: fix code style
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 09/11] batman-adv: fix code style Antonio Quartulli
@ 2014-03-21  8:37     ` Marek Lindner
  0 siblings, 0 replies; 22+ messages in thread
From: Marek Lindner @ 2014-03-21  8:37 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

[-- Attachment #1: Type: text/plain, Size: 620 bytes --]

On Wednesday 19 March 2014 18:57:33 Antonio Quartulli wrote:
> - don't split lines if shorter than 80 chars
> - don't use goto if there is no cleanup to perform
> 
> Introduced by 90ad6a40c80323805be1e86504385de2bd861f0a
> ("batman-adv: Modified forwarding behaviour for multicast packets")
> 
> Cc: Linux Lüssing <linus.luessing@web.de>
> Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
> ---
>  multicast.c         | 3 +--
>  multicast.h         | 8 ++++----
>  translation-table.c | 5 ++---
>  3 files changed, 7 insertions(+), 9 deletions(-)

Applied in revision bc45afd.

Thanks,
Marek

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCHv4 next 10/11] batman-adv: fix more code style
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 10/11] batman-adv: fix more " Antonio Quartulli
@ 2014-03-21  8:39     ` Marek Lindner
  0 siblings, 0 replies; 22+ messages in thread
From: Marek Lindner @ 2014-03-21  8:39 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

[-- Attachment #1: Type: text/plain, Size: 597 bytes --]

On Wednesday 19 March 2014 18:57:34 Antonio Quartulli wrote:
> - keep variable declarations in descending line length order
> - use common iteration style pattern when looking up an
>   object
> 
> Introduced by 86cb16e5ec1e2d75821006e8f4abbec66fb741ac
> ("batman-adv: Add IPv4 link-local/IPv6-ll-all-nodes multicast support")
> 
> Cc: Linux Lüssing <linus.luessing@web.de>
> Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
> ---
>  multicast.c | 20 ++++++++++----------
>  1 file changed, 10 insertions(+), 10 deletions(-)

Applied in revision 45dab5f.

Thanks,
Marek

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCHv4 next 11/11] batman-adv: fix more code style
  2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 11/11] " Antonio Quartulli
@ 2014-03-21  8:40     ` Marek Lindner
  0 siblings, 0 replies; 22+ messages in thread
From: Marek Lindner @ 2014-03-21  8:40 UTC (permalink / raw)
  To: b.a.t.m.a.n; +Cc: Antonio Quartulli

[-- Attachment #1: Type: text/plain, Size: 542 bytes --]

On Wednesday 19 March 2014 18:57:35 Antonio Quartulli wrote:
> - use common iteration style pattern when looking up an
>   object
> 
> Introduced by f2ed1502191a37abb39e3e2c80cca07f0f3bb411
> ("batman-adv: Send multicast packets to nodes with a WANT_ALL flag")
> 
> Cc: Linux Lüssing <linus.luessing@web.de>
> Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
> ---
>  multicast.c | 32 ++++++++++++++++----------------
>  1 file changed, 16 insertions(+), 16 deletions(-)

Applied in revision b08dc3d.

Thanks,
Marek

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 22+ messages in thread

end of thread, other threads:[~2014-03-21  8:40 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-03-19 17:55 [B.A.T.M.A.N.] [PATCHv4 next 01/11] batman-adv: remove useless goto Antonio Quartulli
2014-03-19 17:55 ` [B.A.T.M.A.N.] [PATCHv4 next 02/11] batman-adv: don't mess up with the netdev refcounting if not needed Antonio Quartulli
2014-03-21  8:29   ` Marek Lindner
2014-03-19 17:55 ` [B.A.T.M.A.N.] [PATCHv4 next 03/11] batman-adv: fix multicast kerneldoc Antonio Quartulli
2014-03-21  8:30   ` Marek Lindner
2014-03-19 17:55 ` [B.A.T.M.A.N.] [PATCHv4 next 04/11] " Antonio Quartulli
2014-03-21  8:31   ` Marek Lindner
2014-03-19 17:57 ` [B.A.T.M.A.N.] [PATCHv4 next 05/11] " Antonio Quartulli
2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 06/11] " Antonio Quartulli
2014-03-21  8:33     ` Marek Lindner
2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 07/11] " Antonio Quartulli
2014-03-21  8:34     ` Marek Lindner
2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 08/11] batman-adv: adjust copyright disclaimer in multicast files Antonio Quartulli
2014-03-21  8:35     ` Marek Lindner
2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 09/11] batman-adv: fix code style Antonio Quartulli
2014-03-21  8:37     ` Marek Lindner
2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 10/11] batman-adv: fix more " Antonio Quartulli
2014-03-21  8:39     ` Marek Lindner
2014-03-19 17:57   ` [B.A.T.M.A.N.] [PATCHv4 next 11/11] " Antonio Quartulli
2014-03-21  8:40     ` Marek Lindner
2014-03-21  8:32   ` [B.A.T.M.A.N.] [PATCHv4 next 05/11] batman-adv: fix multicast kerneldoc Marek Lindner
2014-03-21  8:27 ` [B.A.T.M.A.N.] [PATCHv4 next 01/11] batman-adv: remove useless goto Marek Lindner

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.