aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/include
AgeCommit message (Collapse)AuthorFilesLines
2010-04-06nat: Store the config in the connection instead of the lacHolger Hans Peter Freyther1-2/+2
This allows that we can print the Nr. next to the lac and it allows us to change the lac at runtime without reconnecting the BSC.
2010-04-06[vty] Move the VTY logging commands to a new fileHolger Hans Peter Freyther2-1/+7
Currently vty_interface.c is used for the BSC config, in case of the MGCP Gateway or the BSC Nat process these logging commands are not available. Move the commands to a new vty_interface_cmds.c file to allow to share basic commands across different programs.
2010-04-06Revert "nat: Remember where the BTS is listening for things."Holger Hans Peter Freyther1-1/+0
Remove the code to parse port as we need to discover the BTS behind the nat and most likely it will have a different port than the one advertised by the BTS. This reverts commit c6a1fe773d16eb20d4cb1d3097761419436f4537.
2010-04-05nat: Close all endpoints used by a BSC when the BSC is goneHolger Hans Peter Freyther1-0/+1
Cleanup all endpoints that belonged to a given BSC. This is one part of the cleanup, the other is to bring down the SCCP link properly.
2010-04-05nat: Remember a pending delete on an endpoint and carry it out laterHolger Hans Peter Freyther1-0/+2
2010-04-05[sccp] Add a force_free method for connectionsHolger Hans Peter Freyther1-0/+5
E.g. when the underlying connection transport medium is gone one needs to force to close SCCP connections, add this helper. It will remove the connection from the list of connections and it will free the data.
2010-04-05nat: Remember where the BTS is listening for things.Holger Hans Peter Freyther1-0/+1
Extract the port from the BSS's MGCP Gateway so we know where to forward the data to.
2010-04-04nat: Make rewrite work on string, read to a string first, copy to msgbHolger Hans Peter Freyther1-2/+3
The MGCP protocol parsing is adding '\0' to make sure we do not parse beyond where we should parse. This does not mix with strtok or similiar routines. For now we will read the msg into a global array first, then copy it to the msgb for mgcp protocol handling and if we are required to forward it to the MGCP we have a untouched copy we will modify into our own msgb.
2010-04-01nat: Return MGCP messages to the call agentHolger Hans Peter Freyther1-0/+4
Attempt to find the message by transaction id, then patch the response and use the IP/PORT of the local network, update the ci with the one from the BSC. This is currently not tracking any state of the MGCP and will not handle two bsc's... this will need to happen later. With this in we should be feature complete and now enter the mode of making all of this work reliable and fixing thinko's and other bugs.
2010-04-01nat: Handle CRCX/MDCX/DLCX at the natHolger Hans Peter Freyther1-0/+15
* Forward a rewritten msg to the BSS. We change the IP and port to point to the NAT instead of the core network. We also keep track of the BSC and the transacition id. * Handle the case where we have not found a SCCP connection and need to send a response ourselves.
2010-04-01nat: Test rewriting of MGCP messages to patch ip and portHolger Hans Peter Freyther1-0/+1
Add code to change the ip and port for audio data inside MGCP messages. This is needed because the BSS might be behind the NAT and can not reach the network directly and might be behind a nat so the announced sourceport is not the one as we see it.
2010-04-01nat: Add code to find a BSC connection by the given msc multiplexHolger Hans Peter Freyther1-0/+2
2010-04-01[mgcp] Export header parsing via mgcp internalHolger Hans Peter Freyther1-0/+9
This will be used by the NAT code to implement custom protocol handling on top of that.
2010-03-31nat: First go at handling MGCP inside the natHolger Hans Peter Freyther1-0/+2
Listen on the MGCP gateway port and let our protocol stack handle everything for now. We will need to have some more control over things though.
2010-03-31[mgcp] Add a new config option to set the call agent ip addrHolger Hans Peter Freyther1-0/+1
In the case of the nat we only want to communicate with one upstream call agent and this can now be configured.
2010-03-31[mgcp] Regroup struct mgcp_cfg members and provide some hintsHolger Hans Peter Freyther1-4/+10
2010-03-31[mgcp] Add a helper function to convert from GSM0808 ts/mux to MGCP endpointHolger Hans Peter Freyther1-0/+8
Move the conversion of GSM0808 timeslot and multiplex from the bssap.c into the mgcp.h so it can be reused by multiple users. The weird math comes from the mapping of the MSC...
2010-03-31nat: In the case of losing the MSC, reset all endpointsHolger Hans Peter Freyther1-0/+1
When losing the SCCP connection make sure that we free all endpoints. The disconnection of the BSC should already make sure they are closed but this makes sure everything is properly reset.
2010-03-31[nat] Send a RSIP down to the BSC after it connectsHolger Hans Peter Freyther1-1/+2
Make sure the MGCP attached to the BSC is resetting all endpoints whenever the BSC is connecting to us as we assume that all endpoints are available.
2010-03-31[mgcp] Add some parsing for RSIP messages coming inHolger Hans Peter Freyther1-0/+2
This will just call a callback and leave all the handling to the application.
2010-03-30[mgcp] Remove the sending of RSIPHolger Hans Peter Freyther1-1/+0
This message is ignored by the call agent and we were sending this on the first request which we maybe should not ignore...
2010-03-30nat: Add MGCP code and parsing to the nat code..Holger Hans Peter Freyther1-0/+7
For the nat we will have NAT and MGCP in the same process and this commit starts with that. We are linking in the MGCP code and one can embed MGCP config snippets...
2010-03-30nat: Look at the assignment command and remember on which timeslot the data isHolger Hans Peter Freyther1-0/+10
This information will be needed when we are trying to forward MGCP connections to and from the BSC through the IPA protocol.
2010-03-30sccp: Move the destruction of the sccp connection to a new placeHolger Hans Peter Freyther1-0/+1
2010-03-30nat: Return the SCCP connection, change order of patching and updatingHolger Hans Peter Freyther1-3/+3
* Return the SCCP connection. This will be needed to store the assigned timeslot in there. * Update code to work with this change * This uncovered a bug in the CC handling, at the time the BSC was passed it was still a null pointer and the code would have failed.
2010-03-30nat: Documentation fix... use nat for the parameterHolger Hans Peter Freyther1-1/+1
2010-03-30nat: Move paging by lac handling code into the utils fileHolger Hans Peter Freyther1-0/+1
Moving it here means we can more easily test this code, there is one behaviour change with the code that we only support paging messages with one LAC and will silently ignore the others.
2010-03-29nat: Keep track of both sides of the connectionHolger Hans Peter Freyther1-0/+2
On a CC message we will need to remeber where the source local reference of the network belonged so we can properly identify the connection when receiving UDT messages.
2010-03-29nat: Move creation of the structs to a separate fileHolger Hans Peter Freyther1-0/+2
This way one can create the bsc_nat structure in unit tests..
2010-03-29nat: Move SCCP patching to a new file, log updatesHolger Hans Peter Freyther1-0/+8
Move patching and reassigning of messages to a new file which will making testing this functionality more easy.
2010-03-26msc: Create a real interface for BSC MSC and start handling reconnectsHolger Hans Peter Freyther1-2/+18
Create a BSC<->MSC interface and use it for the BSC MSC IP and the BSC NAT to reduce code duplication on handling reconnects to the MSC and cleaning up the local state. The code is only partially tested and will contain bugs. Currently both the BSC and the NAT will just exit on connection loss and this way have the current behavior.
2010-03-26bsc_msc_ip: Keep track of active connections so we could clear them.Holger Hans Peter Freyther1-0/+3
Keep track of SCCP connections so we can clear them when the MSC is going down.
2010-03-26nat: Start using a write_queue for the BSC connectionHolger Hans Peter Freyther1-1/+2
We are still writing to the BSC directly and don't make real use of this feature right now but we will need to do it.
2010-03-26Merge branch 'on-waves/sccp' into on-waves/bsc-masterHolger Hans Peter Freyther1-1/+1
2010-03-26sccp: Change the ownership of the msgb passed to the callbackHolger Hans Peter Freyther1-1/+1
Instead of deleting the msgb within the SCCP library the implementor of the write callback needs to free it. This is required for non blocking io with the server.
2010-03-25channel requests: Add configuration to handle paging any with TCHHolger Hans Peter Freyther1-0/+3
It is possible that the MSC is not sending the channel type it needs for the operations it wants to do. Add a configuration option to assign a TCH in case of paging any requests. It can be a good idea to leave SDCCHs free for location updating requests.
2010-03-25channel request: Store the to be assigned channel type in the GSM NetworkHolger Hans Peter Freyther2-2/+5
Store the mapping from request to channel type in the GSM Network struct as there is some policy involved with handling the request. E.g. in a half rate network we don't want emergy calls to be getting a TCH/F, or we want to have a different policy for early/late assignment of phone calls. Update the table when creating the network and when the neci is changed.
2010-03-24Specify a release reason for the lchanHolger Hans Peter Freyther2-4/+4
In case the put_lchan is making the refcount drop to zero use the release reason specified in the put_lchan call. This is used by the BSC MSC IP implementation for the assignment handling where the old channel is getting closed with a local end release (1).
2010-03-24Fix DNAT debug.h definition and move it to the enum.Holger Hans Peter Freyther1-2/+1
2010-03-24Merge remote branch 'origin/master' into on-waves/bsc-masterHolger Hans Peter Freyther3-2/+21
Keep a static version as the shell script is not dealing well with branch tags/names containing text. Resolve merge conflict in the Makefile.am by adding both sides to the list of sources for the libbsc.a Conflicts: openbsc/configure.in openbsc/src/Makefile.am
2010-03-24Correct the company name. It should be On-Waves (ehf)Holger Hans Peter Freyther2-2/+2
2010-03-24Merge remote branch 'origin/master' into on-waves/bsc-masterHolger Hans Peter Freyther41-3481/+502
* Move to libosmocore * Move to new debugging architecture * Register the BTS types * Has only been compile tested Conflicts: openbsc/include/openbsc/Makefile.am openbsc/include/openbsc/gsm_data.h openbsc/include/openbsc/ipaccess.h openbsc/include/openbsc/mgcp.h openbsc/include/openbsc/msgb.h openbsc/include/openbsc/tlv.h openbsc/src/Makefile.am openbsc/src/abis_rsl.c openbsc/src/bsc_init.c openbsc/src/bsc_mgcp.c openbsc/src/chan_alloc.c openbsc/src/debug.c openbsc/src/gsm_subscriber_base.c openbsc/src/msgb.c openbsc/src/rest_octets.c openbsc/src/sccp/sccp.c openbsc/src/vty/command.c openbsc/src/vty_interface.c openbsc/tests/Makefile.am
2010-03-22GPRS: make NSEI configurable from VTYHarald Welte1-0/+1
2010-03-22GPRS: make NSVC parameters VTY-configurableHarald Welte1-0/+4
2010-03-22Create new gprs-conf branch with the non-SGSN part of the gprs branchHarald Welte2-0/+14
This new gprs-conf branch is intended to contain everything needed to configure GPRS in the nanoBTS, but without implementing the SGSN/GGSN functionality. The SGSN/GGSN development will happen in a branch based on this branch called "gprs-sgsn"
2010-03-22ipa-firmware: Write the firmware parts to a fileHolger Hans Peter Freyther1-0/+1
The first non working version to dump the content of the sdp to the terminal..
2010-03-22ipa-firmware: Remove the part_length from the struct sdp_firmwareHolger Hans Peter Freyther1-2/+1
* The length of the table is not at a fixed position. We will need to read the offset, seek there, read the data, convert it to the host endianes. * Prepare the code to work with offsets of 0...
2010-03-07move large parts of mncc.h and gsm48 encode/decode into libosmocoreHarald Welte1-63/+1
2010-03-04decleare gsm_bts_model_register()Harald Welte1-0/+2
2010-03-04move some gsm48 utility functions to libosmocoreHarald Welte2-9/+0
* gsm48_generate_lai() gsm48_generate_mid_from_tmsi() gsm48_generate_mid_from_imsi() * gsm48_cc_msg_names[]