summaryrefslogtreecommitdiffstats
path: root/ospf6d
diff options
context:
space:
mode:
Diffstat (limited to 'ospf6d')
-rw-r--r--ospf6d/ospf6_intra.c52
-rw-r--r--ospf6d/ospf6_intra.h3
-rw-r--r--ospf6d/ospf6_route.h7
-rw-r--r--ospf6d/ospf6_top.c4
4 files changed, 66 insertions, 0 deletions
diff --git a/ospf6d/ospf6_intra.c b/ospf6d/ospf6_intra.c
index 103e8fc2..bba63f47 100644
--- a/ospf6d/ospf6_intra.c
+++ b/ospf6d/ospf6_intra.c
@@ -1291,6 +1291,58 @@ ospf6_brouter_debug_print (struct ospf6_route *brouter)
}
void
+ospf6_brouter_debug_print (struct ospf6_route *brouter)
+{
+ u_int32_t brouter_id;
+ char brouter_name[16];
+ char area_name[16];
+ char destination[64];
+ char installed[16], changed[16];
+ struct timeval now, res;
+ char id[16], adv_router[16];
+ char capa[16], options[16];
+
+ brouter_id = ADV_ROUTER_IN_PREFIX (&brouter->prefix);
+ inet_ntop (AF_INET, &brouter_id, brouter_name, sizeof (brouter_name));
+ inet_ntop (AF_INET, &brouter->path.area_id, area_name, sizeof (area_name));
+ ospf6_linkstate_prefix2str (&brouter->prefix, destination,
+ sizeof (destination));
+
+ gettimeofday (&now, (struct timezone *) NULL);
+ timersub (&now, &brouter->installed, &res);
+ timerstring (&res, installed, sizeof (installed));
+
+ gettimeofday (&now, (struct timezone *) NULL);
+ timersub (&now, &brouter->changed, &res);
+ timerstring (&res, changed, sizeof (changed));
+
+ inet_ntop (AF_INET, &brouter->path.origin.id, id, sizeof (id));
+ inet_ntop (AF_INET, &brouter->path.origin.adv_router, adv_router,
+ sizeof (adv_router));
+
+ ospf6_options_printbuf (brouter->path.options, options, sizeof (options));
+ ospf6_capability_printbuf (brouter->path.router_bits, capa, sizeof (capa));
+
+ zlog_info ("Brouter: %s via area %s", brouter_name, area_name);
+ zlog_info (" memory: prev: %p this: %p next: %p parent rnode: %p",
+ brouter->prev, brouter, brouter->next, brouter->rnode);
+ zlog_info (" type: %d prefix: %s installed: %s changed: %s",
+ brouter->type, destination, installed, changed);
+ zlog_info (" lock: %d flags: %s%s%s%s", brouter->lock,
+ (CHECK_FLAG (brouter->flag, OSPF6_ROUTE_BEST) ? "B" : "-"),
+ (CHECK_FLAG (brouter->flag, OSPF6_ROUTE_ADD) ? "A" : "-"),
+ (CHECK_FLAG (brouter->flag, OSPF6_ROUTE_REMOVE) ? "R" : "-"),
+ (CHECK_FLAG (brouter->flag, OSPF6_ROUTE_CHANGE) ? "C" : "-"));
+ zlog_info (" path type: %s ls-origin %s id: %s adv-router %s",
+ OSPF6_PATH_TYPE_NAME (brouter->path.type),
+ ospf6_lstype_name (brouter->path.origin.type),
+ id, adv_router);
+ zlog_info (" options: %s router-bits: %s metric-type: %d metric: %d/%d",
+ options, capa, brouter->path.metric_type,
+ brouter->path.cost, brouter->path.cost_e2);
+}
+
+void
ospf6_intra_brouter_calculation (struct ospf6_area *oa)
{
struct ospf6_route *brouter, *copy;
diff --git a/ospf6d/ospf6_intra.h b/ospf6d/ospf6_intra.h
index 31643fd8..19c1f121 100644
--- a/ospf6d/ospf6_intra.h
+++ b/ospf6d/ospf6_intra.h
@@ -210,5 +210,8 @@ extern void ospf6_intra_init (void);
extern int config_write_ospf6_debug_brouter (struct vty *vty);
extern void install_element_ospf6_debug_brouter (void);
+int config_write_ospf6_debug_brouter (struct vty *vty);
+void install_element_ospf6_debug_brouter ();
+
#endif /* OSPF6_LSA_H */
diff --git a/ospf6d/ospf6_route.h b/ospf6d/ospf6_route.h
index 8dcc877f..d12e0ce0 100644
--- a/ospf6d/ospf6_route.h
+++ b/ospf6d/ospf6_route.h
@@ -279,10 +279,17 @@ extern struct ospf6_route *ospf6_route_match_head (struct prefix *prefix,
extern struct ospf6_route *ospf6_route_match_next (struct prefix *prefix,
struct ospf6_route *route);
+<<<<<<< HEAD:ospf6d/ospf6_route.h
+void ospf6_route_remove_all (struct ospf6_route_table *);
+struct ospf6_route_table *ospf6_route_table_create (int s, int t);
+void ospf6_route_table_delete (struct ospf6_route_table *);
+void ospf6_route_dump (struct ospf6_route_table *table);
+=======
extern void ospf6_route_remove_all (struct ospf6_route_table *);
extern struct ospf6_route_table *ospf6_route_table_create (int s, int t);
extern void ospf6_route_table_delete (struct ospf6_route_table *);
extern void ospf6_route_dump (struct ospf6_route_table *table);
+>>>>>>> 41dc3488cf127a1e23333459a0c316ded67f7ff3:ospf6d/ospf6_route.h
extern void ospf6_route_show (struct vty *vty, struct ospf6_route *route);
diff --git a/ospf6d/ospf6_top.c b/ospf6d/ospf6_top.c
index f59b6f95..569994c0 100644
--- a/ospf6d/ospf6_top.c
+++ b/ospf6d/ospf6_top.c
@@ -562,7 +562,11 @@ ALIAS (show_ipv6_ospf6_route_match,
ROUTE_STR
"Specify IPv6 prefix\n"
"Display routes longer than the specified route\n"
+<<<<<<< HEAD:ospf6d/ospf6_top.c
+ );
+=======
)
+>>>>>>> 41dc3488cf127a1e23333459a0c316ded67f7ff3:ospf6d/ospf6_top.c
DEFUN (show_ipv6_ospf6_route_match_detail,
show_ipv6_ospf6_route_longer_detail_cmd,