[B.A.T.M.A.N.] [PATCH 17/28] batman-adv: Make bat_priv-curr_gw an rcu protected pointer

2011-03-05 Thread Sven Eckelmann
From: Linus Lüssing linus.luess...@ascom.ch The rcu protected macros rcu_dereference() and rcu_assign_pointer() for the bat_priv-curr_gw need to be used, as well as spin/rcu locking. Otherwise we might end up using a curr_gw pointer pointing to already freed memory. Reported-by: Sven Eckelmann

[B.A.T.M.A.N.] [PATCH 18/28] batman-adv: Increase orig_node refcount before releasing rcu read lock

2011-03-05 Thread Sven Eckelmann
From: Linus Lüssing linus.luess...@ascom.ch When unicast_send_skb() is increasing the orig_node's refcount another thread might have been freeing this orig_node already. We need to increase the refcount in the rcu read lock protected area to avoid that. Signed-off-by: Linus Lüssing

[B.A.T.M.A.N.] [PATCH 20/28] batman-adv: separate ethernet comparing calls from hash functions

2011-03-05 Thread Sven Eckelmann
From: Marek Lindner lindner_ma...@yahoo.de Note: The function compare_ether_addr() provided by the Linux kernel requires aligned memory. Signed-off-by: Marek Lindner lindner_ma...@yahoo.de --- net/batman-adv/hard-interface.c|2 +- net/batman-adv/main.c |2 +-

[B.A.T.M.A.N.] [PATCH 19/28] batman-adv: Fix possible buffer overflow in softif neigh list output

2011-03-05 Thread Sven Eckelmann
From: Linus Lüssing linus.luess...@ascom.ch When printing the soft interface table the number of entries in the softif neigh list are first being counted and a fitting buffer allocated. After that the softif neigh list gets locked again and the buffer printed - which has the following two issues:

[B.A.T.M.A.N.] [PATCH 22/28] batman-adv: Correct rcu refcounting for orig_node

2011-03-05 Thread Sven Eckelmann
condition all refcount operations have to be atomic. Reported-by: Sven Eckelmann s...@narfation.org Signed-off-by: Marek Lindner lindner_ma...@yahoo.de --- net/batman-adv/gateway_client.c|6 -- net/batman-adv/icmp_socket.c |2 +- net/batman-adv/originator.c| 21

[B.A.T.M.A.N.] [PATCH 23/28] batman-adv: increase refcount in create_neighbor to be consistent

2011-03-05 Thread Sven Eckelmann
From: Marek Lindner lindner_ma...@yahoo.de Signed-off-by: Marek Lindner lindner_ma...@yahoo.de --- net/batman-adv/originator.c |4 ++- net/batman-adv/routing.c| 63 ++ 2 files changed, 30 insertions(+), 37 deletions(-) diff --git

[B.A.T.M.A.N.] [PATCH 24/28] batman-adv: remove orig_hash spinlock

2011-03-05 Thread Sven Eckelmann
From: Marek Lindner lindner_ma...@yahoo.de Signed-off-by: Marek Lindner lindner_ma...@yahoo.de --- net/batman-adv/icmp_socket.c | 16 ++--- net/batman-adv/main.c|1 - net/batman-adv/originator.c | 21 net/batman-adv/routing.c | 75

[B.A.T.M.A.N.] [PATCH 25/28] batman-adv: rename global if_list to hardif_list

2011-03-05 Thread Sven Eckelmann
From: Marek Lindner lindner_ma...@yahoo.de Batman-adv works with hard interfaces as well as soft interfaces. The new name should better make clear which kind of interfaces this list stores. Signed-off-by: Marek Lindner lindner_ma...@yahoo.de --- net/batman-adv/hard-interface.c | 28

[B.A.T.M.A.N.] [PATCH 27/28] batman-adv: Remove unused hdr_size variable in route_unicast_packet()

2011-03-05 Thread Sven Eckelmann
From: Linus Lüssing linus.luess...@ascom.ch Signed-off-by: Linus Lüssing linus.luess...@ascom.ch Signed-off-by: Marek Lindner lindner_ma...@yahoo.de --- net/batman-adv/routing.c|7 +++ net/batman-adv/routing.h|3 +-- net/batman-adv/soft-interface.c |2 +- 3 files

[B.A.T.M.A.N.] [PATCH 28/28] batman-adv: Disallow regular interface as mesh device

2011-03-05 Thread Sven Eckelmann
When trying to associate a net_device with another net_device which already exists, batman-adv assumes that this interface is a fully initialized batman mesh interface without checking it. The behaviour when accessing data behind netdev_priv of a random net_device is undefined and potentially

Re: [B.A.T.M.A.N.] pull request: batman-adv 2011-03-05

2011-03-05 Thread Sven Eckelmann
On Saturday 05 March 2011 13:28:14 Sven Eckelmann wrote: Hi, I was asked to submit following pull request for net-next-2.6/linux-2.6.39. It contains Marek's hard work (and of course related work by other people) to remove the orig_hash (aka the batman-adv private big kernel lock). Small

Re: [B.A.T.M.A.N.] pull request: batman-adv 2011-03-05

2011-03-07 Thread Sven Eckelmann
On Monday 07 March 2011 03:14:32 David Miller wrote: Can you like sync with me when you have less than 20+ patches queued up? It's too much at once to reasonably review, and makes regressions take longer to bisect when people hit them. I'll try. The problem is that most of it is one work

Re: [B.A.T.M.A.N.] New BMX website at www.bmx6.net

2011-03-07 Thread Sven Eckelmann
On Monday 20 December 2010 13:17:51 Sven Eckelmann wrote: Axel Neumann wrote: Does that mean that your svn directories and git repositories at open-mesh.org can be dropped In the long term yes! But please not right now. I want to update links in other repositories like openWrt first

Re: [B.A.T.M.A.N.] BATMAN routing

2011-03-08 Thread Sven Eckelmann
On Monday 07 March 2011 22:00:25 hlabishi kobo wrote: Linus suggested to me that i should print the window and see how it looks, I did that and it returns this ef0fe, ffb, f70f, eb1b53c0, eb3950b8, eb1749c0. I am not sure if this are hexadecimal number or what. I would think that

Re: [B.A.T.M.A.N.] Wireless Bridge

2011-03-15 Thread Sven Eckelmann
On Tuesday 15 March 2011 18:58:16 A. AlBoori wrote: Good Day all, I have Wireless DSL router and Open Mesh Router. Open Mesh router == a router from open-mesh.com? We are not related to open-mesh.com Kind regards, Sven signature.asc Description: This is a digitally signed message

Re: [B.A.T.M.A.N.] Wireless Bridge

2011-03-15 Thread Sven Eckelmann
Tom Cannon wrote: It is unlikely your dsl modem can run any mesh protocol. (The Open-Mesh OM1P runs Robin, which uses olsr) Why do you want to run it as mesh? Maybe this wireless router can be configured as station. Or both devices can be configured to support 4 address mode. But this would

Re: [B.A.T.M.A.N.] BATMAN routing

2011-03-18 Thread Sven Eckelmann
On Thursday 17 March 2011 23:40:06 hlabishi kobo wrote: Hi thank you very much for your suggestions Sven, they were really helpful. i actually now put the below code down which i am still busy trying to test it. int weighted_bit_packet_count(TYPE_OF_WORD *seq_bits) { int i,check,

Re: [B.A.T.M.A.N.] BATMAN routing

2011-03-21 Thread Sven Eckelmann
On Monday 21 March 2011 23:40:57 hlabishi kobo wrote: [...] I actually printed the seq_bits[i] and that is basically why i used 32 but that was just for debugging purpose. But actually if i use NUM_WORDS, my weighted sum become very small whereas if i use 32 it becomes very big, trying to

[B.A.T.M.A.N.] [PATCH 2/2] batman-adv: Fix imbalanced locking in gw_node_update

2011-04-01 Thread Sven Eckelmann
8ffdea813e32cee3c60be36fb9e6a5e077e51ea0 used rcu_read_unlock without using rcu_read_lock when gw_get_selected_gw_node didn't return a valid gw_node. Signed-off-by: Sven Eckelmann s...@narfation.org --- gateway_client.c |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git

[B.A.T.M.A.N.] [PATCH 1/2] batman-adv: Add missing static for softif_neigh_deselect

2011-04-01 Thread Sven Eckelmann
053e6e6c30c161c218eacf2eb2eb4c7ecc0f387c forgot to mark the only locally used function softif_neigh_deselect as static. Signed-off-by: Sven Eckelmann s...@narfation.org --- soft-interface.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/soft-interface.c b/soft

[B.A.T.M.A.N.] [PATCHv2 2/2] batman-adv: Fix imbalanced locking in gw_node_update

2011-04-01 Thread Sven Eckelmann
8ffdea813e32cee3c60be36fb9e6a5e077e51ea0 used rcu_read_unlock without using rcu_read_lock when gw_get_selected_gw_node didn't return a valid gw_node. Signed-off-by: Sven Eckelmann s...@narfation.org --- Maybe the other patch is useful in the future... but changing the goto to a return is less

Re: [B.A.T.M.A.N.] batman-adv coexisting with olsr?

2011-04-11 Thread Sven Eckelmann
On Monday 11 April 2011 05:01:27 Ryan Hughes wrote: Hi. Is it possible to get batman-adv to coexist with olsr, working with different network prefixes? Cuz it seems to me that the olsr traffic would all get routed by batman, and every node would think it could see every other node, and olsr

Re: [B.A.T.M.A.N.] [PATCH] batman-adv: Fix crash on module shutdown with multiple ifaces

2011-04-16 Thread Sven Eckelmann
Sven Eckelmann wrote: Linus Lüssing wrote: hardif_remove_interfaces() removes all hard interfaces from the hardif_list before freeing and cleaning up any device. However the clean up procedures in orig_hash_del_if() (hardif_remove_interface()-hardif_disable_interface()- orig_hash_del_if

[B.A.T.M.A.N.] pull request: batman-adv 2011-04-17

2011-04-17 Thread Sven Eckelmann
Hi, I would like to propose following patches for net-next-2.6/2.6.40. Most of the stuff is cleanup work to reduce the locking complexity. The only exception is Andrew Lunn's patch, which only adds the initialisation of tx_queue_len. thanks, Sven The following changes since commit

[B.A.T.M.A.N.] [PATCH 1/8] batman-adv: Move bonding / iface alternating router search to own functions

2011-04-17 Thread Sven Eckelmann
linus.luess...@web.de Signed-off-by: Marek Lindner lindner_ma...@yahoo.de Signed-off-by: Sven Eckelmann s...@narfation.org --- net/batman-adv/routing.c | 180 +++--- 1 files changed, 105 insertions(+), 75 deletions(-) diff --git a/net/batman-adv/routing.c b

[B.A.T.M.A.N.] [PATCH 3/8] batman-adv: Simplify gw_check_election(), use gw_get_selected()

2011-04-17 Thread Sven Eckelmann
From: Linus Lüssing linus.luess...@web.de gw_get_selected() can get us the desired orig_node directly, therefore reusing that function in gw_check_election(). Signed-off-by: Linus Lüssing linus.luess...@web.de Signed-off-by: Marek Lindner lindner_ma...@yahoo.de Signed-off-by: Sven Eckelmann s

[B.A.T.M.A.N.] [PATCH 2/8] batman-adv: Make gateway_get_selected type safe

2011-04-17 Thread Sven Eckelmann
From: Linus Lüssing linus.luess...@web.de Make the return value explicit instead of (void *). Signed-off-by: Linus Lüssing linus.luess...@web.de Signed-off-by: Marek Lindner lindner_ma...@yahoo.de Signed-off-by: Sven Eckelmann s...@narfation.org --- net/batman-adv/gateway_client.c |2

[B.A.T.M.A.N.] [PATCH 4/8] batman-adv: Make orig_node-router an rcu protected pointer

2011-04-17 Thread Sven Eckelmann
the safe getter method orig_node_get_router(). Signed-off-by: Linus Lüssing linus.luess...@web.de Signed-off-by: Marek Lindner lindner_ma...@yahoo.de Signed-off-by: Sven Eckelmann s...@narfation.org --- net/batman-adv/gateway_client.c | 80 ++--- net/batman-adv/icmp_socket.c

[B.A.T.M.A.N.] [PATCH 5/8] batman-adv: Protect global TQ window with a spinlock

2011-04-17 Thread Sven Eckelmann
From: Linus Lüssing linus.luess...@web.de Signed-off-by: Linus Lüssing linus.luess...@web.de Signed-off-by: Marek Lindner lindner_ma...@yahoo.de Signed-off-by: Sven Eckelmann s...@narfation.org --- net/batman-adv/originator.c |1 + net/batman-adv/routing.c|4 net/batman-adv

[B.A.T.M.A.N.] [PATCH 6/8] batman-adv: concentrate all curr_gw related rcu operations in select/deselect functions

2011-04-17 Thread Sven Eckelmann
From: Marek Lindner lindner_ma...@yahoo.de Signed-off-by: Marek Lindner lindner_ma...@yahoo.de Signed-off-by: Sven Eckelmann s...@narfation.org --- net/batman-adv/gateway_client.c | 176 ++- net/batman-adv/gateway_client.h |2 +- net/batman-adv/unicast.c

[B.A.T.M.A.N.] [PATCH 7/8] batman-adv: protect softif_neigh by rcu

2011-04-17 Thread Sven Eckelmann
From: Simon Wunderlich s...@hrz.tu-chemnitz.de Add get/set wrapper functions for softif_neigh and use rcu functions to manipulate the pointers. Signed-off-by: Simon Wunderlich s...@hrz.tu-chemnitz.de Signed-off-by: Marek Lindner lindner_ma...@yahoo.de Signed-off-by: Sven Eckelmann s

[B.A.T.M.A.N.] [PATCH 8/8] batman-adv: Set the txqueuelen to zero when creating soft interface

2011-04-17 Thread Sven Eckelmann
, but the patch will avoid bufferbloat questions to the mailling lists in the future. Signed-off-by: Andrew Lunn and...@lunn.ch Tested-by: Linus Lüssing linus.luess...@web.de Signed-off-by: Marek Lindner lindner_ma...@yahoo.de Signed-off-by: Sven Eckelmann s...@narfation.org --- net/batman-adv/soft

Re: [B.A.T.M.A.N.] [PATCH] net: batman-adv: remove rx_csum ethtool_ops

2011-04-19 Thread Sven Eckelmann
Michał Mirosław wrote: Signed-off-by: Michał Mirosław mirq-li...@rere.qmqm.pl Applied thanks, Sven signature.asc Description: This is a digitally signed message part.

Re: [B.A.T.M.A.N.] [PATCH] batman-adv: Move definition of atomic_dec_not_zero() into main.h

2011-04-20 Thread Sven Eckelmann
On Wednesday 20 April 2011 08:54:39 Antonio Quartulli wrote: atomic_dec_not_zero() is very usefull and it is currently defined multiple times. So it is possible to move it in main.h I would prefer useful and a Signed-off-by: line. For the rest of the patch: Acked-by: Sven Eckelmann s

Re: [B.A.T.M.A.N.] smallest embedded hw running b.a.t.m.a.n ?

2011-04-25 Thread Sven Eckelmann
f campos wrote: Hi ! Could it be that you repeat yourself? I think I've already read that in banlktinza2tc68-dcc81rzhov1jsppo...@mail.gmail.com and banlktikrfblghckrkph4pwc4zup7eqw...@mail.gmail.com. Can the forum give feedback on the smallest embedded hw running b.a.t.m.a.n ? batmand or

Re: [B.A.T.M.A.N.] [PATCH] batman-adv: Fix crash on module shutdown with multiple ifaces

2011-04-29 Thread Sven Eckelmann
Linus Lüssing wrote: Ah, oki doki, didn't know about commit 5d4b5a4d and yes, a revert of that commit looks kind of similar to my patch. Commit 5d4b5a4d together with your statement confuse me a little. The commit message does not say anything about a locking dependancy issue, but seems to

[B.A.T.M.A.N.] [PATCH 2/2] batman-adv: Avoid deadlock between rtnl_lock and s_active

2011-04-29 Thread Sven Eckelmann
cannot wait for the rntl_lock before creating the actual batman-adv interface to prevent a deadlock. It is still possible to try to get the rtnl_lock and immediately abort the current operation when the trylock call failed. Signed-off-by: Sven Eckelmann s...@narfation.org --- bat_sysfs.c | 13

[B.A.T.M.A.N.] [PATCH 1/2] batman-adv: Remove unnecessary hardif_list_lock

2011-04-29 Thread Sven Eckelmann
hardif_list_lock is unneccessary because we already ensure that no multiple admin operations can take place through rtnl_lock. hardif_list_lock only adds additional overhead and complexity. Critical functions now check whether they are called with rtnl_lock using ASSERT_RTNL. Signed-off-by: Sven

[B.A.T.M.A.N.] [PATCHv2 1/3] batman-adv: Fix crash on module shutdown with multiple ifaces

2011-04-30 Thread Sven Eckelmann
will be down in the same way as removing single interfaces from batman only: One interface will be removed and cleaned at a time. Signed-off-by: Linus Lüssing linus.luess...@web.de [s...@narfation.org: Keep locking around list_for_each_entry_safe] Signed-off-by: Sven Eckelmann s...@narfation.org

[B.A.T.M.A.N.] [PATCHv2 2/3] batman-adv: Remove unnecessary hardif_list_lock

2011-04-30 Thread Sven Eckelmann
hardif_list_lock is unneccessary because we already ensure that no multiple admin operations can take place through rtnl_lock. hardif_list_lock only adds additional overhead and complexity. Critical functions now check whether they are called with rtnl_lock using ASSERT_RTNL. Signed-off-by: Sven

[B.A.T.M.A.N.] pull request: batman-adv 2011-05-01

2011-05-01 Thread Sven Eckelmann
Hi, I would like to propose following patches for net-next-2.6/2.6.40. Marek Lindner continued to convert different datastructures to use RCU. Antonio Quartulli fixed an important bug introduced in the last patchset related to the update of the current gateway. He also did some minor cleanup

[B.A.T.M.A.N.] [PATCH 1/4] batman-adv: orig_hash_find() manages rcu_lock/unlock internally

2011-05-01 Thread Sven Eckelmann
From: Antonio Quartulli or...@autistici.org orig_hash_find() manages rcu_lock/unlock internally and doesn't need to be surrounded by rcu_read_lock() / rcu_read_unlock() anymore Signed-off-by: Antonio Quartulli or...@autistici.org Acked-by: Marek Lindner lindner_ma...@yahoo.de Signed-off-by: Sven

[B.A.T.M.A.N.] [PATCH 2/4] batman-adv: Move definition of atomic_dec_not_zero() into main.h

2011-05-01 Thread Sven Eckelmann
From: Antonio Quartulli or...@autistici.org atomic_dec_not_zero() is very useful and it is currently defined multiple times. So it is possible to move it in main.h Signed-off-by: Antonio Quartulli or...@autistici.org Signed-off-by: Sven Eckelmann s...@narfation.org --- net/batman-adv

[B.A.T.M.A.N.] [PATCH 3/4] batman-adv: fix gw_node_update() and gw_election()

2011-05-01 Thread Sven Eckelmann
() is terminating in case of curr_gw == NULL. It has to terminate in case of curr_gw != NULL Signed-off-by: Antonio Quartulli or...@autistici.org Signed-off-by: Sven Eckelmann s...@narfation.org --- net/batman-adv/gateway_client.c | 12 1 files changed, 8 insertions(+), 4 deletions(-) diff

[B.A.T.M.A.N.] [PATCH 4/4] batman-adv: Make bat_priv-primary_if an rcu protected pointer

2011-05-01 Thread Sven Eckelmann
Lindner lindner_ma...@yahoo.de Signed-off-by: Sven Eckelmann s...@narfation.org --- net/batman-adv/gateway_client.c| 33 -- net/batman-adv/hard-interface.c| 83 --- net/batman-adv/hard-interface.h| 18 net/batman-adv/icmp_socket.c

Re: [B.A.T.M.A.N.] [PATCH] batman-adv: remove misplaced comment

2011-05-02 Thread Sven Eckelmann
/originator.c @@ -19,8 +19,6 @@ * */ -/* increase the reference counter for this originator */ Could we replace it with another joke? :D Acked-by: Sven Eckelmann s...@narfation.org Kind regards, Sven signature.asc Description: This is a digitally signed message part.

Re: [B.A.T.M.A.N.] [PATCH] batman-adv: purge unnecessary include

2011-05-02 Thread Sven Eckelmann
On Monday 02 May 2011 16:53:44 Marek Lindner wrote: Signed-off-by: Marek Lindner lindner_ma...@yahoo.de [] #include linux/version.h /* LINUX_VERSION_CODE */ -#include bat_sysfs.h /* struct bat_attribute */ This is necessary for kernels older than 2.6.24 make -C

Re: [B.A.T.M.A.N.] [PATCH] batman-adv: purge unnecessary include

2011-05-02 Thread Sven Eckelmann
On Monday 02 May 2011 17:09:31 Marek Lindner wrote: On Monday 02 May 2011 17:02:32 Sven Eckelmann wrote: On Monday 02 May 2011 16:53:44 Marek Lindner wrote: Signed-off-by: Marek Lindner lindner_ma...@yahoo.de [] #include linux/version.h /* LINUX_VERSION_CODE

Re: [B.A.T.M.A.N.] [PATCH] batman-adv: purge unnecessary include

2011-05-02 Thread Sven Eckelmann
On Monday 02 May 2011 17:09:31 Marek Lindner wrote: On Monday 02 May 2011 17:02:32 Sven Eckelmann wrote: On Monday 02 May 2011 16:53:44 Marek Lindner wrote: Signed-off-by: Marek Lindner lindner_ma...@yahoo.de [] #include linux/version.h /* LINUX_VERSION_CODE

Re: [B.A.T.M.A.N.] [PATCHv3 2/3] batman-adv: Remove unnecessary hardif_list_lock

2011-05-02 Thread Sven Eckelmann
Linus Lüssing wrote: Looks quite good and seems to make sense to avoid the double-locking. Tested it here and together with patch 1/3 fixes the initial issue, too. Just one minor thing: [58518.225154] batman_adv: bat0: The MTU of interface eth1 is too small (1500) to handle the

[B.A.T.M.A.N.] [PATCHv4 1/2] batman-adv: Remove unnecessary hardif_list_lock

2011-05-02 Thread Sven Eckelmann
the problem that orig_hash_del_if() expects that only one interface is deleted from hardif_list at a time, but hardif_remove_interfaces() removes all at once and then calls orig_hash_del_if(). Reported-by: Linus Lüssing linus.luess...@web.de Signed-off-by: Sven Eckelmann s...@narfation.org

[B.A.T.M.A.N.] [PATCHv4 2/2] batman-adv: Avoid deadlock between rtnl_lock and s_active

2011-05-02 Thread Sven Eckelmann
cannot wait for the rntl_lock before creating the actual batman-adv interface to prevent a deadlock. It is still possible to try to get the rtnl_lock and immediately abort the current operation when the trylock call failed. Signed-off-by: Sven Eckelmann s...@narfation.org --- Rebased on new merged

[B.A.T.M.A.N.] [RFC/PATCH] atomic: add *_dec_not_zero

2011-05-03 Thread Sven Eckelmann
. Miller da...@davemloft.net Signed-off-by: Sven Eckelmann s...@narfation.org --- Please check someone if this looks ok... I have to look through following people to check who would be interested in reviewing this patch: Richard Henderson r...@twiddle.net (:ALPHA PORT) Ivan Kokshaysky i

Re: [B.A.T.M.A.N.] (no subject)

2011-05-03 Thread Sven Eckelmann
On Tuesday 03 May 2011 11:51:37 Linus Lüssing wrote: With that tiny change, it now all works as expected and the patch 1/2 can also be used and verified without having to add patch 2/2 as well. Hope I'm not getting too picky :D. Thanks for your effort again, Sven! No, I am very happy with

[B.A.T.M.A.N.] [RFC/PATCH] batman-adv: Add compatibility code for kfree_rcu

2011-05-03 Thread Sven Eckelmann
Signed-off-by: Sven Eckelmann s...@narfation.org --- This is pure speculation and only to show how ugly it is... It is currently not used in Linus' tree DONT APPLY THIS PATCH Makefile.kbuild |1 + compat.c| 41

[B.A.T.M.A.N.] [PATCH 1/5] batman-adv: Rename bat_printk.c to compat.c

2011-05-04 Thread Sven Eckelmann
Signed-off-by: Sven Eckelmann s...@narfation.org --- Makefile.kbuild |2 +- bat_printk.c = compat.c |0 2 files changed, 1 insertions(+), 1 deletions(-) rename bat_printk.c = compat.c (100%) diff --git a/Makefile.kbuild b/Makefile.kbuild index 0a35006..d469668 100644

[B.A.T.M.A.N.] [PATCH 4/5] batman-adv: convert call_rcu(neigh_node_free_rcu) to kfree()

2011-05-04 Thread Sven Eckelmann
-chemnitz.de Cc: Sven Eckelmann s...@narfation.org Acked-by: David S. Miller da...@davemloft.net Signed-off-by: Sven Eckelmann s...@narfation.org --- originator.c | 10 +- 1 files changed, 1 insertions(+), 9 deletions(-) diff --git a/originator.c b/originator.c index ef4a9be..05cc738 100644

[B.A.T.M.A.N.] [PATCH 5/5] batman-adv: convert call_rcu(softif_neigh_free_rcu) to kfree_rcu

2011-05-04 Thread Sven Eckelmann
-chemnitz.de Cc: Sven Eckelmann s...@narfation.org Acked-by: David S. Miller da...@davemloft.net Signed-off-by: Sven Eckelmann s...@narfation.org --- soft-interface.c | 10 +- 1 files changed, 1 insertions(+), 9 deletions(-) diff --git a/soft-interface.c b/soft-interface.c index 9e5fcd1

[B.A.T.M.A.N.] [PATCH] batman-adv: cosmetic: Use ethtool ethtool_cmd_speed API

2011-05-04 Thread Sven Eckelmann
have been updated. Tested: make allyesconfig on x86_64 + e1000e/bnx2x work Signed-off-by: David Decotigny de...@google.com Signed-off-by: David S. Miller da...@davemloft.net [s...@narfation.org: compat function added] Signed-off-by: Sven Eckelmann s...@narfation.org --- This patch is now part of net

[B.A.T.M.A.N.] [PATCH-Marek 2/5] batman-adv: Add compatibility code for kfree_rcu

2011-05-04 Thread Sven Eckelmann
Signed-off-by: Sven Eckelmann s...@narfation.org --- compat.c | 30 +- compat.h | 10 ++ 2 files changed, 39 insertions(+), 1 deletions(-) diff --git a/compat.c b/compat.c index f4561c3..67c5126 100644 --- a/compat.c +++ b/compat.c @@ -1,4 +1,4

[B.A.T.M.A.N.] [PATCH] batman-adv: Fix rcu_lock imbalance in softif_neigh_get

2011-05-04 Thread Sven Eckelmann
Fix extra rcu_read_unlock after an failed softif_neigh_vid_get in softif_neigh_get introduced by 0281a6aab718965d7c0ef45c4ba22e305f6aefe7 Signed-off-by: Sven Eckelmann s...@narfation.org --- soft-interface.c |7 --- 1 files changed, 4 insertions(+), 3 deletions(-) diff --git a/soft

Re: [B.A.T.M.A.N.] [PATCHv3] batctl: rename stuff from *hna* to *tt* (translation table)

2011-05-05 Thread Sven Eckelmann
diff --git a/packet.h b/packet.h index e757187..c225c3a 100644 --- a/packet.h +++ b/packet.h @@ -61,7 +61,7 @@ struct batman_packet { uint8_t orig[6]; uint8_t prev_sender[6]; uint8_t ttl; - uint8_t num_hna; + uint8_t num_tt; uint8_t gw_flags; /*

Re: [B.A.T.M.A.N.] Routing decisions

2011-05-05 Thread Sven Eckelmann
Ed Okerson wrote: On Thu, May 5, 2011 at 10:44 AM, Marek Lindner lindner_ma...@yahoo.de wrote: Hi, We are evaluating using Batman in an environment where there could be 200-300 devices in a single building. We started out setting up 10 devices in our office to figure out how

Re: [B.A.T.M.A.N.] Routing decisions

2011-05-05 Thread Sven Eckelmann
Ed Okerson wrote: On Thu, May 5, 2011 at 12:35 PM, Sven Eckelmann s...@narfation.org wrote: Ed Okerson wrote: On Thu, May 5, 2011 at 10:44 AM, Marek Lindner lindner_ma...@yahoo.de wrote: Hi, We are evaluating using Batman in an environment where there could be 200-300

Re: [B.A.T.M.A.N.] [PATCHv2] batman-adv: Fix refcount imbalance in find_router

2011-05-05 Thread Sven Eckelmann
Marek Lindner wrote: Signed-off-by: Marek Lindner lindner_ma...@yahoo.de Acked-by: Sven Eckelmann s...@narfation.org signature.asc Description: This is a digitally signed message part.

Re: [B.A.T.M.A.N.] mesh

2011-05-06 Thread Sven Eckelmann
On Friday 06 May 2011 16:23:43 Jose Armando wrote: Hello Can any one tell me how to install batman on openwrt my router has openwrt install with luci but i cant install batman im need on this mesh or any one can build for me and i will pay for u time thank you batmand or batman-adv or bmxd

Re: [B.A.T.M.A.N.] mesh

2011-05-06 Thread Sven Eckelmann
On Friday 06 May 2011 18:11:21 Jose Armando wrote: Hello Sven Thank you so much for u info i will play with it Note Question if for one reason i cant make work can u help to install for me i can open telnet on my router and u can do for me i will pay you for u time and i will be greatfull

Re: [B.A.T.M.A.N.] mesh

2011-05-06 Thread Sven Eckelmann
On Friday 06 May 2011 19:02:48 Jose Armando wrote: Question so openwrt do not work with Batman? U saying I need to creater package for my router? Diego to much Question but I'm need I was think just install openwrt on the router u can install any package ? You still didn't answer what you

Re: [B.A.T.M.A.N.] mesh

2011-05-06 Thread Sven Eckelmann
On Friday 06 May 2011 19:21:58 Jose Armando wrote: Sorry seven here's is what looking for I would like to build a firmware that work like mesh and I been told that Batman is the best I'm new one this linux open source but I want to learn and I want to build mesh firmware that work with this 1

Re: [B.A.T.M.A.N.] mesh

2011-05-06 Thread Sven Eckelmann
On Friday 06 May 2011 19:31:33 Jose Armando wrote: Sven are u in usa? Not right now and propably not in the near future. Kind regards, Sven signature.asc Description: This is a digitally signed message part.

Re: [B.A.T.M.A.N.] mesh

2011-05-06 Thread Sven Eckelmann
On Friday 06 May 2011 19:58:46 Sebastián D. Criado wrote: El 06/05/11 14:39, Sven Eckelmann escribió: On Friday 06 May 2011 19:21:58 Jose Armando wrote: Sorry seven here's is what looking for I would like to build a firmware that work like mesh and I been told that Batman is the best I'm

[B.A.T.M.A.N.] [PATCH 1/2] batman-adv: Don't include bat_sysfs.h in compat.h

2011-05-07 Thread Sven Eckelmann
, but are available when it is used as in-kernel module. Signed-off-by: Sven Eckelmann s...@narfation.org --- compat.c | 29 + compat.h | 26 -- 2 files changed, 33 insertions(+), 22 deletions(-) diff --git a/compat.c b/compat.c index f4561c3

[B.A.T.M.A.N.] [PATCH 2/2] batman-adv: Remove unused variable r in bat_printk

2011-05-07 Thread Sven Eckelmann
Signed-off-by: Sven Eckelmann s...@narfation.org --- compat.c |3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) diff --git a/compat.c b/compat.c index 34b27a1..70de376 100644 --- a/compat.c +++ b/compat.c @@ -909,11 +909,10 @@ int bat_vscnprintf(char *buf, size_t size, const char

[B.A.T.M.A.N.] [PATCHv3] batman-adv: remove duplicate code from function is_bidirectional_neigh()

2011-05-07 Thread Sven Eckelmann
From: Daniele Furlan daniele.fur...@gmail.com In function is_bidirectional_neigh the code that find out the one hop neighbor is duplicated. Signed-off-by: Daniele Furlan daniele.fur...@gmail.com Signed-off-by: Sven Eckelmann s...@narfation.org --- No answer yet, but I would like to get

[B.A.T.M.A.N.] [PATCH] batman-adv: Fix line over 80 characters

2011-05-08 Thread Sven Eckelmann
160dd1399c4d589c0c5678a759e8ac7a7eefe64e introduced a line over 80 and can not be accepted according to the Linux Coding Style. Signed-off-by: Sven Eckelmann s...@narfation.org --- translation-table.c |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/translation-table.c

[B.A.T.M.A.N.] [PATCH 1/2] batman-adv: Remove multiline comments from line ending

2011-05-08 Thread Sven Eckelmann
It is slightly irritating that comments after a long line span over multiple lines without any code. It is easier to put them before the actual code and reduce the number of lines which the eye has to read. Signed-off-by: Sven Eckelmann s...@narfation.org --- This patch makes batman-adv nearly

[B.A.T.M.A.N.] [PATCH 2/2] batctl: Remove multiline comments from line ending

2011-05-08 Thread Sven Eckelmann
Signed-off-by: Sven Eckelmann s...@narfation.org --- packet.h |3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) diff --git a/packet.h b/packet.h index c225c3a..eda9965 100644 --- a/packet.h +++ b/packet.h @@ -128,8 +128,7 @@ struct vis_packet { uint8_t entries

[B.A.T.M.A.N.] pull request: batman-adv 2011-05-08

2011-05-08 Thread Sven Eckelmann
comment batman-adv: multi vlan support for bridge loop detection batman-adv: Fix refcount imbalance in find_router Sven Eckelmann (3): batman-adv: Remove unnecessary hardif_list_lock batman-adv: Avoid deadlock between rtnl_lock and s_active batman-adv: Remove multiline

[B.A.T.M.A.N.] [PATCH 2/8] batman-adv: multi vlan support for bridge loop detection

2011-05-08 Thread Sven Eckelmann
segment this patch extends the aforementioned bridge loop detection. Signed-off-by: Marek Lindner lindner_ma...@yahoo.de Signed-off-by: Sven Eckelmann s...@narfation.org --- net/batman-adv/main.c |3 +- net/batman-adv/soft-interface.c | 407 --- net

[B.A.T.M.A.N.] [PATCH 3/8] batman-adv: Remove unnecessary hardif_list_lock

2011-05-08 Thread Sven Eckelmann
the problem that orig_hash_del_if() expects that only one interface is deleted from hardif_list at a time, but hardif_remove_interfaces() removes all at once and then calls orig_hash_del_if(). Reported-by: Linus Lüssing linus.luess...@web.de Signed-off-by: Sven Eckelmann s...@narfation.org

[B.A.T.M.A.N.] [PATCH 4/8] batman-adv: Avoid deadlock between rtnl_lock and s_active

2011-05-08 Thread Sven Eckelmann
cannot wait for the rntl_lock before creating the actual batman-adv interface to prevent a deadlock. It is still possible to try to get the rtnl_lock and immediately abort the current operation when the trylock call failed. Signed-off-by: Sven Eckelmann s...@narfation.org --- net/batman-adv

[B.A.T.M.A.N.] [PATCH 5/8] batman-adv: Fix refcount imbalance in find_router

2011-05-08 Thread Sven Eckelmann
From: Marek Lindner lindner_ma...@yahoo.de Signed-off-by: Marek Lindner lindner_ma...@yahoo.de Signed-off-by: Sven Eckelmann s...@narfation.org --- net/batman-adv/routing.c | 14 +- 1 files changed, 9 insertions(+), 5 deletions(-) diff --git a/net/batman-adv/routing.c b/net/batman

[B.A.T.M.A.N.] [PATCH 8/8] batman-adv: remove duplicate code from function is_bidirectional_neigh()

2011-05-08 Thread Sven Eckelmann
From: Daniele Furlan daniele.fur...@gmail.com In function is_bidirectional_neigh the code that find out the one hop neighbor is duplicated. Signed-off-by: Daniele Furlan daniele.fur...@gmail.com Signed-off-by: Sven Eckelmann s...@narfation.org --- net/batman-adv/routing.c | 74

[B.A.T.M.A.N.] [PATCH] batman-adv: Fix build with linux 2.6.25-2.6.27

2011-05-09 Thread Sven Eckelmann
We must prevent that IPPROTO_UDP gets redefined using compat.h. Otherwise the build will fail when including things like net/addrconf.h Signed-off-by: Sven Eckelmann s...@narfation.org --- compat.c |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/compat.c b/compat.c index

[B.A.T.M.A.N.] [PATCH 1/4] batman-adv: Add compatibility code for kfree_rcu

2011-05-10 Thread Sven Eckelmann
Signed-off-by: Sven Eckelmann s...@narfation.org --- Rebased on top of current master + newest version from Paul E. McKenney compat.c | 28 compat.h | 10 ++ 2 files changed, 38 insertions(+), 0 deletions(-) diff --git a/compat.c b/compat.c index 586898f

[B.A.T.M.A.N.] [PATCHv2 3/4] batman-adv: convert call_rcu(neigh_node_free_rcu) to kfree()

2011-05-10 Thread Sven Eckelmann
-chemnitz.de Acked-by: David S. Miller da...@davemloft.net Reviewed-by: Josh Triplett j...@joshtriplett.org Signed-off-by: Sven Eckelmann s...@narfation.org --- Rebased on top of current master + newest version from Paul E. McKenney originator.c | 10 +- 1 files changed, 1 insertions(+), 9

[B.A.T.M.A.N.] [PATCHv2 4/4] batman-adv: convert call_rcu(softif_neigh_free_rcu) to kfree_rcu

2011-05-10 Thread Sven Eckelmann
-chemnitz.de Acked-by: David S. Miller da...@davemloft.net Reviewed-by: Josh Triplett j...@joshtriplett.org Signed-off-by: Sven Eckelmann s...@narfation.org --- Rebased on top of current master + newest version from Paul E. McKenney soft-interface.c | 10 +- 1 files changed, 1 insertions

[B.A.T.M.A.N.] [PATCH] batman-adv: Use kzalloc rather than kmalloc followed by memset with 0

2011-05-10 Thread Sven Eckelmann
Signed-off-by: Sven Eckelmann s...@narfation.org --- gateway_client.c |3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) diff --git a/gateway_client.c b/gateway_client.c index 65f3953..e638841 100644 --- a/gateway_client.c +++ b/gateway_client.c @@ -281,11 +281,10 @@ static void

[B.A.T.M.A.N.] [PATCH 2/2] batman-adv: Ensure that we really have route changes in update_route

2011-05-10 Thread Sven Eckelmann
reading it without this test. Signed-off-by: Sven Eckelmann s...@narfation.org --- routing.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/routing.c b/routing.c index 8c403ce..3f8355c 100644 --- a/routing.c +++ b/routing.c @@ -109,7 +109,7 @@ static void update_route(struct

[B.A.T.M.A.N.] [RFC PATCH] batman-adv: Add missing hardif_free_ref in forw_packet_free

2011-05-11 Thread Sven Eckelmann
add_bcast_packet_to_list increases the refcount for if_incoming but the reference count is never decreased. This is an regression introduced by 89079aec4c0c2c60a3a2561afcce62538cebd71d. Signed-off-by: Sven Eckelmann s...@narfation.org --- This patch is not ready to be applied - just a first note

[B.A.T.M.A.N.] [RFC PATCHv2] batman-adv: Add missing hardif_free_ref in forw_packet_free

2011-05-11 Thread Sven Eckelmann
to invoke forw_packet_free when a work item was really cancelled. This was a regression introduced by 89079aec4c0c2c60a3a2561afcce62538cebd71d. Signed-off-by: Sven Eckelmann s...@narfation.org --- I will leave the hard work to someone else (cleanup, fixing commit message, ...) aggregation.c

Re: [B.A.T.M.A.N.] [PATCH] batman-adv: reset broadcast flood protection on error

2011-05-14 Thread Sven Eckelmann
; forw_packet = kmalloc(sizeof(struct forw_packet), GFP_ATOMIC); Acked-by: Sven Eckelmann s...@narfation.org signature.asc Description: This is a digitally signed message part.

[B.A.T.M.A.N.] [PATCH 1/9] batman-adv: Annotate functions with format strings

2011-05-14 Thread Sven Eckelmann
Signed-off-by: Sven Eckelmann s...@narfation.org --- bat_debugfs.c |1 + main.h|3 ++- 2 files changed, 3 insertions(+), 1 deletions(-) diff --git a/bat_debugfs.c b/bat_debugfs.c index abaeec5..4577d3f 100644 --- a/bat_debugfs.c +++ b/bat_debugfs.c @@ -50,6 +50,7 @@ static void

[B.A.T.M.A.N.] [PATCH 2/9] batman-adv: Print jiffies as unsigned long

2011-05-14 Thread Sven Eckelmann
Signed-off-by: Sven Eckelmann s...@narfation.org --- bat_debugfs.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/bat_debugfs.c b/bat_debugfs.c index 4577d3f..e8491ee 100644 --- a/bat_debugfs.c +++ b/bat_debugfs.c @@ -82,7 +82,7 @@ int debug_log(struct bat_priv

[B.A.T.M.A.N.] [PATCH 3/9] batman-adv: Remove comparising 0 for unsigned type

2011-05-14 Thread Sven Eckelmann
Signed-off-by: Sven Eckelmann s...@narfation.org --- bat_debugfs.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/bat_debugfs.c b/bat_debugfs.c index e8491ee..628ab18 100644 --- a/bat_debugfs.c +++ b/bat_debugfs.c @@ -115,7 +115,7 @@ static ssize_t log_read(struct file

[B.A.T.M.A.N.] [PATCH 4/9] batman-adv: Don't do pointer arithmetic with void*

2011-05-14 Thread Sven Eckelmann
The size of void is currently set by gcc to 1, but is not well defined in general. Therefore it is more advisable to cast it to char* before doing pointer arithmetic. Signed-off-by: Sven Eckelmann s...@narfation.org --- originator.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions

[B.A.T.M.A.N.] [PATCH 5/9] batman-adv: Add const type qualifier for pointers

2011-05-14 Thread Sven 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 s...@narfation.org --- aggregation.c | 21 +++-- aggregation.h |5

[B.A.T.M.A.N.] [PATCH 6/9] batman-adv: Only use in up and down gw representation

2011-05-14 Thread Sven Eckelmann
It is not save to provide memory for an int and then cast the pointer to it to long*. It is better to standardize the up and down gateway bandwith representation to simple ints and only use long inside conversation routines. Signed-off-by: Sven Eckelmann s...@narfation.org --- gateway_common.c

[B.A.T.M.A.N.] [PATCH 7/9] batman-adv: Remove explicit casts cast from void* for store

2011-05-14 Thread Sven Eckelmann
It is not necessary to cast a void* to the pointer type when we just store it and don't want to do pointer arithmetic before the actual assignment. Signed-off-by: Sven Eckelmann s...@narfation.org --- bitarray.c |2 +- hard-interface.c|2 +- translation-table.c |2 +- 3

[B.A.T.M.A.N.] [PATCH 8/9] batman-adv: Remove casts from type x to type x

2011-05-14 Thread Sven Eckelmann
Casting from pointer like 'struct orig_node*' to 'struct orig_node *' doesn't provide any additional functionality and can be savely removed. Signed-off-by: Sven Eckelmann s...@narfation.org --- unicast.c |2 +- vis.c |2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff

<    2   3   4   5   6   7   8   9   10   11   >