summaryrefslogtreecommitdiff
path: root/nest/protocol.h
diff options
context:
space:
mode:
authorOndrej Zajicek <santiago@crfreenet.org>2010-01-03 12:17:52 +0100
committerOndrej Zajicek <santiago@crfreenet.org>2010-01-03 12:17:52 +0100
commitcf31112f0d7618464097f71228f84bd534f1bc0f (patch)
tree68f7fa93bd2154a16169b4db3dc9c16e51c2e84f /nest/protocol.h
parent610bb3cff05f6d5b09c77724bc97295b809d15e2 (diff)
Implements MRTdump feature.
Diffstat (limited to 'nest/protocol.h')
-rw-r--r--nest/protocol.h15
1 files changed, 12 insertions, 3 deletions
diff --git a/nest/protocol.h b/nest/protocol.h
index 21a1c1b4..5a69b33b 100644
--- a/nest/protocol.h
+++ b/nest/protocol.h
@@ -82,7 +82,8 @@ struct proto_config {
struct proto *proto; /* Instance we've created */
char *name;
char *dsc;
- unsigned debug, preference, disabled; /* Generic parameters */
+ u32 debug, mrtdump; /* Debugging bitfields, both use D_* constants */
+ unsigned preference, disabled; /* Generic parameters */
u32 router_id; /* Protocol specific router ID */
struct rtable_config *table; /* Table we're attached to */
struct filter *in_filter, *out_filter; /* Attached filters */
@@ -125,7 +126,8 @@ struct proto {
struct event *attn; /* "Pay attention" event */
char *name; /* Name of this instance (== cf->name) */
- unsigned debug; /* Debugging flags */
+ u32 debug; /* Debugging flags */
+ u32 mrtdump; /* MRTDump flags */
unsigned preference; /* Default route preference */
int min_scope; /* Minimal route scope accepted */
unsigned accept_ra_types; /* Which types of route announcements are accepted (RA_OPTIMAL or RA_ANY) */
@@ -199,7 +201,7 @@ void proto_request_feeding(struct proto *p);
void proto_show(struct symbol *, int);
struct proto *proto_get_named(struct symbol *, struct protocol *);
void proto_xxable(char *, int);
-void proto_debug(char *, unsigned int);
+void proto_debug(char *, int, unsigned int);
#define XX_DISABLE 0
#define XX_ENABLE 1
@@ -307,6 +309,13 @@ void proto_notify_state(struct proto *p, unsigned state);
#define D_PACKETS 32 /* Packets sent/received */
/*
+ * MRTDump flags
+ */
+
+#define MD_STATES 1 /* Protocol state changes (BGP4MP_MESSAGE_AS4) */
+#define MD_MESSAGES 2 /* Protocol packets (BGP4MP_MESSAGE_AS4) */
+
+/*
* Known unique protocol instances as referenced by config routines
*/