Commit Graph

3722 Commits

Author SHA1 Message Date
Holger Hans Peter Freyther bea9a1206b rtp: Add lua script to split a trace by SSRC/streams
This can be used to replay RTP streams with more or less the
same timing as the original one.
2012-05-18 10:48:02 +02:00
Holger Hans Peter Freyther 2c9ea91317 nitb: Enable the external RF Control interface for the nitb application
Add argument handling for the nitb application and create the RF
ctrl interface for being able to control the TRX using an external
socket.
2012-05-17 09:38:24 +02:00
Holger Hans Peter Freyther 41a93dc2f0 bsc: Move the osmo_bsc_rf file into the libbsc code and rename
The nitb will provide the RF interface as well.
2012-05-17 09:37:22 +02:00
Holger Hans Peter Freyther a8090d54d6 mgcp: Make it possible to drop RTCP packets coming from the BTS/Net
The ip.access nanoBTS appears to send quite broken NTP timestamps in
the RTCP messages might confuse equipment that uses the sender report
of the BTS. Make it easy to experiment by adding an option to drop RTCP.
2012-05-11 13:09:30 +02:00
Holger Hans Peter Freyther c50e04a409 bsc vty: Provide a show mscs command to show the state of each MSC 2012-05-11 12:41:13 +02:00
Sylvain Munaut 5e80cc4adc libmsc/db: Fix max value of ainfo->a3a8_ki_len in db_get_authinfo_for_subscr
Thanks to Robert Ingr for pointing this out

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2012-05-07 22:09:15 +02:00
Harald Welte fda74ee055 RSL add debug statements when sending RSL EST REQ and RSL REL REQ. 2012-04-26 19:43:36 +02:00
Harald Welte 6e8dcf304c bsc_api: Fix wrong order of log category and level arguments 2012-04-26 19:35:58 +02:00
Harald Welte 0e9311df40 bsc_api: log RR STATUS from MS as NOTICE, not DEBUG level 2012-04-26 19:35:27 +02:00
Harald Welte 46cb8514a5 add loopback flag to lchan (for osmo-bts) 2012-04-19 23:14:28 +02:00
Holger Hans Peter Freyther afa0ad1723 lchan: Fix the name of the SACCH in the variable names
Call the channel by the right name.
2012-04-18 18:58:36 +02:00
Holger Hans Peter Freyther cc7b22a53b bsc_api: Send RR Release and de-activate the SACCH on error
In case the connection should not be created/accepted release
the channel by sending a RR Release and de-activating the
SACCH. Phones should deal better with that behavior.
2012-04-17 21:54:24 +02:00
Holger Hans Peter Freyther ec2542627e mgcp: Catch up with the renaming of the MGCP GW binary 2012-04-13 18:06:26 +02:00
Holger Hans Peter Freyther a5dcdd9a9a bsc: Allow to run a mixed TCH/H, TCH/F configuration
In case the call handling starts on a TCH/H switch to a TCH/F
if fullrate is requested. Add a method that is used to determine
if the mode and current channel are compatible with each other.
2012-04-11 20:15:54 +02:00
Harald Welte 5d52c97cff add 'ciph_state' member to BTS-side lchan definition 2012-04-08 20:23:28 +02:00
Harald Welte 9c3dc90d16 introduce HAVE_TM_GMTOFF_IN_TM
Not all architectures have the tm.tm_gmtoff member.  This fixes cygwin
builds.
2012-04-08 16:59:24 +02:00
Harald Welte a334c296e0 make sure we still build on systems that don't have IPPROTO_GRE 2012-04-08 15:56:00 +02:00
Holger Hans Peter Freyther 09db1a44bc nat: Add another test case for TP-SRR clearing and number rewrite 2012-03-26 16:22:08 +02:00
Holger Hans Peter Freyther 2f2be578cb misc: Use other size modifiers to fix compiler warnings
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-16 12:18:39 +01:00
Holger Hans Peter Freyther 20fea24515 bsc: Prepare to have multiple MSC connections
We now have a list of MSCs but in the code we will
try to access the MSC with the nr 0.
2012-03-16 11:56:21 +01:00
Holger Hans Peter Freyther 44e5dad3e2 bsc: Use the right connection for outgoing packets
This is needed for simple UDT messages where we do not have
a SCCP connection.
2012-03-16 11:56:10 +01:00
Holger Hans Peter Freyther abd668a68d bsc: Move more things to use osmo_msc_data* directly 2012-03-16 11:56:10 +01:00
Holger Hans Peter Freyther f936fb4086 bsc: Move the bsc_filter to use the osmo_bsc_sccp_con 2012-03-16 11:56:10 +01:00
Holger Hans Peter Freyther 4cdb050d13 bsc: Move away from ->bsc.msc to use the selected MSC
For multiple MSCs we should only have one place where the MSC
is selected and the rest will extract it from somewhere.
2012-03-16 11:56:10 +01:00
Holger Hans Peter Freyther f31a4a4810 bsc: Stop using net->bsc->msc and get the right msc from somewhere else 2012-03-16 11:56:10 +01:00
Holger Hans Peter Freyther 8ec4952557 bsc: Create a osmo_bsc_data and embed osmo_msc_data
We want to have multiple MSCs but we also have some data
that is only present on a per BSC basis. Right now the
MSC data is not allocated with talloc, so we have some
change in the talloc contexts.
2012-03-16 11:56:10 +01:00
Holger Hans Peter Freyther 4d31900e2d bsc: Address warnings about implicit declarations
osmo_bsc_main.c: In function ‘main’:
osmo_bsc_main.c:398:2: warning: implicit declaration of function ‘bts_init’ [-Wimplicit-function-declaration]
osmo_bsc_main.c:399:2: warning: implicit declaration of function ‘libosmo_abis_init’ [-Wimplicit-function-declaration]
osmo_bsc_main.c:418:2: warning: implicit declaration of function ‘bsc_bootstrap_network’ [-Wimplicit-function-declaration]
2012-03-16 11:56:10 +01:00
Holger Hans Peter Freyther dc3389f9c8 bsc: Fix compiler warning about wrong return and unused variable
osmo_bsc_api.c: In function ‘bsc_cm_update’:
osmo_bsc_api.c:195:2: warning: ‘return’ with a value, in function returning void [enabled by default]
osmo_bsc_api.c:193:28: warning: unused variable ‘sccp’ [-Wunused-variable]
2012-03-16 11:56:10 +01:00
Harald Welte ae1997248c mgcp: implement a more tolerant parser based on strtok_r()
Instead of building complex manual byte-wise parsers, we simply use two
strtok_r loops:  one iterating over all the lines, the next one
iterating over the invididual space-separated elements in the first line.

The benefit is that we now accept \r, \n or \r\n, or any multiple of
them as line ending.  This works around incompliant MGCP implementations
like that of Zynetix MSC.

Addition: mgcp_analyze_header returns 0 when all out parameters have
been set.

Signed-off-by: Holger Hans Peter Freyther <zecke@selfish.org>
2012-03-16 10:24:18 +01:00
Harald Welte 6b36b90f75 mgcp: make sure all command line options are documented
Signed-off-by: Holger Hans Peter Freyther <zecke@selfish.org>
2012-03-16 10:21:34 +01:00
Harald Welte ec7683f3b0 mgcp: consistently name bsc_mgcp osmo-bsc_mgcp
Signed-off-by: Holger Hans Peter Freyther <zecke@selfish.org>
2012-03-16 10:21:34 +01:00
Holger Hans Peter Freyther d77023b1c2 mgcp_test: Add wrong messages as input and check what happens
Test parsing some invalid messages and see if we start to crash.
2012-03-16 10:21:29 +01:00
Holger Hans Peter Freyther 5563e6c268 mgcp_test: Rename method as it now operates on an array of messages
This code was cleaned up, catch up and rename the method.
2012-03-16 10:06:39 +01:00
Holger Hans Peter Freyther 3e60348b3b misc: Deal with smatch warnings about the bitfields
Use unsigned ints for the bitfield.
2012-03-02 14:14:33 +01:00
Holger Hans Peter Freyther a8ddb08e05 misc: Use msgb_free for freeing the messages 2012-03-01 20:30:32 +01:00
Andreas Eversberg c50543b18a Improved generation of SYSTEM INFORMATIONs 2* and 5* for neighbour bands
In addition to SI 2 and SI 5, the SI 2ter and 2bis is generated, if
neighbour cells in other bands exist. Also it is indicated in the rest
octets of SI3, that SI 2ter is used. If no neighbour cell in a different
band exists, the SI 2ter and SI 5ter is omitted.

A special case is P-GSM range (channels 1-124). To be compatible with
older phones, SI 2bis and SI 5bis is used. If the BCCH lays inside the
P-GSM band, only neighbour cells of the P-GSM range are included in
SI 2 and SI 5. If neighbour cells exist in the same band (900), but lay
outside the P-GSM range, the SI 2bis and SI 5bis is used to extend the
list of neighbour cells. The extension is also indicated in SI 2 and
SI 5. If the BCCH lays inside the P-GSM range, but no neighbour cell
exists in the same band outside the P-GSM range, the SI 2bis ans SI 5bis
are omitted.
2012-03-01 08:29:56 +01:00
Tobias Engel c33d7d71cb Make sure USSD code only responds *#100# for retrieving own number
strstr() was used with wrong argument order, causing it to always match,
and causing an invalid response to a variety of different SS and USSD
requests.

This has apparently caused havoc among a number of HTC phones which
issue SS requests without user interaction upon boot, and then trip over
our inappropriate response.
2012-02-24 22:23:17 +01:00
Harald Welte 2935034b5e fix generation of frequency list (E-GSM vs. P-GSM 900) 2012-02-17 15:59:25 +01:00
Holger Hans Peter Freyther c8ddf73c8f bts_ipaccess_nanobts.c: Remove unused variable.
This must have been obsoleted by the move to libosmo-abis.

GCC warning:
bts_ipaccess_nanobts.c: In function ‘ipaccess_drop_oml’:
bts_ipaccess_nanobts.c:509:21: warning: variable ‘line’ set but not used [-Wunused-but-set-variable]
2012-02-03 20:31:05 +01:00
Holger Hans Peter Freyther 863dc9bc84 abis_rsl.c: Remove unused variable net.
The old BSC code had code to override the payload type, this has
been removed, remove the variable accessing it.

GCC warning:
abis_rsl.c: In function ‘ipa_rtp_pt_for_lchan’:
abis_rsl.c:1590:22: warning: unused variable ‘net’ [-Wunused-variable]
2012-02-03 20:29:00 +01:00
Holger Hans Peter Freyther 54fa2c7eab abis_rsl: The rach information was not used, introduce a signal
Introduce a SS_CCCH for the paging and the rach load. The paging
code could now start using the signal.

GCC warning:
abis_rsl.c: In function ‘rsl_rx_ccch_load’:
abis_rsl.c:1371:11: warning: variable ‘rach_access_count’ set but not used [-Wunused-but-set-variable]
abis_rsl.c:1370:11: warning: variable ‘rach_busy_count’ set but not used [-Wunused-but-set-variable]
abis_rsl.c:1369:11: warning: variable ‘rach_slot_count’ set but not used [-Wunused-but-set-variable]
2012-02-03 20:26:25 +01:00
Holger Hans Peter Freyther c6d0a17100 abis_rsl.c: Remove unused variable ts_number
GCC warning:
abis_rsl.c: In function ‘rsl_rx_chan_rqd’:
abis_rsl.c:1245:10: warning: variable ‘ts_number’ set but not used [-Wunused-but-set-variable]
2012-02-03 20:10:13 +01:00
Holger Hans Peter Freyther 06b04f851b abis_om2000.c: Remove unused variable to_trx_oml.
GCC warning:
abis_om2000.c: In function ‘abis_om2k_sendmsg’:
abis_om2000.c:804:6: warning: unused variable ‘to_trx_oml’ [-Wunused-variable]
2012-02-03 20:03:06 +01:00
Holger Hans Peter Freyther 37e6523c0f vty: Remove two unimplemented OML functions
attribute get|set <0-255> (.HEX) was never implemented and the
output about the unused attributes clutter the build output, remove
them.

GCC warning:
abis_nm_vty.c: In function ‘oml_attrib_get’:
abis_nm_vty.c:141:25: warning: unused variable ‘oms’ [-Wunused-variable]
abis_nm_vty.c: In function ‘oml_attrib_set’:
abis_nm_vty.c:152:25: warning: unused variable ‘oms’ [-Wunused-variable]
2012-02-03 20:03:02 +01:00
Holger Hans Peter Freyther dae5307a57 misc: abis_nm.c Use the result of ret.
Use LOGP(DNM, LOGL_ERROR, ...); for errors in the
abis_nm_rx_sw_act_req method.

GCC warning:
abis_nm.c: In function ‘abis_nm_rx_sw_act_req’:
abis_nm.c:412:6: warning: variable ‘ret’ set but not used [-Wunused-but-set-variable]
2012-02-03 20:03:00 +01:00
Holger Hans Peter Freyther f02bb200c5 misc: gsm_data.c address compiler warning
Assume nothing special needs to be done for the Nokia
*site hardware.

GCC warning:
gsm_data.c: In function ‘gsm_set_bts_type’:
gsm_data.c:342:2: warning: enumeration value ‘GSM_BTS_TYPE_NOKIA_SITE’ not handled in switch [-Wswitch]
2012-02-03 20:02:54 +01:00
Harald Welte 1fe73a19cd ARFCNs are in the range of 0..1023, not 0..1024
I'm sure I read somewhere that it actually was 0..1024, as I kept
wondering how stupid it was to use 10bit+1.  However, that source
was incorrect, as GSM TS 05.05 quite clearly states 0..1023
2012-01-29 13:24:12 +01:00
Harald Welte 94b499c9bd mgcp: add missing prototypes for send_mgcp_reset_* 2012-01-27 00:46:49 +01:00
Harald Welte 78b5586e25 osmo-bsc: Remove hard-coded check for codec preferecne in ASS CMD
When we get an assignment command from the MSC, we no longer have to
check statically for certain codecs, as we have a vty-configured list of
codecs that is checked just below.
2012-01-27 00:43:06 +01:00
Harald Welte 6a85705d51 MGCP: Add VTY commands to reset (RSIP) one or all endpoints 2012-01-27 00:41:39 +01:00