diff --git a/zebra/rtadv.c b/zebra/rtadv.c index e181b495b8..5841c44b03 100644 --- a/zebra/rtadv.c +++ b/zebra/rtadv.c @@ -50,6 +50,8 @@ extern struct zebra_privs_t zserv_privs; #if defined(HAVE_RTADV) +DEFINE_MTYPE_STATIC(ZEBRA, RTADV_PREFIX, "Router Advertisement Prefix") + #ifdef OPEN_BSD #include #endif diff --git a/zebra/zebra_dplane.c b/zebra/zebra_dplane.c index abe1879c26..f93562b31b 100644 --- a/zebra/zebra_dplane.c +++ b/zebra/zebra_dplane.c @@ -36,8 +36,8 @@ #include "zebra/debug.h" /* Memory type for context blocks */ -DEFINE_MTYPE(ZEBRA, DP_CTX, "Zebra DPlane Ctx") -DEFINE_MTYPE(ZEBRA, DP_PROV, "Zebra DPlane Provider") +DEFINE_MTYPE_STATIC(ZEBRA, DP_CTX, "Zebra DPlane Ctx") +DEFINE_MTYPE_STATIC(ZEBRA, DP_PROV, "Zebra DPlane Provider") #ifndef AOK # define AOK 0 diff --git a/zebra/zebra_memory.c b/zebra/zebra_memory.c index ee041b1c3d..a9c2c5fe58 100644 --- a/zebra/zebra_memory.c +++ b/zebra/zebra_memory.c @@ -26,11 +26,5 @@ #include "zebra_memory.h" DEFINE_MGROUP(ZEBRA, "zebra") -DEFINE_MTYPE(ZEBRA, RTADV_PREFIX, "Router Advertisement Prefix") -DEFINE_MTYPE(ZEBRA, ZEBRA_VRF, "ZEBRA VRF") DEFINE_MTYPE(ZEBRA, RE, "Route Entry") -DEFINE_MTYPE(ZEBRA, RIB_QUEUE, "RIB process work queue") -DEFINE_MTYPE(ZEBRA, STATIC_ROUTE, "Static route") DEFINE_MTYPE(ZEBRA, RIB_DEST, "RIB destination") -DEFINE_MTYPE(ZEBRA, RIB_TABLE_INFO, "RIB table info") -DEFINE_MTYPE(ZEBRA, RNH, "Nexthop tracking object") diff --git a/zebra/zebra_memory.h b/zebra/zebra_memory.h index 667c73b227..e15f972493 100644 --- a/zebra/zebra_memory.h +++ b/zebra/zebra_memory.h @@ -29,17 +29,9 @@ extern "C" { #endif DECLARE_MGROUP(ZEBRA) -DECLARE_MTYPE(RTADV_PREFIX) DECLARE_MTYPE(ZEBRA_NS) -DECLARE_MTYPE(ZEBRA_VRF) DECLARE_MTYPE(RE) -DECLARE_MTYPE(RIB_QUEUE) -DECLARE_MTYPE(STATIC_ROUTE) DECLARE_MTYPE(RIB_DEST) -DECLARE_MTYPE(RIB_TABLE_INFO) -DECLARE_MTYPE(RNH) -DECLARE_MTYPE(DP_CTX) -DECLARE_MTYPE(DP_PROV) #ifdef __cplusplus } diff --git a/zebra/zebra_rnh.c b/zebra/zebra_rnh.c index 0a8dbfdde8..5f397eb8c2 100644 --- a/zebra/zebra_rnh.c +++ b/zebra/zebra_rnh.c @@ -50,6 +50,8 @@ #include "zebra/zebra_memory.h" #include "zebra/zebra_errors.h" +DEFINE_MTYPE_STATIC(ZEBRA, RNH, "Nexthop tracking object") + static void free_state(vrf_id_t vrf_id, struct route_entry *re, struct route_node *rn); static void copy_state(struct rnh *rnh, struct route_entry *re, diff --git a/zebra/zebra_router.c b/zebra/zebra_router.c index 4352d688a1..1e9f9e4ec7 100644 --- a/zebra/zebra_router.c +++ b/zebra/zebra_router.c @@ -32,6 +32,8 @@ #include "zebra_nhg.h" #include "debug.h" +DEFINE_MTYPE_STATIC(ZEBRA, RIB_TABLE_INFO, "RIB table info") + struct zebra_router zrouter = { .multipath_num = MULTIPATH_NUM, .ipv4_multicast_mode = MCAST_NO_CONFIG, diff --git a/zebra/zebra_vrf.c b/zebra/zebra_vrf.c index fdf0cbc693..fcc94a7be9 100644 --- a/zebra/zebra_vrf.c +++ b/zebra/zebra_vrf.c @@ -48,7 +48,8 @@ static void zebra_vrf_table_create(struct zebra_vrf *zvrf, afi_t afi, static void zebra_rnhtable_node_cleanup(struct route_table *table, struct route_node *node); -DEFINE_MTYPE_STATIC(ZEBRA, OTHER_TABLE, "Other Table"); +DEFINE_MTYPE_STATIC(ZEBRA, ZEBRA_VRF, "ZEBRA VRF") +DEFINE_MTYPE_STATIC(ZEBRA, OTHER_TABLE, "Other Table") /* VRF information update. */ static void zebra_vrf_add_update(struct zebra_vrf *zvrf)