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

2011-05-05 Thread Antonio Quartulli
To be coherent, all the functions/variables/constats have been renamed to the TranslationTable style Signed-off-by: Antonio Quartulli or...@autistici.org --- The man page hass been corrected. Some '-H' were still there. Thanks Marek. README | 18 +- man/batctl.8 | 12

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; /*

[B.A.T.M.A.N.] batman-adv: added uevent support for gw and gw propagation for clients

2011-05-05 Thread Antonio Quartulli
Three new features have been added: 1) generic uevent support 2) uevent triggering for gw state changes 3) gw propagation for clients Patch summary: - 1/3: a wrapper function that permits to trigger uevents has been added. The function takes a type, an action and a data as parameters which will

[B.A.T.M.A.N.] [PATCH 1/3] batman-adv: add wrapper function to throw uevent in userspace

2011-05-05 Thread Antonio Quartulli
Using throw_uevent() is now possible to trigger uevent signal that can be recognised in userspace. Uevents will be triggered through the /devices/virtual/net/{MESH_IFACE} kobject. A triggered uevent has three properties: - type: the event class. Who generates the event (only 'gw' is currently

[B.A.T.M.A.N.] [PATCH 2/3] batman-adv: throw uevent in userspace on gateway add/change/del event

2011-05-05 Thread Antonio Quartulli
In case of new default gw, changing the default gw or deleting the default gw a uevent is triggered with type=gw, action=add/change/del and data={GW_ORIG_ADDRESS} (if any). The gateway election mechanism has been a little revised. Now the gw_election is trigered by an atomic_t flag (gw_reselect)

[B.A.T.M.A.N.] [PATCH] batman-adv: move neigh_node-if_incoming-if_status check in find_router()

2011-05-05 Thread Antonio Quartulli
Every time that find_router() is invoked, if_status has to be compared with IF_ACTIVE. Moving this comparison inside find_router() will avoid to write it each time. Signed-off-by: Antonio Quartulli or...@autistici.org --- routing.c |4 +++- unicast.c |3 --- 2 files changed, 3

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

2011-05-05 Thread Daniele Furlan
In function is_bidirectional_neigh the code that find out the one hop neighbor is duplicated. This patch remove the duplicate code and adjust the comments. P.S. It's my first patch, let me know if there is any problem. Signed-off-by: Daniele Furlan daniele.fur...@gmail.com --- routing.c | 75

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

2011-05-05 Thread Marek Lindner
Signed-off-by: Marek Lindner lindner_ma...@yahoo.de --- routing.c | 14 +- 1 files changed, 9 insertions(+), 5 deletions(-) diff --git a/routing.c b/routing.c index 49f5715..d8cde2b 100644 --- a/routing.c +++ b/routing.c @@ -1213,7 +1213,7 @@ struct neigh_node *find_router(struct

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

2011-05-05 Thread Marek Lindner
Signed-off-by: Marek Lindner lindner_ma...@yahoo.de --- Fixed wrong subject. routing.c | 14 +- 1 files changed, 9 insertions(+), 5 deletions(-) diff --git a/routing.c b/routing.c index 49f5715..d8cde2b 100644 --- a/routing.c +++ b/routing.c @@ -1213,7 +1213,7 @@ struct neigh_node

Re: [B.A.T.M.A.N.] [PATCH] batman-adv: move neigh_node-if_incoming-if_status check in find_router()

2011-05-05 Thread Marek Lindner
On Thursday 05 May 2011 10:21:42 Antonio Quartulli wrote: return_router: + if (router router-if_incoming-if_status != IF_ACTIVE) + router = NULL; + rcu_read_unlock(); return router; You are breaking the reference counting of 'router' here. While looking

Re: [B.A.T.M.A.N.] [PATCH 1/3] batman-adv: add wrapper function to throw uevent in userspace

2011-05-05 Thread Andrew Lunn
On Thu, May 05, 2011 at 09:13:07AM +0200, Antonio Quartulli wrote: Using throw_uevent() is now possible to trigger uevent signal that can be recognised in userspace. Uevents will be triggered through the /devices/virtual/net/{MESH_IFACE} kobject. A triggered uevent has three properties: -

Re: [B.A.T.M.A.N.] [PATCH 3/3] batman-adv: improved gateway tq-based selection

2011-05-05 Thread Andrew Lunn
On Thu, May 05, 2011 at 09:13:09AM +0200, Antonio Quartulli wrote: + /* If old_gw != NULL then this packet is unicast. + * So, at this point it can only be a renewal packet (because it is the + * only dhcp client message sent as unicast) and we have to decide + * whether to

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

2011-05-05 Thread Ed Okerson
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 everything works and do some throughput testing. We have noticed that the routing decisions always send the packet

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.] [PATCHv2] batman-adv: Fix refcount imbalance in find_router

2011-05-05 Thread Marek Lindner
On Thursday 05 May 2011 21:01:43 Sven Eckelmann wrote: Marek Lindner wrote: Signed-off-by: Marek Lindner lindner_ma...@yahoo.de Acked-by: Sven Eckelmann s...@narfation.org Applied in revision ca6b80c. Thanks for the review, Marek