From 58ec07d580d1e3e93908e6383b5b1f969eba39cc Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther Date: Wed, 11 Nov 2009 13:41:56 +0100 Subject: [bsc] Add BSC specific config option... currently and empty show is implemented In the future this should give a list of SCCP connections and their allocated radio resources/users... --- openbsc/src/Makefile.am | 2 +- openbsc/src/bsc_msc_ip.c | 5 ----- openbsc/src/vty_interface_bsc.c | 48 +++++++++++++++++++++++++++++++++++++++++ 3 files changed, 49 insertions(+), 6 deletions(-) create mode 100644 openbsc/src/vty_interface_bsc.c (limited to 'openbsc') diff --git a/openbsc/src/Makefile.am b/openbsc/src/Makefile.am index e6c5fb743..8bcb031ab 100644 --- a/openbsc/src/Makefile.am +++ b/openbsc/src/Makefile.am @@ -24,7 +24,7 @@ libsccp_a_SOURCES = sccp/sccp.c bsc_hack_SOURCES = bsc_hack.c bsc_init.c vty_interface.c vty_interface_layer3.c bsc_hack_LDADD = libmsc.a libbsc.a libmsc.a libvty.a -ldl -ldbi $(LIBCRYPT) -bsc_msc_ip_SOURCES = bssap.c bsc_msc_ip.c bsc_init.c vty_interface.c +bsc_msc_ip_SOURCES = bssap.c bsc_msc_ip.c bsc_init.c vty_interface.c vty_interface_bsc.c bsc_msc_ip_LDADD = libbsc.a libvty.a libsccp.a bs11_config_SOURCES = bs11_config.c abis_nm.c gsm_data.c msgb.c debug.c \ diff --git a/openbsc/src/bsc_msc_ip.c b/openbsc/src/bsc_msc_ip.c index 7e810cf66..9153af83f 100644 --- a/openbsc/src/bsc_msc_ip.c +++ b/openbsc/src/bsc_msc_ip.c @@ -110,11 +110,6 @@ struct gsm_subscriber *find_subscriber(u_int8_t type, const char *mi_string) -/* BSC -> MSC hooks */ -void bsc_vty_init_extra(void) -{ -} - /* SCCP handling */ void msc_outgoing_sccp_data(struct sccp_connection *conn, struct msgb *msg, unsigned int len) { diff --git a/openbsc/src/vty_interface_bsc.c b/openbsc/src/vty_interface_bsc.c new file mode 100644 index 000000000..346ed007f --- /dev/null +++ b/openbsc/src/vty_interface_bsc.c @@ -0,0 +1,48 @@ +/* OpenBSC interface to quagga VTY - BSC options */ +/* (C) 2009 by Harald Welte + * All Rights Reserved + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + * + */ + +#include +#include +#include + +#include +#include +#include + +#include + +static struct gsmnet *gsmnet = NULL; + +DEFUN(show_bsc, show_bsc_cmd, "show bsc", + SHOW_STR "Display information about the BSC\n") +{ + vty_out(vty, "BSC... not implemented yet%s", VTY_NEWLINE); + return CMD_SUCCESS; +} + +int bsc_vty_init_extra(struct gsm_network *net) +{ + gsmnet = net; + + /* get runtime information */ + install_element(VIEW_NODE, &show_bsc_cmd); + + return 0; +} -- cgit v1.2.3