summaryrefslogtreecommitdiff
path: root/nest
diff options
context:
space:
mode:
authorMaria Matejka <mq@ucw.cz>2021-11-24 17:30:13 +0100
committerMaria Matejka <mq@jmq.cz>2021-11-24 19:42:52 +0000
commit644e9ca94e2d10ba0c2de45f94523da2414328e3 (patch)
tree51dfbcb9a41b7ea06970b65264f5934960c2e09f /nest
parent9f24fef5e91fb4df301242ede91ee7ac1b46b8a8 (diff)
Directly mapped pages are kept for future use if temporarily not needed
Diffstat (limited to 'nest')
-rw-r--r--nest/cmds.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/nest/cmds.c b/nest/cmds.c
index 18f39eb5..f58923a7 100644
--- a/nest/cmds.c
+++ b/nest/cmds.c
@@ -91,7 +91,12 @@ cmd_show_memory(void)
print_size("Routing tables:", rmemsize(rt_table_pool));
print_size("Route attributes:", rmemsize(rta_pool));
print_size("Protocols:", rmemsize(proto_pool));
- print_size("Total:", rmemsize(&root_pool));
+ size_t total = rmemsize(&root_pool);
+#ifdef HAVE_MMAP
+ print_size("Standby memory:", get_page_size() * pages_kept);
+ total += get_page_size() * pages_kept;
+#endif
+ print_size("Total:", total);
cli_msg(0, "");
}