Commit Graph

187 Commits

Author SHA1 Message Date
Holger Hans Peter Freyther 511f9c3e4a si: Partially implement the range encoding for the SI.
I saw the old copy of the "Appendix J" code too late and I have
discovered some quirks and I am more familar with my implementation.
Most noticable 'w' only needs to be as big as the input arfcn but
requires the 'w' to be initialized. The power_of_2 implementation
differs as well (mine matches the output of wirehsark).

The f0 could be chosen in a better way but right now picking
the lower bound is the easiest. It is not clear if to use
modulo if the range is chosen in the middle. This can be improved
in the future. Right now I have no bit fiddling for range128, 256
and 1024 as I was running out of time.
2012-10-22 15:23:58 +02:00
Pablo Neira Ayuso d49eb74732 libbsc: fix message leaks on several error paths
This patch fixes several leak of msgbs in uncommon error paths.

Add break at the end of default to make Holger and Peter happy ;-)
2012-10-18 19:04:40 +02:00
Andreas Eversberg 2ee7ecddeb Allow setting of Control Channel Description parameters via VTY 2012-10-18 12:01:32 +02:00
Holger Hans Peter Freyther 94c2b0578b bsc: Do not print "SI 18" but SI2ter when the SI generation fails 2012-10-09 11:54:00 +02:00
Harald Welte c15d0ac8dd SI13: Set alpha value to a safer default of 0 instead of 10
alpha=0 (the new value) doesn't reduce MS transmission power during GPRS
as much as we did with alpha=10.  This is to optimize for coverage and
to keep GPRS working at all cost, and not care about MS battery life
time or uplink interference in surrounding cells.

FIXME: This should be made configurable via the VTY and the normal
default (unless configured otherwise by vty/config file) should be '6'.
2012-10-08 21:22:08 +02:00
Harald Welte d9173c3fce bsc_init: Don't drop all BTSs because a single BTS had an error 2012-10-08 21:17:51 +02:00
Andreas Eversberg becc89a98e Fix: T3192 and T3193 must be similar
In order to keep mobile at PACCH as long as possible the timer T3192 is
set to 1500ms. This reduces the probablity of long lasting assignment
process on CCCH for subsequent downlink TBFs.
2012-09-29 20:29:16 +02:00
Holger Hans Peter Freyther 34203bd487 abis_nm: Provide a reason when an invalid channel configuration is used
Provide a human readable reason the channel combination is not allowed.
2012-09-17 17:24:49 +02:00
Holger Hans Peter Freyther 9ceea68ba9 abis_nm: Log an error when the channel combination can not be set. 2012-09-17 14:21:53 +02:00
Daniel Willmann 65924a5fe8 osmo-bsc: Include rf statistics in the location-state TRAP as well
The first fields are still the location up to the height.
The next field is "operational" if any of the trx are operational,
otherwise "inoperational"
The second to last field contains "locked" if all of the trx are in the
admin state, otherwise "unlocked".
The last field represents the rf policy currently in effect. It is one
of (on|off|grace|unknown).

<tstamp>,<valid>,<lat>,<lon>,<height>,<oper>,<admin>,<policy>
2012-09-11 16:20:45 +02:00
Holger Hans Peter Freyther 4dd84ff7c2 bts_hsl_femtocell.c: Use PRIx64 to printf the uint64_t
bts_hsl_femtocell.c: In function ‘hsl_sign_link_up’:
bts_hsl_femtocell.c:206:3: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 7 has type ‘uint64_t’ [-Wformat]
bts_hsl_femtocell.c:210:2: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 6 has type ‘uint64_t’ [-Wformat]
2012-09-11 12:41:23 +02:00
Holger Hans Peter Freyther d98136d25c bsc_init: Initialize rc on all paths to address a compiler warning
bsc_init.c:203:6: warning: ‘rc’ may be used uninitialized in this function [-Wmaybe-uninitialized]
bsc_init.c:101:6: note: ‘rc’ was declared here
2012-09-11 12:41:23 +02:00
Holger Hans Peter Freyther a5050b14c9 misc: Address compiler warning on unused variables
abis_nm.c: In function ‘abis_nm_get_attr’:
abis_nm.c:1380:11: warning: unused variable ‘cur’ [-Wunused-variable]

abis_nm.c: In function ‘ipac_parse_bcch_info’:
abis_nm.c:2588:11: warning: variable ‘len’ set but not used [-Wunused-but-set-variable]

bts_nokia_site.c:1310:6: warning: variable ‘constructed’ set but not used [-Wunused-but-set-variable]
bts_nokia_site.c: At top level:
bts_nokia_site.c:1364:12: warning: ‘dump_elements’ defined but not used [-Wunused-function]

gsm_04_08.c: In function ‘mm_rx_loc_upd_req’:
gsm_04_08.c:521:6: warning: variable ‘rc’ set but not used [-Wunused-but-set-variable]

osmo_msc.c: In function ‘msc_ciph_m_compl’:
osmo_msc.c:122:7: warning: variable ‘rc’ set but not used [-Wunused-but-set-variable]

bts_hsl_femtocell.c: In function ‘hslfemto_bootstrap_om’:
bts_hsl_femtocell.c:101:11: warning: variable ‘cur’ set but not used [-Wunused-but-set-variable]

bts_hsl_femtocell.c: In function ‘hsl_drop_oml’:
bts_hsl_femtocell.c:232:21: warning: variable ‘line’ set but not used [-Wunused-but-set-variable]

handover_logic.c: In function ‘ho_chan_activ_ack’:
handover_logic.c:197:6: warning: variable ‘rc’ set but not used [-Wunused-but-set-variable]
2012-09-11 12:41:23 +02:00
Harald Welte 79c34ffb4f OM2000: don't silently send CON/IS/TF configuration request 2012-09-07 20:15:50 +02:00
Harald Welte 4c889a5c49 RBS2000: Don't sent IS configuration if we want to config TF 2012-09-07 20:14:47 +02:00
Harald Welte 0818f31144 OM2000: make sure to route messages to IXU/DXU over BTS oml link
Messages to CF and other core objects need to go to the BTS (IXU/DXU)
OML link, not to the OML link of the primary TRX!
2012-09-07 19:10:47 +02:00
Harald Welte 240a828ffd OM2000: don't signal operational state for a unknown MO
This case happens if the BTS signals operational state for a TRXC which
is not configured as TRX in the openbsc.cfg
2012-09-07 19:10:47 +02:00
Harald Welte e422798866 RSL: Add basic support for CSD transparent mode
We now have a lchan->csd_mode member that determines if RSL should
activate the channel in CSD transparent services or not.  The previous
code always assumed CSD is non-transparent.

(This requires libosmocore >= eed26116c96f03c6128fac3dead9054714af6cab)
2012-08-29 16:33:54 +02:00
Harald Welte bb53e3577a reimplement chan_compat_with_mode() to take care of CSD 2012-08-29 16:33:54 +02:00
Harald Welte 9fc70f365a bsc_api: Invert logic of chan_compat_with_mode()
A function called this  way should return 1 if it is compatible, so
something like "if (!chan_compat_with_mode())" will check if it is not
compatible.
2012-08-29 16:33:53 +02:00
Harald Welte 570ce24deb VTY: improve VTY prompt and make sure exit/end works everywhere
Some nodes below 'config' didn't have ournode_exit / ournode_end,
and thus were not able to properly perform this function.  exit should
always only go back one level, while end drops us back to ENABLE_NODE.

The prompt now represents the nesting level, and there's one consistent
space after the final prompt character (typically #).
2012-08-17 13:16:10 +02:00
Harald Welte e555c2b545 VTY: dynamically create BTS "type" command syntax 2012-08-17 13:02:12 +02:00
Harald Welte 57e0724ed4 BSC VTY: use numeric ranges for bts/trx/timeslot numbers
This effectively limits the number of BTSs to 256, but I think that's
acceptable for now.  Unfortuantely there's no decent way to dynamically
update the valid number range depending on how many BTSs are actually
configured in the system :/
2012-08-17 12:50:14 +02:00
Harald Welte 4ab9d7c012 dynamically generate a proper VTY reference for phys_chan_config
this uses vty_cmd_string_from_valstr() from _very_ recent libosmocore,
so you have to update the library, sorry.
2012-08-17 12:42:06 +02:00
Harald Welte 13fe21939c ... and more VTY help fixes 2012-08-17 09:57:25 +02:00
Harald Welte d13e0cd6db Some more VTY documentation / help fixes 2012-08-17 09:52:03 +02:00
Harald Welte cfaabbb21e complete the VTY help messages so we don't get "null" in the manual 2012-08-16 23:23:50 +02:00
Harald Welte fe568f235f abis_nm: Add function abis_nm_get_attr() to get attributes from BTS 2012-08-14 19:15:57 +02:00
Holger Hans Peter Freyther 64c17fa598 libbsc: Add documentation to MM INFO, LAC, TSC, CI 2012-07-21 00:28:05 +02:00
Harald Welte ae1d010220 BSC API: Don't treat a RRLP message as NOTICE event
While generally we should log troly unknown RR messages, we can simply
pass along RRLP messages (which aren't unknown!)

In real networks, the RRLP would probably not end up at the MSC, but
well, sometimes we don't care what real/classic networks do.
2012-07-16 13:20:53 +02:00
Harald Welte 45f9171175 move BTS-specific timezone override into sub-structure
Group all three structure members involved in bts-specific timezone
handling into a sub-structure.
2012-07-12 01:14:28 +02:00
Harald Welte 25cf824edc handover: Not finding a HO record on CHAN ACT NACK is not an error
... it might well a completely non-ho-related establishment
2012-07-12 01:14:28 +02:00
Harald Welte ad66a2d150 BSC VTY: Allow encryption to be set to A5/3
We are currently not checking if the BTS actually suports that cipher,
and we particularly don't have any hack for ip.access which apparently
seems to re-use the RSL algorithm identifier for A5/2.
2012-07-04 21:39:27 +02:00
Harald Welte f383aa11a5 BSC: introduce new "sysmobts" BTS model
so far, osmo-bts/sysmobts used to be entered as "sysmobts" type in the
configuration file.  However, there are some differences in the
protocol/behaviour and we should reflect that by a new BTS plugin (with
lots of code reuse from the nanobts driver).
2012-07-02 20:13:08 +02:00
Harald Welte 0c1bd61bb3 pre-fix measurement reports with subscriber identity
... otherwise it's impossible to distinguish them from each other.
2012-07-02 20:13:02 +02:00
Harald Welte c95175fb88 ipaccess: some more comments on timer values 2012-06-28 09:03:00 +02:00
Harald Welte ea34a4e3a7 split libgb into a separate library for outside use
This also removes the dependency to osmo_sock() inside libcommon and
replaces it with osmo_sock_* from libosmocore
2012-06-16 15:14:00 +08:00
Harald Welte 67161f27d1 Allow VTY-based configuration of T3105
This timer will only be forwarded to BS11 and Ericsson Abis so far,
not to Nokia and ip.access BTS yet.
2012-06-03 16:58:18 +02:00
Harald Welte f25b55ec71 abis_rsl_rcvmsg(): Fix msgb memory leak in error path
Thanks to Andreas Eversberg for spotting this one.
2012-05-31 20:22:34 +02:00
Harald Welte c513ded578 vty / cfg_bts_tsc: TSC range is 0..7, not 0..255 2012-05-31 10:57:40 +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
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
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 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
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
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
Harald Welte 2935034b5e fix generation of frequency list (E-GSM vs. P-GSM 900) 2012-02-17 15:59:25 +01:00