diff options
author | Martin Mares <mj@ucw.cz> | 1999-12-01 13:00:15 +0100 |
---|---|---|
committer | Martin Mares <mj@ucw.cz> | 1999-12-01 13:00:15 +0100 |
commit | 9685deb910c9e7400915209c1924e100b1feb5d5 (patch) | |
tree | 49e9108f91a43aab1e0a283418439ccb7232c7a9 /nest/protocol.h | |
parent | 5954dcfab74c8d8a2774f259c9940c1d87e76518 (diff) | |
download | bird-9685deb910c9e7400915209c1924e100b1feb5d5.tar bird-9685deb910c9e7400915209c1924e100b1feb5d5.zip |
`show protocols' now shows time of last state change and protocol-dependent
status information (obtained via newly introduced hook protocol->get_status).
Diffstat (limited to 'nest/protocol.h')
-rw-r--r-- | nest/protocol.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/nest/protocol.h b/nest/protocol.h index 8958d07..c77a935 100644 --- a/nest/protocol.h +++ b/nest/protocol.h @@ -11,6 +11,7 @@ #include "lib/lists.h" #include "lib/resource.h" +#include "lib/timer.h" struct iface; struct ifa; @@ -45,6 +46,7 @@ struct protocol { void (*dump_attrs)(struct rte *); /* Dump protocol-dependent attributes */ int (*start)(struct proto *); /* Start the instance */ int (*shutdown)(struct proto *); /* Stop the instance */ + void (*get_status)(struct proto *, byte *buf); /* Get instance status (for `show protocols' command) */ }; void protos_build(void); @@ -98,6 +100,7 @@ struct proto { unsigned proto_state; /* Protocol state machine (see below) */ unsigned core_state; /* Core state machine (see below) */ unsigned core_goal; /* State we want to reach (see below) */ + bird_clock_t last_state_change; /* Time of last state transition */ /* * General protocol hooks: |