[MERGED] osmocom-bb[master]: mobile: register the talloc context introspection command

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Vadim Yanitskiy gerrit-no-reply at lists.osmocom.org
Mon Oct 30 16:38:33 UTC 2017


Vadim Yanitskiy has submitted this change and it was merged.

Change subject: mobile: register the talloc context introspection command
......................................................................


mobile: register the talloc context introspection command

This change registers the command, which is now implemented in
libosmocore since the 463deef8c209dd7eb023ac70bf41fa9893ad35ed
and allows to introspect mobile application's talloc context
directly from the VTY interface.

Change-Id: I979d64ae63d385f4fd082a4e3f981cbf5ab28338
---
M src/host/layer23/configure.ac
M src/host/layer23/src/mobile/app_mobile.c
M src/host/layer23/src/mobile/vty_interface.c
3 files changed, 5 insertions(+), 1 deletion(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/host/layer23/configure.ac b/src/host/layer23/configure.ac
index 102d234..de26d23 100644
--- a/src/host/layer23/configure.ac
+++ b/src/host/layer23/configure.ac
@@ -13,7 +13,7 @@
 
 dnl checks for libraries
 PKG_CHECK_MODULES(LIBOSMOCORE, libosmocore)
-PKG_CHECK_MODULES(LIBOSMOVTY, libosmovty)
+PKG_CHECK_MODULES(LIBOSMOVTY, libosmovty >= 0.10.0)
 PKG_CHECK_MODULES(LIBOSMOGSM, libosmogsm)
 PKG_CHECK_MODULES(LIBOSMOCODEC, libosmocodec)
 AC_CHECK_LIB(gps, gps_waiting, LIBGPS_CFLAGS=" -D_HAVE_GPSD" LIBGPS_LIBS=" -lgps ",,)
diff --git a/src/host/layer23/src/mobile/app_mobile.c b/src/host/layer23/src/mobile/app_mobile.c
index ecf9820..9dbae7c 100644
--- a/src/host/layer23/src/mobile/app_mobile.c
+++ b/src/host/layer23/src/mobile/app_mobile.c
@@ -396,6 +396,7 @@
 
 	osmo_gps_init();
 
+	vty_info.tall_ctx = l23_ctx;
 	vty_init(&vty_info);
 	ms_vty_init();
 	dummy_conn.priv = NULL;
diff --git a/src/host/layer23/src/mobile/vty_interface.c b/src/host/layer23/src/mobile/vty_interface.c
index 0f321ba..2ad95d0 100644
--- a/src/host/layer23/src/mobile/vty_interface.c
+++ b/src/host/layer23/src/mobile/vty_interface.c
@@ -2951,6 +2951,9 @@
 	install_element(MS_NODE, &cfg_ms_shutdown_force_cmd);
 	install_element(MS_NODE, &cfg_ms_no_shutdown_cmd);
 
+	/* Register the talloc context introspection command */
+	osmo_talloc_vty_add_cmds();
+
 	return 0;
 }
 

-- 
To view, visit https://gerrit.osmocom.org/4566
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I979d64ae63d385f4fd082a4e3f981cbf5ab28338
Gerrit-PatchSet: 7
Gerrit-Project: osmocom-bb
Gerrit-Branch: master
Gerrit-Owner: Vadim Yanitskiy <axilirator at gmail.com>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Vadim Yanitskiy <axilirator at gmail.com>



More information about the gerrit-log mailing list