aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src/gprs
AgeCommit message (Collapse)AuthorFilesLines
2016-03-03put Iu-common and Iu-CS stuff in proper placesNeels Hofmeyr2-558/+2
Add libiu to contain the parts used by both Iu-CS (in osmo-cscn) and Iu-PS (in gprs) into libiu. It's rather thin and may make sense to move to osmo-iuh altogether, eventually. iu.c is half moved to libiu/, and half to osmo-cscn/iu_cs.c.
2016-03-03wipNeels Hofmeyr1-1/+9
2016-03-03todo / #if 0Neels Hofmeyr1-0/+5
2016-03-03minor fixesNeels Hofmeyr1-3/+3
2016-03-03func declaration, commentsNeels Hofmeyr1-0/+3
2016-03-03fix: it's called msgb.dst.Neels Hofmeyr1-2/+2
2016-03-03Add some Iu-CS functions (in the wrong place though, wip)Neels Hofmeyr1-0/+78
2016-03-03cosmetic: a rename, comments.Neels Hofmeyr1-3/+3
Rename conn_ctx_list -> ue_conn_ctx_list. Indicate Iu-CS 'siblings' for a couple of functions. Tweak/add comments.
2016-03-03wip (reminders to self, whitespace)Neels Hofmeyr1-1/+0
2016-03-03iu_init: add addr and port argsNeels Hofmeyr2-3/+4
2016-03-03various small fixesNeels Hofmeyr2-18/+39
2016-03-03sai arg back to pointerNeels Hofmeyr1-2/+2
2016-03-03some fixesNeels Hofmeyr1-6/+9
2016-03-03generalize rab_act for ps and csNeels Hofmeyr2-12/+26
2016-03-03move struct ue_conn_ctx to headerNeels Hofmeyr1-6/+0
2016-03-03sai argNeels Hofmeyr1-1/+1
2016-03-03iu_commonNeels Hofmeyr1-2/+1
2016-03-03rename sgsn_iu.c to iu.c.Neels Hofmeyr2-1/+1
That code seems to be usable for the CS side, as well. A more general name is applicable. todo: move out of gprs even.
2016-03-03tweak ..rcvmsg_iu()'s sai arg.Neels Hofmeyr1-2/+2
It was a uint16_t*, but is passed as a uint16_t, and never used anyway, yet.
2016-03-03iu_common wipNeels Hofmeyr3-5/+17
2016-03-03asn_debugNeels Hofmeyr1-0/+1
2016-03-03cosmeticNeels Hofmeyr2-2/+2
2016-03-03typoNeels Hofmeyr1-1/+1
2016-03-03fix sgsn_mm_ctx_cleanup_free: TLLI unass. after sgsn_mm_ctx_free.Neels Hofmeyr1-4/+7
The comment says so and it was moved above sgsn_mm_ctx_free in a commit marked as ugly hack.
2016-03-03fix ranap_handle_co_dt, failed to pass struct pointerNeels Hofmeyr1-1/+1
2016-03-03remove dead code from Makefile.amHarald Welte1-2/+0
2016-03-03migrate WIP osmo-iuh hack to use system-installed libosm-ranap.soHarald Welte3-26/+21
this means we no longer try to link to hard-coded files outside of the openbsc.git repository.
2016-03-03WIP: Really ugly hacks to get up to (and including) PDP CTX ACTHarald Welte6-41/+200
2016-03-03add sgsn_iu.c that was missed in large WIP commitHarald Welte1-0/+425
2016-03-03WIPHarald Welte1-1/+51
2016-03-03gprs_gmm.c: Preform LLME operations only if we have oneHarald Welte1-5/+7
In case the GMM message did not arrive over a Gb interface, there is no LLME (and thus the associated pointer is NULL). Don't try to perform operations on a NULL LLME.
2016-03-03gprs_gmm.c: Make TLLI handling specific to Gb interfaceHarald Welte1-36/+60
Soem of the operations we perform in the GMM layer are specific to the GPRS/EDGE radio access network and its Gb interface. Let's make them conditional to that in preparation of supporting an Iu interface.
2016-03-03gprs_gmm.c: Don't try to de-reference NULL mmctxHarald Welte1-0/+10
There was a comment in the code that certain GMM messages require a valid mmctx pointer. However, nothing actually checked if that pointer was in fact non-NULL. We plainly crashed if a MS would send us the wrong message in the wrong state.
2016-03-03rename gsm0408_gprs_rcvmsg() to gsm0408_gprs_rcvmsg_gb()Harald Welte2-3/+3
This is the entry point for GMM from Gb. We will create a new one for Iu, so let's be explicit rather than implicit.
2016-03-03prepare sgsn_mm_ctx for Gb and Iu mode (UMTS)Harald Welte6-45/+45
Let's explicitly mark those sgsn_mm_ctx members that apply for Gb mode and (upcoming) Iu mode, respectively.
2016-02-25enable ctrl bind config for various programsNeels Hofmeyr2-13/+23
Add ctrl_vty_init() calls and feed the ctrl_vty_get_bind_addr() return value to ctrl_interface_setup() in the following programs: osmo-bsc osmo-bsc_nat osmo-nitb osmo-sgsn For osmo-sgsn, move the control interface setup invocation below the config parsing, so that the ctrl_vty_get_bind_addr() can return the configured address.
2016-02-25enable telnet VTY bind address config for various programsNeels Hofmeyr3-10/+24
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.
2016-02-23gtphub: tweak default logging levelNeels Hofmeyr1-1/+1
2016-02-23gtphub: include ports.h instead of redefining OSMO_VTY_PORT_GTPHUBNeels Hofmeyr1-5/+1
2016-02-22sgsn: Re-add searching for MM ctx based on TLLI / P-TMSI matchesJacob Erlbeck2-3/+48
If an MM context cannot be found based on BBSGP info and a RA UPDATE REQUEST is received, try to find an MM context with an P-TMSI from which the TLLI could have been derived. This also checks, whether the routing area matches. This is similar to the old behaviour removed by the commits "sgsn: Only look at TLLIs in sgsn_mm_ctx_by_tlli" and "sgsn: Remove tlli_foreign2local", except that this will only be done for RA UPDATE REQUESTs now. Sponsored-by: On-Waves ehf
2016-02-22sgsn: Change handling of missing mmctx in gsm48_rx_gmm_ra_upd_reqJacob Erlbeck1-3/+15
Currently the MM context is just overwritten by a call to sgsn_mm_ctx_by_tlli(msgb_tlli(msg), &old_ra_id) even if it has already been found by using the BSSGP info. With the changes made to sgsn_mm_ctx_by_tlli this will never find a MM context if the routing area has changed. If the routing area has not changed, the mmctx has already been found if it exists. This commit splits searching for an MM context (if it hasn't been found already) from checking, whether a found one can really be used. The actual search is removed, so that the MS will be forced to restart the attach procedure, which is less efficient but safe. Sponsored-by: On-Waves ehf
2016-02-22sgsn: Only look at TLLIs in sgsn_mm_ctx_by_tlliJacob Erlbeck1-30/+1
Currently the code also matches the TLLI against LOCAL and FOREIGN mappings of the P-TMSI, thus eventually finding MM contexts not consistent with the TLLI (both tlli and tlli_new differ). On the other hand, tlli_new is not checked at all. This commit changes the function to only look at mmctx->tlli, mmctx->tlli_new, and the routing area. Sponsored-by: On-Waves ehf
2016-02-22sgsn: Make ra_id_equals available as gprs_ra_id_equalsJacob Erlbeck2-9/+9
The function is moved to gprs_utils.c, renamed, and made non-static to be usable in other modules, too. Sponsored-by: On-Waves ehf
2016-02-22sgsn: Remove tlli_foreign2localJacob Erlbeck1-23/+2
Currently foreign TLLI are sometimes mapped to local TLLI in the hope that they will match. This seems to sometimes introduce inconsisties, possibly leading to a failing assertion in _bssgp_tx_dl_ud. This mapping should probably reduce the allocation of additional LLME during routing area changes. This commit removes tlli_foreign2local. Sponsored-by: On-Waves ehf
2016-01-30gsm0408: Provide unique strings for the gsm 04.08 messageHolger Hans Peter Freyther2-20/+20
At Rhizomatica we see that some GSM 04.08 messages are leaked and have no other indication if that is Call Control, SMS or something else.
2016-01-26gprs: use libgtp cflagsAlexander Huemer1-1/+1
2016-01-23gtphub: Fix use after free on failureHolger Hans Peter Freyther1-1/+3
Even if fclose fails the stream is inaccessible and the second fclose might cause memory violation. Linux manpage says: Upon successful completion 0 is returned. Otherwise, EOF is returned and errno is set to indicate the error. In either case any further access (including another call to fclose()) to the stream results in undefined behavior. Fixes: CID#57958
2016-01-22gtphub: Make the two setter static as wellHolger Hans Peter Freyther1-2/+2
Same as with the previous gtphub commit. Make these static to deal with the new semantic of inline in gcc5.
2016-01-22gtphub: Fix compilation using gcc5Holger Hans Peter Freyther1-2/+2
The semantic of inline has changed and we need to make it static to not end up with undefined references.
2015-12-14gtphub VTY: add newlines to some VTY docs' final linesNeels Hofmeyr1-8/+8