babeld: remove remains of standalone babeld's configuration code.

Standalone babeld has a configuration interface that is not used in
Quagga.  This removes a few bits of this code that survived the
port to Quagga.
This commit is contained in:
Juliusz Chroboczek 2012-02-14 08:49:57 +01:00 committed by Paul Jakma
parent cb4b13d945
commit 36329c02c3
5 changed files with 8 additions and 23 deletions

View File

@ -565,10 +565,6 @@ interface_recalculate(struct interface *ifp)
babel_ifp->flags |= BABEL_IF_LQ;
}
/* Since the interface was marked as active above, the
idle_hello_interval cannot be the one being used here. */
babel_ifp->update_interval = babel_ifp->hello_interval * 4;
memset(&mreq, 0, sizeof(mreq));
memcpy(&mreq.ipv6mr_multiaddr, protocol_group, 16);
mreq.ipv6mr_interface = ifp->ifindex;
@ -1019,7 +1015,8 @@ babel_interface_allocate (void)
babel_ifp->bucket_time = babel_now.tv_sec;
babel_ifp->bucket = BUCKET_TOKENS_MAX;
babel_ifp->hello_seqno = (random() & 0xFFFF);
babel_ifp->hello_interval = BABELD_DEFAULT_HELLO_INTERVAL;
babel_ifp->hello_interval = BABEL_DEFAULT_HELLO_INTERVAL;
babel_ifp->update_interval = BABEL_DEFAULT_UPDATE_INTERVAL;
babel_ifp->channel = BABEL_IF_CHANNEL_INTERFERING;
return babel_ifp;

View File

@ -91,8 +91,6 @@ static inline babel_interface_nfo* babel_get_if_nfo(struct interface *ifp)
return ((babel_interface_nfo*) ifp->info);
}
#define IF_CONF(_ifp, _field) babel_get_if_nfo(_ifp)->_field
/* babel_interface_nfo flags */
#define BABEL_IF_IS_UP (1 << 0)
#define BABEL_IF_WIRED (1 << 1)

View File

@ -79,8 +79,6 @@ struct timeval babel_now; /* current time */
unsigned char myid[8]; /* unique id (mac address of an interface) */
int debug = 0;
int default_wireless_hello_interval = -1;
int default_wired_hello_interval = -1;
int resend_delay = -1;
static const char *pidfile = PATH_BABELD_PID;
@ -258,18 +256,7 @@ babel_init(int argc, char **argv)
vty_init (master);
memory_init ();
if(default_wireless_hello_interval <= 0)
default_wireless_hello_interval = 4000;
default_wireless_hello_interval = MAX(default_wireless_hello_interval, 5);
if(default_wired_hello_interval <= 0)
default_wired_hello_interval = 4000;
default_wired_hello_interval = MAX(default_wired_hello_interval, 5);
resend_delay = 2000;
resend_delay = MIN(resend_delay, default_wireless_hello_interval / 2);
resend_delay = MIN(resend_delay, default_wired_hello_interval / 2);
resend_delay = MAX(resend_delay, 20);
resend_delay = BABEL_DEFAULT_RESEND_DELAY;
if(parasitic && allow_duplicates >= 0) {
/* Too difficult to get right. */

View File

@ -41,7 +41,6 @@ THE SOFTWARE.
extern struct timeval babel_now; /* current time */
extern struct thread_master *master; /* quagga's threads handler */
extern int debug;
extern int default_wireless_hello_interval, default_wired_hello_interval;
extern int resend_delay;
extern unsigned char myid[8];

View File

@ -107,7 +107,11 @@ THE SOFTWARE.
#define BABEL_VTY_PORT 2609
#define BABEL_DEFAULT_CONFIG "babeld.conf"
#define BABEL_VERSION "0.1 for quagga"
#define BABELD_DEFAULT_HELLO_INTERVAL 4000 /* miliseconds */
/* Values in milliseconds */
#define BABEL_DEFAULT_HELLO_INTERVAL 4000
#define BABEL_DEFAULT_UPDATE_INTERVAL 16000
#define BABEL_DEFAULT_RESEND_DELAY 2000
/* Babel socket. */