diff options
author | Paul Jakma <paul.jakma@sun.com> | 2006-07-27 19:59:58 +0000 |
---|---|---|
committer | Paul Jakma <paul.jakma@sun.com> | 2006-07-27 19:59:58 +0000 |
commit | 457eb9af72e6e7aa85c26b65ba4d053f9ecbffac (patch) | |
tree | ca93002285032e0c845749cfd770a446a9fc702b /zebra/zebra_rib.c | |
parent | 1893740016d35d75de567a5f6b74db2314ffdc52 (diff) |
[zebra] Add test rig code, for testing the zebra RIB
2006-07-27 Paul Jakma <paul.jakma@sun.com>
* {ioctl,kernel}_null.c: Dummy/Null kernel method implementations,
useful for testing zebra code that calls such methods.
* {redistribute,misc}_null.c: Dummy/Null methods, as above. But
for zclient, and for various misc functions.
* test_main.c: Test harness for zebra, currently just to test the
RIB.
* Makefile.am: Build testzebra using above.
* zebra_rib.c: Add a global for the workqueue hold time, useful
for testing.
Diffstat (limited to 'zebra/zebra_rib.c')
-rw-r--r-- | zebra/zebra_rib.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/zebra/zebra_rib.c b/zebra/zebra_rib.c index 665e5673..7373c6d8 100644 --- a/zebra/zebra_rib.c +++ b/zebra/zebra_rib.c @@ -42,6 +42,12 @@ /* Default rtm_table for all clients */ extern struct zebra_t zebrad; +/* Hold time for RIB process, should be very minimal. + * it is useful to able to set it otherwise for testing, hence exported + * as global here for test-rig code. + */ +int rib_process_hold_time = 10; + /* Each route type's string and default distance value. */ struct { @@ -1120,6 +1126,7 @@ rib_queue_init (struct zebra_t *zebra) zebra->ribq->spec.del_item_data = &rib_queue_qnode_del; /* XXX: TODO: These should be runtime configurable via vty */ zebra->ribq->spec.max_retries = 3; + zebra->ribq->spec.hold = rib_process_hold_time; return; } |