aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src/osmo-bsc_mgcp/mgcp_main.c
AgeCommit message (Collapse)AuthorFilesLines
2020-10-18Migrate from BSC_FD_* to OSMO_FD_*Harald Welte1-1/+1
Change-Id: If45434eb0d7da69feb4001e0ac35f0e297bdeef5
2019-08-05Remove undefined param passed to {logging,osmo_stats}_vty_add_cmdsPau Espin Pedrol1-2/+2
Since March 15th 2017, libosmocore API logging_vty_add_cmds() had its parameter removed (c65c5b4ea075ef6cef11fff9442ae0b15c1d6af7). However, definition in C file doesn't contain "(void)", which means number of parameters is undefined and thus compiler doesn't complain. Let's remove parameters from all callers before enforcing "(void)" on it. API osmo_stats_vty_add_cmds never had a param list but has seem problem (no "void"), so some users decided to pass a parameter to it. Change-Id: I7d9d477b983b0d62f01237d90acaa7ce455c3c3d Related: OS#4138
2019-03-20osmo-bsc-mgcp.service: Fix parsing of cmdline option sPau Espin Pedrol1-1/+1
From journald output: /usr/bin/osmo-bsc_mgcp: invalid option -- 's' Change-Id: I995d2f5909640fc007aa39dd6c6b54ff97ee45f7
2018-08-20mgcp: add VTY Option to force-realloc endpointsPhilipp Maier1-0/+2
Currently the force_realloc feature is turnd on and of in a hardcoded way. This patch makes the option available via VTY. Backport from osmo-mgw.git. Change-Id: Ic8740512c5ea0766ff6ceb1c28b9c2b3fe46e75f
2017-02-08vty: remove ignored logging parametersMax1-1/+1
Since ce9fec3e896571835ac5bfd2980d6836f2b29f0d libosmocore ignores parameters to log_vty_command_* functions. Hence parameter of logging_vty_add_cmds() is ignored too. As we depend on much later libosmocore version anyway, we can simplify code somewhat by removing parameters which will be ignored anyway. Change-Id: I62f752fd88f1d8fefa563648f9864c7c31f87991
2016-10-13msgb talloc ctx: initialize in all main() scopesNeels Hofmeyr1-0/+1
Add msgb_talloc_ctx_init() call to many main() functions still lacking a msgb talloc context. Change-Id: Ib0d6751260659cabf18a7ce80680ba2fb4228ea1
2016-09-27log VTY telnet bind only onceNeels Hofmeyr1-2/+0
After libosmocore 55dc2edc89c1a85187ef8aafc09f7d922383231f which outputs 'telnet at <ip> <port>' from telnet_init_dynif(), there's no need to log the telnet VTY bind here anymore. Change-Id: I97a730b28759df1d549a5049f47a3da1c16a3447
2016-02-25enable telnet VTY bind address config for various programsNeels Hofmeyr1-1/+5
Following the 'line vty'/'bind A.B.C.D' command added in libosmocore, use the configured address to set the telnet bind for the VTY line. It is now possible to publish the VTY on a specific local interface (including 0.0.0.0 aka "any"). Implement in all of: osmo-gbproxy osmo-gtphub osmo-sgsn osmo-bsc osmo-bsc_nat osmo-bsc_mgcp osmo-nitb In some of these main programs, move the telnet initialization below the configuration parsing. Historically, this was not a good idea for programs using bsc_init.c (aka bsc_bootstrap_network()), since they expected a gsm_network struct pointer in ((struct telnet_connection*)vty->priv)->priv, so that telnet had to be either initialized or replaced by a dummy struct. In the meantime, the gsm_network struct is not actually looked up in a priv pointer but in the static bsc_vty.c scope (bsc_gsmnet), so this limitation is mere legacy (even though said legacy is still there in an "#if 0" chunk). In the other binaries I have briefly looked at the init sequence dependencies and found no reason to initialize telnet above the config file parsing. In any case, I have tested every single one of abovementioned binaries to verify that they still parse the example config successfully and launch, allowing VTY connections on the configured address(es). I hope this suffices. In all of the above, log VTY address and port. LOGL_INFO is disabled by default in some of the logging scopes, and since it is a single log message right at program launch, I decided for the slightly more aggressive LOGL_NOTICE.
2015-11-02stats/mgcp: Initialize the statistics for MGCP as wellHolger Hans Peter Freyther1-0/+7
There are currently no reate counters but this will hopefully change in the near future.
2015-09-24vty: Change the return type from enum to intHolger Hans Peter Freyther1-1/+1
clang complained that different enums are mixed with the return type and we actually want this to be an int now.
2015-08-0364bit: Fix compiler warnings in regard to 64bitHolger Hans Peter Freyther1-1/+1
vty_interface_layer3.c:584:4: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long unsigned int' [-Wformat=] sizeof(subscr->extension)-1, VTY_NEWLINE);
2015-01-02logging: Only compare the subscr addressHolger Hans Peter Freyther1-3/+0
Move the "logging filter imsi IMSI" into the BTS/NITB code to allow to set the gsm_subscriber and only compare it. This way we simply compare the subscriber address and don't have to care if the subscriber data is still valid.
2014-08-24Use port number #defines for VTY and CTRL portsHarald Welte1-2/+2
.. as defined in libosmocore
2014-07-22mgcp: Change API to remove memory management from the nameHolger Hans Peter Freyther1-1/+1
Jacob pointed out that "free_endp" refers to the memory of the endpoint being freed. What we want is actually a way to release an endpoint (and the resource it allocated) or in the case of the testcase/testapp initialize the data structure correctly. Introduce two names for that.
2014-06-05mgcp: Move transcoding to libmgcpJacob Erlbeck1-1/+1
This patch moves the files relevant to transcoding from src/osmo-bsc_mgcp to src/libmgcp and src/include/openbsc. Makefiles and include directives are being updated accordingly. Sponsored-by: On-Waves ehf
2014-06-05mgcp: Add RTP audio transcodingJacob Erlbeck1-0/+10
This patch implements audio transcoding between the formats GSM, PCMA, L16, and optionally G.729. The feature needs to be enabled by using the autoconf option '--enable-mgcp-transcoding'. In this case mgcp_transcode.c will be compiled and linked to osmo-bsc_mgcp, and the transcoding functions provided will be registered as processing callbacks. If G.729 support is required, libcg729 needs to be installed and '--with-g729' must be passed to ./configure. Ticket: OW#1111 Sponsored-by: On-Waves ehf
2014-01-16mgcp: Send RTP keepalive dummy packets to netJacob Erlbeck1-10/+0
So far, a single dummy packet has been sent immediately after the reception of a MDCX message. There is no dedicated keep alive mechanism (it just worked because the audio from the MS has always been forwarded to the NAT until the 'mgcp: Set output_enabled flags based on the MGCP mode' patch). This patch adds explicit, timer based keep alive handling that can be enable per trunk. A VTY command 'rtp keep-alive' command is added for configuration which can be used to set the interval in seconds, to send a single packet after the reception of a CRCX/MDCX when RTP data from the net is expected ('once'), or to disable the feature completely ('no rtp keep-alive'). In 'send-recv' connections, only the initial packet is sent if enabled (even when an interval has been configured). The default is 'once'. Note that this removes the mgcp_change_cb() from mgcp_main.c. Sponsored-by: On-Waves ehf
2013-08-27libmgcp: add enum mgcp_rolePablo Neira Ayuso1-1/+1
This enum indicates if the mgcp is running on the BSC or the BSC-NAT.
2012-09-20mgcp: Add the disable color option to the mgcp binaryHolger Hans Peter Freyther1-0/+5
2012-03-16misc: Use other size modifiers to fix compiler warningsHolger Hans Peter Freyther1-2/+2
control_if.c:521:2: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘uint64_t’ [-Wformat] osmo_bsc_bssap.c:473:3: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 7 has type ‘unsigned int’ [-Wformat] mgcp_main.c:162:4: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 4 has type ‘unsigned int’ [-Wformatt]
2012-03-16mgcp: make sure all command line options are documentedHarald Welte1-0/+2
Signed-off-by: Holger Hans Peter Freyther <zecke@selfish.org>
2012-01-27bsc_mgcp: optionally connect the MGCP socket to the MGWHarald Welte1-0/+11
This allows the use of the existing "call-agent ip A.B.C.D" command in libmgcp in order to set a default destination address of the call agent. This is required as a pre-condition for certain call agents (like the zynetix MSC) that require a RSIP from the BSC to the MSC as the initial MGCP message.
2011-09-06fix fprintf format specifiers in osmo-bsc_mgcpAlexander Huemer1-2/+2
2011-07-19mgcp: Implement RSIP based on a trunk levelHolger Hans Peter Freyther1-6/+10
Implement the RSIP spec extension to work on the specified trunk instead of hardcoding it to the virtual trunk.
2011-07-18misc: Remove the osmocom/core/process.h includeHolger Hans Peter Freyther1-1/+0
The osmo_daemonize moved from process.h to application.h (that is already included), remove the process.h include.
2011-05-12misc: Use the osmo_init code for signals and loggingHolger Hans Peter Freyther1-9/+9
Use the libosmocore code to ignore certain signals by default (e.g. SIGHUP, SIGPIPE) and use the new code to create a default stderr logging target and initialize it properly.
2011-05-06src: use namespace prefix osmo_fd* and osmo_select*Pablo Neira Ayuso1-3/+3
Summary of changes: s/struct bsc_fd/struct osmo_fd/g s/bsc_register_fd/osmo_fd_register/g s/bsc_unregister_fd/osmo_fd_unregister/g s/bsc_select_main/osmo_select_main/g
2011-03-23src: use new library libosmogsm and new path to headers in libosmocorePablo Neira Ayuso1-4/+4
libosmogsm is a new library that is distributed in the libosmocore. Now, openbsc depends on it. This patch gets openbsc with this change. This patch also rewrites all include path to the new osmocom/[gsm|core] Signed-off-by: Pablo Neira Ayuso <pablo@gnumonks.org>
2011-03-19bsc: change bsc_vty_init to take logging categories as parameterPablo Neira Ayuso1-1/+1
This change is required to finish the integration of the VTY and the per-application logging categories that provides: "vty: integration with logging framework" in libosmocore. It has been tested with osmo-nitb. The other just compiled tested.
2011-03-03Rename bsc_nat -> osmo-bsc_nat and bsc_mgcp -> osmo-bsc_mgcpHarald Welte1-0/+283
This now enforces a unique structure: All of our main daemon programs start with an "osmo-" prefix.