netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* pull request net: batman-adv 20140527
@ 2014-05-27  2:25 Antonio Quartulli
  2014-05-27  2:25 ` [PATCH] batman-adv: fix NULL pointer dereferences Antonio Quartulli
  2014-05-30 23:47 ` pull request net: batman-adv 20140527 David Miller
  0 siblings, 2 replies; 5+ messages in thread
From: Antonio Quartulli @ 2014-05-27  2:25 UTC (permalink / raw)
  To: davem; +Cc: netdev, b.a.t.m.a.n

Hello David,

here you have another very small fix intended for net/linux-3.15.
It prevents some multicast functions from dereferencing a NULL pointer.
(Actually it was nothing more than a typ0)
I hope it is not too late for such a small patch.


Please pull or let me know of any problem

Thanks a lot,
	Antonio



The following changes since commit b6ed5498601df40489606dbc14a9c7011c16630b:

  batman: fix a bogus warning from batadv_is_on_batman_iface() (2014-05-22 17:23:00 -0400)

are available in the git repository at:

  git://git.open-mesh.org/linux-merge.git 

for you to fetch changes up to 9d4190df6a21d96238133a9a64866a9c796f4ec8:

  batman-adv: fix NULL pointer dereferences (2014-05-23 16:32:32 +0200)

----------------------------------------------------------------
Included changes:
- prevent NULL dereference in multicast code

----------------------------------------------------------------
Marek Lindner (1):
      batman-adv: fix NULL pointer dereferences

 net/batman-adv/multicast.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

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

* [PATCH] batman-adv: fix NULL pointer dereferences
  2014-05-27  2:25 pull request net: batman-adv 20140527 Antonio Quartulli
@ 2014-05-27  2:25 ` Antonio Quartulli
  2014-05-30 23:47 ` pull request net: batman-adv 20140527 David Miller
  1 sibling, 0 replies; 5+ messages in thread
From: Antonio Quartulli @ 2014-05-27  2:25 UTC (permalink / raw)
  To: davem
  Cc: netdev, b.a.t.m.a.n, Marek Lindner, Linus Lüssing,
	Antonio Quartulli

From: Marek Lindner <mareklindner@neomailbox.ch>

Was introduced with 4c8755d69cbde2ec464a39c932aed0a83f9ff89f
("batman-adv: Send multicast packets to nodes with a WANT_ALL flag")

Reported-by: Sven Eckelmann <sven@narfation.org>
Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch>
Acked-by: Antonio Quartulli <antonio@meshcoding.com>
Signed-off-by: Linus Lüssing <linus.luessing@web.de>
Signed-off-by: Antonio Quartulli <antonio@meshcoding.com>
---
 net/batman-adv/multicast.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/net/batman-adv/multicast.c b/net/batman-adv/multicast.c
index 8c7ca81..96b66fd 100644
--- a/net/batman-adv/multicast.c
+++ b/net/batman-adv/multicast.c
@@ -415,7 +415,7 @@ batadv_mcast_forw_ipv4_node_get(struct batadv_priv *bat_priv)
 	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))
+		if (!atomic_inc_not_zero(&tmp_orig_node->refcount))
 			continue;
 
 		orig_node = tmp_orig_node;
@@ -442,7 +442,7 @@ batadv_mcast_forw_ipv6_node_get(struct batadv_priv *bat_priv)
 	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))
+		if (!atomic_inc_not_zero(&tmp_orig_node->refcount))
 			continue;
 
 		orig_node = tmp_orig_node;
@@ -493,7 +493,7 @@ batadv_mcast_forw_unsnoop_node_get(struct batadv_priv *bat_priv)
 	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))
+		if (!atomic_inc_not_zero(&tmp_orig_node->refcount))
 			continue;
 
 		orig_node = tmp_orig_node;
-- 
1.8.5.5

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

* Re: pull request net: batman-adv 20140527
  2014-05-27  2:25 pull request net: batman-adv 20140527 Antonio Quartulli
  2014-05-27  2:25 ` [PATCH] batman-adv: fix NULL pointer dereferences Antonio Quartulli
@ 2014-05-30 23:47 ` David Miller
  2014-05-31  9:26   ` Antonio Quartulli
  1 sibling, 1 reply; 5+ messages in thread
From: David Miller @ 2014-05-30 23:47 UTC (permalink / raw)
  To: antonio; +Cc: netdev, b.a.t.m.a.n

From: Antonio Quartulli <antonio@meshcoding.com>
Date: Tue, 27 May 2014 04:25:46 +0200

> Hello David,
> 
> here you have another very small fix intended for net/linux-3.15.
> It prevents some multicast functions from dereferencing a NULL pointer.
> (Actually it was nothing more than a typ0)
> I hope it is not too late for such a small patch.
> 
> 
> Please pull or let me know of any problem
 ...
> are available in the git repository at:
> 
>   git://git.open-mesh.org/linux-merge.git 

This doesn't work:

[davem@dokdo net]$ git pull git://git.open-mesh.org/linux-merge.git 
remote: Counting objects: 10335, done.        
remote: Compressing objects: 100% (2687/2687), done.        
remote: Total 9894 (delta 7726), reused 9123 (delta 7189)        
Receiving objects: 100% (9894/9894), 1.98 MiB | 399 KiB/s, done.
Resolving deltas: 100% (7726/7726), completed with 236 local objects.
>From git://git.open-mesh.org/linux-merge
 * branch            HEAD       -> FETCH_HEAD
Auto-merging net/batman-adv/types.h
Auto-merging net/batman-adv/translation-table.c
CONFLICT (content): Merge conflict in net/batman-adv/translation-table.c
Auto-merging net/batman-adv/sysfs.c
Auto-merging net/batman-adv/soft-interface.c
Auto-merging net/batman-adv/send.c
CONFLICT (content): Merge conflict in net/batman-adv/send.c
Auto-merging net/batman-adv/network-coding.c
Auto-merging net/batman-adv/multicast.c
CONFLICT (add/add): Merge conflict in net/batman-adv/multicast.c
Auto-merging net/batman-adv/main.h
CONFLICT (content): Merge conflict in net/batman-adv/main.h
Auto-merging net/batman-adv/distributed-arp-table.c
warning: inexact rename detection was skipped due to too many files.
warning: you may want to set your merge.renamelimit variable to at least 1268 and retry the command.
Automatic merge failed; fix conflicts and then commit the result.

You seem to have a bunch of unrelated things in this tree.

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

* Re: pull request net: batman-adv 20140527
  2014-05-30 23:47 ` pull request net: batman-adv 20140527 David Miller
@ 2014-05-31  9:26   ` Antonio Quartulli
  2014-06-01  3:02     ` David Miller
  0 siblings, 1 reply; 5+ messages in thread
From: Antonio Quartulli @ 2014-05-31  9:26 UTC (permalink / raw)
  To: David Miller; +Cc: netdev, b.a.t.m.a.n

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

David,

On 31/05/14 01:47, David Miller wrote:
> From: Antonio Quartulli <antonio@meshcoding.com>
> Date: Tue, 27 May 2014 04:25:46 +0200
> 
>> Hello David,
>>
>> here you have another very small fix intended for net/linux-3.15.
>> It prevents some multicast functions from dereferencing a NULL pointer.
>> (Actually it was nothing more than a typ0)
>> I hope it is not too late for such a small patch.
>>
>>
>> Please pull or let me know of any problem
>  ...
>> are available in the git repository at:
>>
>>   git://git.open-mesh.org/linux-merge.git 
> 

ops, this was supposed to be:

git://git.open-mesh.org/linux-merge.git tags/batman-adv-fix-for-davem

Can you pull this tag please?

(I just rebased my branch on top of the current net/master once again to
be sure that everything is in order).


Thanks a lot!



-- 
Antonio Quartulli


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 901 bytes --]

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

* Re: pull request net: batman-adv 20140527
  2014-05-31  9:26   ` Antonio Quartulli
@ 2014-06-01  3:02     ` David Miller
  0 siblings, 0 replies; 5+ messages in thread
From: David Miller @ 2014-06-01  3:02 UTC (permalink / raw)
  To: antonio; +Cc: netdev, b.a.t.m.a.n

From: Antonio Quartulli <antonio@meshcoding.com>
Date: Sat, 31 May 2014 11:26:39 +0200

> ops, this was supposed to be:
> 
> git://git.open-mesh.org/linux-merge.git tags/batman-adv-fix-for-davem
> 
> Can you pull this tag please?
> 
> (I just rebased my branch on top of the current net/master once again to
> be sure that everything is in order).

Pulled, thanks.

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

end of thread, other threads:[~2014-06-01  3:02 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-27  2:25 pull request net: batman-adv 20140527 Antonio Quartulli
2014-05-27  2:25 ` [PATCH] batman-adv: fix NULL pointer dereferences Antonio Quartulli
2014-05-30 23:47 ` pull request net: batman-adv 20140527 David Miller
2014-05-31  9:26   ` Antonio Quartulli
2014-06-01  3:02     ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).