From cc47f66e6b9ec7e7d465f74739a6fc9844593894 Mon Sep 17 00:00:00 2001 From: Antonio Quartulli Date: Wed, 27 Apr 2011 14:27:57 +0200 Subject: batman-adv: improved roaming mechanism With the current client announcement implementation, in case of roaming, an update is triggered on the new AP serving the client. At that point the new information is spread around by means of the OGM broadcasting mechanism. Until this operations is not executed, no node is able to correctly route traffic towards the client. This obviously causes packet drops and introduces a delay in the time needed by the client to recover its connections. A new packet type called ROAMING_ADVERTISEMENT is added to account this issue. This message is sent in case of roaming from the new AP serving the client to the old one and will contain the client MAC address. In this way an out-of-OGM update is immediately committed, so that the old node can update its global translation table. Traffic reaching this node will then be redirected to the correct destination utilising the fresher information. Thus reducing the packet drops and the connection recovery delay. Signed-off-by: Antonio Quartulli Signed-off-by: Sven Eckelmann --- net/batman-adv/main.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'net/batman-adv/main.h') diff --git a/net/batman-adv/main.h b/net/batman-adv/main.h index 6f53a1de778c..8eae05e4dc1b 100644 --- a/net/batman-adv/main.h +++ b/net/batman-adv/main.h @@ -42,7 +42,7 @@ * -> TODO: check influence on TQ_LOCAL_WINDOW_SIZE */ #define PURGE_TIMEOUT 200 #define TT_LOCAL_TIMEOUT 3600 /* in seconds */ - +#define TT_CLIENT_ROAM_TIMEOUT 600 /* sliding packet range of received originator messages in squence numbers * (should be a multiple of our word size) */ #define TQ_LOCAL_WINDOW_SIZE 64 @@ -55,6 +55,10 @@ #define TT_OGM_APPEND_MAX 3 /* number of OGMs sent with the last tt diff */ +#define ROAMING_MAX_TIME 20 /* Time in which a client can roam at most + * ROAMING_MAX_COUNT times */ +#define ROAMING_MAX_COUNT 5 + #define NO_FLAGS 0 #define NUM_WORDS (TQ_LOCAL_WINDOW_SIZE / WORD_BIT_SIZE) -- cgit v1.2.3