Skip to contentSkip to conversation

batman-adv: Remove unnecessary braces for test_bit() in DAT

PATCH Applied Linus Lüssing 2 participants 6 messages Aug 14, 2015 – Sep 6, 2015 Batman advanced

lore
Share & tools
lore
#0 lore raw

PATCH 1/3 batman-adv: Remove unnecessary braces for test_bit() in DAT

Fixes de466678 ("batman-adv: Fix broken DAT capability check")
---
 net/batman-adv/distributed-arp-table.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
net/batman-adv/distributed-arp-table.c +1 -1
index 1caf7d2..63243a3 100644
@@ -453,7 +453,7 @@ static bool batadv_is_orig_node_eligible(struct batadv_dat_candidate *res,
 	int j;
 
 	/* check if orig node candidate is running DAT */
-	if (!(test_bit(BATADV_ORIG_CAPA_HAS_DAT, &candidate->capabilities)))
+	if (!test_bit(BATADV_ORIG_CAPA_HAS_DAT, &candidate->capabilities))
 		goto out;
 
 	/* Check if this node has already been selected... */
Signature · 1 line
1.7.10.4
#1 lore raw

PATCH 2/3 batman-adv: Remove unnecessary braces for test_bit() in NC

Fixes dfb27e75 ("batman-adv: Fix broken NC capability check")
---
 net/batman-adv/network-coding.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
net/batman-adv/network-coding.c +1 -1
index 55a0b28..1a1f7e6 100644
@@ -894,7 +894,7 @@ void batadv_nc_update_nc_node(struct batadv_priv *bat_priv,
 		goto out;
 
 	/* check if orig node is network coding enabled */
-	if (!(test_bit(BATADV_ORIG_CAPA_HAS_NC, &orig_node->capabilities)))
+	if (!test_bit(BATADV_ORIG_CAPA_HAS_NC, &orig_node->capabilities))
 		goto out;
 
 	/* accept ogms from 'good' neighbors and single hop neighbors */
Signature · 1 line
1.7.10.4
#2 lore raw

Re: [B.A.T.M.A.N.] [PATCH maint 2/3] batman-adv: Remove unnecessary braces for test_bit() in NC

Quoted 5 lines · On Friday, August 14, 2015 17:23:49 Linus Lüssing wrote:
Fixes dfb27e75 ("batman-adv: Fix broken NC capability check")
---
 net/batman-adv/network-coding.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Applied in revision 5abaf07.

Thanks,
Marek

#3 lore raw

PATCH 3/3 batman-adv: Remove unnecessary braces for test_bit() in MCAST

In reply to Linus Lüssing

Help! Help! \o/ I'm trapped in this commit message!!! :(

Fixes 1798ad3f ("batman-adv: Fix broken MCAST capability check")
---
 net/batman-adv/multicast.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
net/batman-adv/multicast.c +2 -2
index 8bdd69f..4541f08 100644
@@ -740,7 +740,7 @@ static void batadv_mcast_tvlv_ogm_handler_v1(struct batadv_priv *bat_priv,
 	 * is a completely new orig_node no need to decrease the counter.
 	 */
 	if (orig_mcast_enabled &&
-	    !(test_bit(BATADV_ORIG_CAPA_HAS_MCAST, &orig->capabilities))) {
+	    !test_bit(BATADV_ORIG_CAPA_HAS_MCAST, &orig->capabilities)) {
 		if (orig_initialized)
 			atomic_dec(&bat_priv->mcast.num_disabled);
 		set_bit(BATADV_ORIG_CAPA_HAS_MCAST, &orig->capabilities);
@@ -798,7 +798,7 @@ void batadv_mcast_purge_orig(struct batadv_orig_node *orig)
 
 	spin_lock_bh(&orig->mcast_handler_lock);
 
-	if (!(test_bit(BATADV_ORIG_CAPA_HAS_MCAST, &orig->capabilities)) &&
+	if (!test_bit(BATADV_ORIG_CAPA_HAS_MCAST, &orig->capabilities) &&
 	    test_bit(BATADV_ORIG_CAPA_HAS_MCAST, &orig->capa_initialized))
 		atomic_dec(&bat_priv->mcast.num_disabled);
 
Signature · 1 line
1.7.10.4
#4 lore raw

Re: [B.A.T.M.A.N.] [PATCH maint 3/3] batman-adv: Remove unnecessary braces for test_bit() in MCAST

Quoted 7 lines · On Friday, August 14, 2015 17:23:50 Linus Lüssing wrote:

Help! Help! \o/ I'm trapped in this commit message!!!

Fixes 1798ad3f ("batman-adv: Fix broken MCAST capability check")
---
 net/batman-adv/multicast.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Applied in revision d126204.

Thanks,
Marek