aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src
AgeCommit message (Collapse)AuthorFilesLines
2009-12-21it's LOGL_ERROR, not LOG_ERRORHarald Welte2-3/+3
2009-12-21[sms] bugfix: additional functionality indicator only appears in ↵Steffen Neubauer1-1/+2
TP_VPF_ENHANCED - not in TP_VPF_ABSOLUTE
2009-12-21make sure bootstrap_bts() only contains static initializationHarald Welte1-3/+5
values that might change at runtime are moved to set_system_infos() which we might now also call at runtime to update the BTS with changes in the SI
2009-12-21remove duplicate flag for cell barringHarald Welte2-6/+4
it's sufficient if we keep the state of cell barring in one place
2009-12-21ipaccess: Fix two minor bugs regarding multi-TRX setupHarald Welte1-2/+3
we need to set newbfd->priv_nr to 2+trx_id, rather than keeping it '2' all the time, as it is used to look-up the e1i_ts when we receive a packet. A constant '2' would always match to TRX 0. we also need to keep one separate bit for each TRX state in order to properly generate the EVT_E1_TEI_UP event for trx > 0.
2009-12-21[gprs] SI 13 should only be generated on C0 (BCCH-carrying TRX)Harald Welte1-7/+8
2009-12-21[abis] Do not access an array with N elements at index NHolger Hans Peter Freyther1-3/+3
Possible crash fixes by preventing accessing the array out of bounds.
2009-12-21[abis] Properly compare obj_inst->trx_nr to bts->num_trxHolger Hans Peter Freyther1-2/+2
* Use >= in this case as we start counting the trx from 0 * This is fixing a problem with multi trx config
2009-12-21make handover algorithm parameters configurable from VTYHarald Welte1-0/+65
2009-12-21[handover] Real handover algorithmHarald Welte4-27/+211
This implements the handover algorithm (and associated parameters) as described in Chapter 8 of the book "Performance Enhancements in a Frequency |Hopping GSM Network" by Thomas Toftegard Nielsen and Jeroen Wigard. The parameters such as averaging windows are configured in struct gsm_network. We keep some state to trakc up to 10 neighbors as they are being reported from the MS. This has so far only been tested in a network with two BTS that have each other as neighbor. Networks with morge neighbors might encounter bugs.
2009-12-21handover: set old channel to INACTIVE stateHarald Welte1-1/+4
After receiving the HANDOVER COMPLETE on the new channel, we mark the old channel as INACTIVE and try to release it ASAP.
2009-12-21RSL: keep track if a channel is active or notHarald Welte1-0/+10
This allows us to block packets that we have received after the channel is no longer being used. This is visible during handover, where we still receive a measurement report after the MS has switched to the new channel. This leftover measurement report then attempts to trigger another handover, which si bogus and will fail - and thus only consumes resources. With the new LCHAN_S_ACTIVE state, we can check for this when processing the measurement report.
2009-12-21meas_rep: utility function for processing of measurement reportsHarald Welte2-1/+115
This provides two functions: get_meas_rep_avg() to obtain the sliding window average of one particular field, and meas_rep_n_out_of_m_be() to check if at least N out of M measurments are >= BE.
2009-12-21Fix typo s/memcpy/memcmp in trau_frame.cAndreas Eversberg1-1/+1
2009-12-21chan_alloc: Delete T3101 on lchan_free as wellSylvain Munaut1-0/+1
If a RF channel is assigned but no response is ever heard from the phone, we will receive a CONNECTION FAIL from the BTS, triggering a RF release freeing the channel. Then sometime later, T3101 will expire as well and free the channel again ... Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2009-12-21[db] Fix queries for unsent SMSSylvain Munaut1-3/+5
- Need to use sms.id for the ORDER BY since 'subscriber' also has 'id' - Need to add the join clause between 'SMS' and 'subscriber' - Add a LIMIT 1 (probably no impact for the db size we're dealing with here, but with large DB and mysql/postgresql this can help the planner) - (fix a wrong comment in passing ...) Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2009-12-20Fix some compiler warnings regarding missing const in rest_octets.cHarald Welte1-2/+3
2009-12-20fix compiler warning and coding style in rtp_proxyHarald Welte1-2/+3
2009-12-20[handover] implement TCH RTP stream handoverHarald Welte1-1/+69
This patch takes care of handling the RTP streams / sockets during an in-call handover from one BTS to another BTS. It only works in combination with rtp_proxy mode.
2009-12-20rename ipacc_connect_proxy_bind() to rsl_ipacc_mdcx_to_rtpsock()Harald Welte2-17/+17
Our RTP sockets are no longer just for the proxy mode, so having "proxy" in the function name is really misleading.
2009-12-20Move RTP socket handling out of signal handlers into abis_rslHarald Welte2-26/+33
This is not really nice, but we will soon have multiple users of the CRCX / MDCX / DLCX signals, and we cannot guarantee the ordering of them. So as a workaround, we move the RTP socket creation and deletion into the core abis_rsl codebase.
2009-12-20don't enable handover unless RTP Proxy is enabledHarald Welte1-0/+6
We cannot support in-call handover of calls without a RTP proxy, since at the time of the handover the SSRC, sequence number and timestamp of the RTP frames change.
2009-12-20Introduce new MNCC based proxy modeHarald Welte1-4/+59
Since the MNCC API can now send and receive frames to/from the MNCC application, we can also implement a proxy this way. Not at the RTP/UDP packet level, but at the 'TCH speech frame' level. Especially for handover, we need this mode as the receiver in the BTS needs a persistent SSRC and monotonic frame numbers / timestamps.
2009-12-20remove hand full of 'extern ipacc_rtp_direct' definitionsHarald Welte3-4/+0
and instead declare it in gsm_data.h
2009-12-20RTP Proxy: Fix RTP sequence number and timestamp in case of dropped framesHarald Welte1-0/+35
During handover, we will not send RTP frames for quite some time. However, the way the rtp_send code is structured, it will increment the timestamp with a fixed amount every time we send a frame, independent how much wallclock time has actually passed. This code is a hack to update the sequence number and timestamp in case it seems to be wrong. It makes handover much more reliable.
2009-12-20add FIXME to IMSI DETACH INDICATION: we need to release all transactionsHarald Welte1-0/+3
2009-12-20fix segfault in rrlp code in case of unsuccessful pagingHarald Welte1-0/+4
PAGING_COMPLETED can be signalled without an active lchan in case it was unable to page the repsective subscriber.
2009-12-20handover: disable default-printing of every measurement reportHarald Welte1-1/+1
2009-12-20handover: no debug message for ever non-handover measurement reportHarald Welte1-3/+1
2009-12-20handover: don't create negative lchan use countsHarald Welte1-3/+0
trans_lchan_change() takes care of use counts for us.
2009-12-19Add RTP support for EFRHarald Welte2-1/+10
This is just the minimal support to receive and send EFR codec RTP frames. We are missing the code to convert TRAU frames in EFR format!
2009-12-19RTP-enable MNCC API for LCR + ip.accessHarald Welte3-48/+388
Instead of passing TRAU frames down the MNCC API to the call control application like MNCC, we now decode the TRAU frame into the actual codec frame. We do the same with the RTP packets in case of ip.access and thus have a unified format of passing codec data from the BTS to an application, independent of the BTS type. This is only implemented for V1 full-rate at the moment, and needs to be fixed.
2009-12-19[handover] add VTY parameter to enable/disable handoverHarald Welte2-7/+25
2009-12-19[handover] don't use measurement reports with NCELL=7Harald Welte1-0/+3
NCELL=7 inidicates that there was no neighbor cell info in the SI5 on the SACCH.
2009-12-19system_information: DEBUGP() SI13/5/6 during startupHarald Welte1-12/+12
2009-12-19system_information: ip.access wants L2_PLEN, BS-11 doesn'tHarald Welte1-7/+20
It seems that depending on the manufacturer, there is a need to include the L2 pseudo-length in the SI5+SI6 messasges (SACCH FILLING) Thanks to Dieter for pointing this out.
2009-12-19don't print measurement reports that have no cellsHarald Welte1-0/+2
2009-12-19measurement report parsing: NO-NCELL-M of 7 tells us no neighborsHarald Welte1-1/+1
2009-12-19ip.access: Keep a full copy of local and remote IP/PORT in lchanHarald Welte2-51/+89
Keeping all parameters for each RTP connection in the abis_ip member of lchan will help us with actual TCH handover later on.
2009-12-19add --help message about --rtp-proxy argumentHarald Welte1-0/+1
2009-12-19Never allocate transaction ID 7Sylvain Munaut1-1/+1
According to GSM 04.07 11.2.3.1.3 , TID 7 is "reserved for future extensions". Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2009-12-19Fix subscr ref leak for multi CM SERV REQSylvain Munaut1-1/+3
Multiple CM SERVICE REQUEST can happen on a single RR connection, in this case, since the subscr reference is tracked through lchan->subscr and will only be put'd once on lchan_free, we need to make sure we don't get several reference .... Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2009-12-19Use 'new' rather than 'unknown' when starting transactionSylvain Munaut1-1/+1
'unknown' has a negative connotation for a case that's totally normal so refer to it as 'new' so it doesn't sound like a problem. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2009-12-19Fix transaction_id displayed in debug messageSylvain Munaut1-1/+1
In SMS debug messages, we always display the transaction ID as if we were 'sending' the message. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2009-12-19Fix typos in debug message / commentsSylvain Munaut1-1/+1
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2009-12-18[handover] lchan use count handling in case of trans_lchan_change()Harald Welte1-0/+5
2009-12-18[handover]: make sure the new lchan keeps the subscriber pointer of the old ↵Harald Welte1-5/+6
lchan also, ensure that we don't print debug messages about handover in non-handover channel activation cases.
2009-12-18handover: use correct handover lookup functionHarald Welte1-1/+1
2009-12-18for now we only do handover of TCH channelsHarald Welte1-0/+9
2009-12-18fix segfault in case of handover timer expirationHarald Welte1-0/+1