Commit Graph

2867 Commits

Author SHA1 Message Date
Holger Hans Peter Freyther 46caa3048d bsc_api: Provide the link_id in the dtap callback. 2010-11-15 20:06:46 +01:00
Holger Hans Peter Freyther b094171c9f bsc_api: Add needed parameters to the assignment complete callback
Provide the chosen channel and more information in the assignment
complete method.
2010-11-15 20:06:46 +01:00
Holger Hans Peter Freyther e1996f013c bsc_api: The cipher mode is not a message on the air interface
The cipher mode reject will be send in case the BSC is not
able to support the requested cipher. So this reject can be
handled by however attempts to enable ciphering.
2010-11-15 20:06:46 +01:00
Holger Hans Peter Freyther 6c199e7d99 bsc_api: Look into the msg and call the right API functions
For certain messages we will need to call other GSM0808 functions. To
keep the bsc_hack working we will try to send this through the normal
messages first and then fallback to dtap if no handler is registered.

The gsm_04_08.c code is not forced to handle the IPA activation
and channel modify ack anymore. This is done transparently by the
BSC API now.
2010-11-15 20:06:46 +01:00
Holger Hans Peter Freyther fce9307553 bsc_api: Change the cause to a uint8_t for now
The RR Cause can only be one byte. Change from uint16_t to uint8_t for that.
2010-11-15 20:06:46 +01:00
Holger Hans Peter Freyther 05c68841a8 bsc_api: Fix a use after free error in the Clear Request path
The implementation of bsc_hack would call subscr_con_free before
the BSC API has had the chance to call gsm0808_clear to try to
release other channels. Fix that by adding a return value.
2010-11-15 20:06:46 +01:00
Holger Hans Peter Freyther 85334f1309 paging: Move the paging data into the paging.h 2010-11-15 20:06:45 +01:00
Holger Hans Peter Freyther 8dfd241bc6 subscr: Add method to find an active subscriber
This is used by the paging code of the osmo_bsc. When we get
a paging response there should be an active subscriber with
the TMSI or IMSI and we can stop paging. There is no need to
allocate a new subscriber.
2010-11-15 20:06:45 +01:00
Holger Hans Peter Freyther d740b688dc subscr: Add the subscr_get_or_create from the on-waves/bsc-master branch
Create a subscriber based on a known IMSI, search the list of
active subscribers if there is already someone like this.
2010-11-15 20:06:45 +01:00
Holger Hans Peter Freyther 928ca743db subscr: Move the TMSI reserved into the gsm_data
Put it into the gsm_data.h to avoid requiring MSC code
in the BSC code paths.
2010-11-15 20:06:45 +01:00
Holger Hans Peter Freyther 8cc59036e6 rsl: Allow to hardcode the RTP Payload
In case of a inflexible network it is better to hardcode
the rtp payload to a given type. E.g. when using AMR5.9 on
a TCH/F and TCH/H having the same payload is helpful. For
now this will be only used by the osmo-bsc.
2010-11-15 20:06:45 +01:00
Holger Hans Peter Freyther ecd94a4b45 misc: Introduce a --enable-coverage mode to build with gprof coverage
This adds a test coverage build. One can use gcov and lcov on the
resulting data afterwards to see which code paths were executed and
which were not.
2010-11-15 20:06:45 +01:00
Holger Hans Peter Freyther 0b369c582b e1_input: Fix compiler warning by using offsetof
Use the offsetof/__builtin_offsetof to determine the
offset of a variable inside a structure instead of going
via a NULL pointer and taking the address.

This fixes:
warning: variably modified ‘dummyhalen_offset’ at file scope
2010-11-09 23:11:29 +01:00
Andreas Eversberg 5652cfc0e8 mark andreas@eversberg.eu as 'extern' for lcr 2010-11-09 13:39:43 +01:00
Holger Hans Peter Freyther 1406977e7e nat: Verify that the endpoint from the assignment command exists
Make sure that the MSC endpoint exists on the NAT, otherwise
we end up trying to free this endpoint when the SCCP connection
is taken down and will corrupt our memory. This issue started
to pop up as we have reduced the number of endpoints to 60
to allow transcoding on them.
2010-11-04 17:14:41 +01:00
Holger Hans Peter Freyther f3d1ae7072 bsc: Add simple SCCP binding code. 2010-11-03 16:40:03 +01:00
Holger Hans Peter Freyther 0425c38feb bsc: Fix crash when making a MSC connection.
Use the right types that are passed as void..
2010-11-03 14:46:56 +01:00
Holger Hans Peter Freyther 7bf66c5a6e bsc: Add the audio codec list command to list preferred codecs 2010-11-03 13:56:27 +01:00
Holger Hans Peter Freyther fe16622bf5 bsc: Add the rtp-base command to osmo-bsc 2010-11-03 13:56:26 +01:00
Holger Hans Peter Freyther 45f9e69ac5 bsc: Add the ip.access rtp-payload command known from bsc_msc_ip 2010-11-03 13:56:26 +01:00
Holger Hans Peter Freyther 4de1116356 bsc: Readd the core network code setting
This will instruct the BSC to patch messages and replace
the old network code with the new one.
2010-11-03 13:56:26 +01:00
Holger Hans Peter Freyther 5b848f37cf bsc: Fix the name of the local vty variable. 2010-11-03 13:11:14 +01:00
Holger Hans Peter Freyther 79dcd719e0 Merge branch 'zecke/mgcp-transcoder' 2010-11-02 19:41:42 +01:00
Holger Hans Peter Freyther 8b19dee437 mgcp: Send data from the network to the transcoder too
We now should be able to transcode in both directions.
2010-11-02 19:08:09 +01:00
Holger Hans Peter Freyther 5f2cd84281 mgcp: Use the calculated remote port from the mgcp_rtp_end 2010-11-02 19:08:09 +01:00
Holger Hans Peter Freyther 3f29cc8303 mgcp: Make the transcoding forwarding work for BTS/NET
Share the implementation for the transcoded packets and
forward them to the network and the bts.
2010-11-02 19:08:09 +01:00
Holger Hans Peter Freyther 386a940736 mgcp: Refactor the network binding routines
Create another wrapper function that takes most of
the arguments from the caller.
2010-11-02 19:08:09 +01:00
Holger Hans Peter Freyther bd7b3c5e45 mgcp: Introduce trans_bts and send BTS packets from this port
Introduce the trans_bts. Right now only a port is allocated
and the packets from the BTS are sent from this socket.
2010-11-02 19:08:09 +01:00
Holger Hans Peter Freyther e97155a2af mgcp: Keep the local_port like it was set on allocation
Do not reset statically allocated local_port. The port
might be different to the calculation of endpoint number
and base port. This might be the case for the coming remote
transcoding.
2010-11-02 19:06:13 +01:00
Holger Hans Peter Freyther 2126233590 mgcp: Rename transcoder_end to trans_net
Packets arriving for trans_net will be send out to the
networking. We will introduce a trans_bts in a second.
2010-11-01 21:15:55 +01:00
Holger Hans Peter Freyther 88b597e21c mgcp: Allow to disable the transcoder in a running system. 2010-11-01 21:15:55 +01:00
Holger Hans Peter Freyther b54048fe25 mgcp: Make transcoding a per Endpoint configuration
This allows to switch off transcoding on the fly, or only enable
it for certain vessels with known problems.
2010-11-01 21:15:55 +01:00
Holger Hans Peter Freyther fbca4ea117 mgcp: Fix the indetion of this code. it should use tabs 2010-11-01 21:15:55 +01:00
Holger Hans Peter Freyther 43eb1a3db0 nat: Send a clear command in case of connection releases.
This should help the BS+ to release RF channels earlier.
2010-10-29 17:05:28 +02:00
Holger Hans Peter Freyther 74779c68f7 nat: Add test case for matching phone numbers
Add the test case for matching '*' and for not matching at all
2010-10-28 15:27:00 +02:00
Holger Hans Peter Freyther d414c06fd9 nat: Fix a thinko in allowing '*' as a wildcard...
We need to match everything BUT the wildcard and then
do the normal strcmp...
2010-10-28 13:51:28 +02:00
Holger Hans Peter Freyther 732d9c19bf Merge branch 'zecke/number-rewrite' 2010-10-27 12:41:19 +02:00
Holger Hans Peter Freyther c4fd45ccf1 Merge branch 'zecke/ussd-side-channel' 2010-10-27 12:37:42 +02:00
Holger Hans Peter Freyther afa5a394ab Require 0.1.27 for the new gsm0808 methods 2010-10-27 12:37:13 +02:00
Holger Hans Peter Freyther a8a50a87ea nat: Also send a Clear Command in case of the USSD Provider dies 2010-10-27 12:02:21 +02:00
Holger Hans Peter Freyther 54f5352e07 nat: Close SCCP connections when the USSD Provider is closed.
Send a RLSD down to the BSC in case the USSD Provider is gone. It
is not sending a Clear Command and ut depends if the BS+ will
like this kind of behavior. At least the data on the NAT will
be freed soon afterwards due the RLC message.
2010-10-27 11:01:55 +02:00
Holger Hans Peter Freyther 07dfc70276 nat: Make clear where the RLSD is send to
Add a _msc to the method as we will send a RLSD to the
MSC and will add a method to send it down to the BSC
as well.
2010-10-27 10:54:11 +02:00
Holger Hans Peter Freyther 643931db3d nat: Look at the number type to figure out if we want to rewrite it 2010-10-27 10:40:45 +02:00
Holger Hans Peter Freyther 1400310f05 nat: Explain that we do not want to have a + in the replacement rule 2010-10-27 10:40:44 +02:00
Holger Hans Peter Freyther 25adfceb3a nat: Add '*' as wildcard for the IMSI matching.
In case any rule has a '*' we will always match this
rule.
2010-10-27 10:40:44 +02:00
Holger Hans Peter Freyther 73bbf89245 nat: Implement rewriting, have a very basic test for that feature 2010-10-27 10:40:44 +02:00
Holger Hans Peter Freyther a914daf174 nat: Add hook for rewriting a setup message
Create a new function, hand the data to this function, take back
a possible modified msgb and invalidate parsed at this point.
2010-10-27 10:40:44 +02:00
Holger Hans Peter Freyther 76424392e0 nat: Add vty option for number rewriting
Parse a msg file in case we do have a list.
2010-10-27 10:40:43 +02:00
Holger Hans Peter Freyther 0586b0fa47 [vty] First set of fixes for the oml/rsl con dropping
The code had wrong documentation in the VTY, it crashed
when OML or RSL was not up yet. These issues are fixed
right now.
2010-10-26 09:44:21 +02:00
Holger Hans Peter Freyther 2484ceb2be [vty] Add ipa specific command to provoke failures to test OML/RSL reconnect
We need to simulate OML/RSL failure in an easy and fast way
and adding a command to do so seems like a good way to achieve
this. The command is a bit misplaced, in one way it is no config
and does not belong into the config node but then again it does
not belong into the VIEW_NODE either as it is manipulating content.

On this merge I have changed it to the ENABLE_NODE.
2010-10-26 09:40:13 +02:00