From 22dabe1556915e92f98c56a16b9627cbed41762b Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Mon, 11 Mar 2024 13:04:09 -0400 Subject: [PATCH 1/5] lib: Remove unused memory types These are never used. So let's remove them. Signed-off-by: Donald Sharp --- lib/netns_other.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/lib/netns_other.c b/lib/netns_other.c index 30218409dd..545a962b55 100644 --- a/lib/netns_other.c +++ b/lib/netns_other.c @@ -13,10 +13,6 @@ #include "log.h" #include "memory.h" -DEFINE_MTYPE_STATIC(LIB, NS, "NetNS Context"); -DEFINE_MTYPE_STATIC(LIB, NS_NAME, "NetNS Name"); - - static inline int ns_compare(const struct ns *ns, const struct ns *ns2); RB_GENERATE(ns_head, ns, entry, ns_compare) @@ -39,7 +35,6 @@ void ns_init_management(ns_id_t ns_id) { } - /* * NS utilities */ From 6b2554b94a43dcd531f63d3203b31a25c682d423 Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Mon, 11 Mar 2024 16:05:56 -0400 Subject: [PATCH 2/5] zebra: Clean up leaked linklist data structure on shutdown Signed-off-by: Donald Sharp --- zebra/main.c | 1 + 1 file changed, 1 insertion(+) diff --git a/zebra/main.c b/zebra/main.c index 606ecc7279..27e98ed999 100644 --- a/zebra/main.c +++ b/zebra/main.c @@ -203,6 +203,7 @@ static void sigint(void) rib_update_finish(); list_delete(&zrouter.client_list); + list_delete(&zrouter.stale_client_list); /* Indicate that all new dplane work has been enqueued. When that * work is complete, the dataplane will enqueue an event From beb2ebadb3a2a8984c7d87e3e40cced342d3883a Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Mon, 11 Mar 2024 16:07:14 -0400 Subject: [PATCH 3/5] lib: Remove unused mtypes from affinitymap.c Signed-off-by: Donald Sharp --- lib/affinitymap.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/affinitymap.c b/lib/affinitymap.c index e53d54a443..6ff8e83f91 100644 --- a/lib/affinitymap.c +++ b/lib/affinitymap.c @@ -41,8 +41,6 @@ #include "jhash.h" DEFINE_MTYPE_STATIC(LIB, AFFINITY_MAP, "Affinity map"); -DEFINE_MTYPE(LIB, AFFINITY_MAP_NAME, "Affinity map name"); -DEFINE_MTYPE_STATIC(LIB, AFFINITY_MAP_INDEX, "Affinity map index"); DEFINE_QOBJ_TYPE(affinity_maps); DEFINE_QOBJ_TYPE(affinity_map); From ad1722cedd46debadaee9efd398f08af2be90ea9 Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Mon, 11 Mar 2024 16:52:21 -0400 Subject: [PATCH 4/5] lib: Remove unused MTYPE_MSG_NATIVE_MSG Signed-off-by: Donald Sharp --- lib/mgmt_msg_native.c | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/mgmt_msg_native.c b/lib/mgmt_msg_native.c index d27c5d3a29..98b7da45ce 100644 --- a/lib/mgmt_msg_native.c +++ b/lib/mgmt_msg_native.c @@ -9,7 +9,6 @@ #include "mgmt_msg_native.h" DEFINE_MGROUP(MSG_NATIVE, "Native message allocations"); -DEFINE_MTYPE(MSG_NATIVE, MSG_NATIVE_MSG, "native mgmt msg"); DEFINE_MTYPE(MSG_NATIVE, MSG_NATIVE_ERROR, "native error msg"); DEFINE_MTYPE(MSG_NATIVE, MSG_NATIVE_GET_TREE, "native get tree msg"); DEFINE_MTYPE(MSG_NATIVE, MSG_NATIVE_TREE_DATA, "native tree data msg"); From a67e159e3b741f26d104342cdeb4c9ed9a06f47e Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Mon, 11 Mar 2024 16:52:51 -0400 Subject: [PATCH 5/5] lib: Remove MTYPE_SYSREPO it is not used Signed-off-by: Donald Sharp --- lib/northbound_sysrepo.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/northbound_sysrepo.c b/lib/northbound_sysrepo.c index 4942d66850..640334926d 100644 --- a/lib/northbound_sysrepo.c +++ b/lib/northbound_sysrepo.c @@ -19,8 +19,6 @@ #include #include -DEFINE_MTYPE_STATIC(LIB, SYSREPO, "Sysrepo module"); - static struct debug nb_dbg_client_sysrepo = {0, "Northbound client: Sysrepo"}; static struct event_loop *master;